summaryrefslogtreecommitdiffstats
path: root/gui.py
diff options
context:
space:
mode:
authorMatt Wilson <msw@redhat.com>1999-09-21 16:08:42 +0000
committerMatt Wilson <msw@redhat.com>1999-09-21 16:08:42 +0000
commit10395c942817f04a17481cabc9d25d1ba9678b6c (patch)
treea80d4a318dd48745baa638670c9e04088c4b8a42 /gui.py
parentc64619596343c12ae71aef5d1c44862f106c72b7 (diff)
downloadanaconda-10395c942817f04a17481cabc9d25d1ba9678b6c.tar.gz
anaconda-10395c942817f04a17481cabc9d25d1ba9678b6c.tar.xz
anaconda-10395c942817f04a17481cabc9d25d1ba9678b6c.zip
fork, exec for syslogd, shoot at rc parsing for language selection
Diffstat (limited to 'gui.py')
-rwxr-xr-xgui.py24
1 files changed, 15 insertions, 9 deletions
diff --git a/gui.py b/gui.py
index 5c8179a07..5920c195a 100755
--- a/gui.py
+++ b/gui.py
@@ -1,17 +1,10 @@
import gettext
+import os
cat = gettext.Catalog ("anaconda", "/usr/share/locale")
def _(string):
- return cat.gettext(string)
-
-def setLanguage (lang):
- global cat
- newlangs = [lang]
- if len(lang) > 2:
- newlangs.append(lang[:2])
- gettext.setlangs (newlangs)
- cat = gettext.Catalog ("anaconda", "/usr/share/locale")
+ return cat.gettext(string)
from gtk import *
from gtk import _root_window
@@ -219,6 +212,19 @@ class InstallInterface:
self.finishedTODO.wait ()
class InstallControlWindow (Thread):
+ def setLanguage (self, lang):
+ global cat
+
+ newlangs = [lang]
+ if len(lang) > 2:
+ newlangs.append(lang[:2])
+ gettext.setlangs (newlangs)
+ cat = gettext.Catalog ("anaconda", "/usr/share/locale")
+ for l in newlangs:
+ if os.access ("/etc/gtk/gtkrc." + l, os.R_OK):
+ rc_parse("/etc/gtk/gtkrc." + l)
+ print "loaded gtkrc." + l
+ self.window.reset_rc_styles ()
def instantiateWindow (self, windowClass):
ics = InstallControlState (self, self.ii, self.todo)