Frans Pop <aragorn@tiscali.nl> wrote:
Message-ID: <200512062038.20977.aragorn@tiscali.nl>
On Tuesday 06 December 2005 14:52, Attilio Fiandrotti wrote:
ok, let's suppose we can setup a correct gtkrc file every time we need
it: then the GTK frontend will have to read /etc/gtkrc at every
frontend_go() call and so we must be sure this wouldn't be cause of
performance degradation.
Could we not trigger (force) a re-read externally somehow?
That is exactly what the sample program written in [1]Muto-san's previous
mail does.
1. http://lists.debian.org/debian-boot/2005/12/msg00159.html
To use it, the following steps are needed:
1. Compile it with libgtk+2.0-directfb0, and archive it with
tar+gzip, and put on the server where GTK-TARBALL-SOURCE points.
2. Applied the attached patch to localechooser and rebuild udeb.
After rebuilding, put the udeb under build/localudebs.
3. Build gtk-miniiso with ttf-compact-fonts.udeb.
Currently it can change the font successfully, but it crashes cdebconf
(and cdebconf restarts). It works well with other applications(such
as gimp) and normal libgtk2.0-0.
Best regards,
--
Hidetaka Iwai
tyuyu@debian.or.jp
------------------------------------------------------------------------
Index: localechooser
===================================================================
--- localechooser (revision 32636)
+++ localechooser (working copy)
@@ -313,6 +313,23 @@
pkginstall libfribidi0
;;
esac
+
+# set the primary font accroding to $LANGUAGE
+if [ "$DEBIAN_FRONTEND" = "gtk" ]; then
+ case "$LANGUAGE" in
+ ja)
+ echo 'gtk-font-name = "Sazanami Gothic 12"' > /.\gtkrc-2.0
+ ;;
+ zh)
+ echo 'gtk-font-name = "ShanHeiSun-Uni 12"' > /.\gtkrc-2.0
+ ;;
+ ko)
+ echo 'gtk-font-name = "UnDotum 12"' > /.\gtkrc-2.0
+ ;;
+ esac
+ langupdate || treu
+fi
+
# This is needed at the end of the script
COUNTRYCODE_LANGUAGECHOOSER=$COUNTRY
COUNTRY_LANGUAGECHOOSER=$(code2country $COUNTRY)