Applications Google
Menu principal

Post a Comment On: Only Python

"Rur-ple 0.95 is out"

1 Comment -

1 – 1 of 1
Blogger Jean-Yves RAZAFY said...

Sorry couldn't find a way to send you a patch for the bug in rur_py/translation.py

--- translation.py 2006-03-22 17:17:26.000000000 -0500
+++ newTranslation.py 2006-03-22 16:52:09.000000000 -0500
@@ -5,8 +5,9 @@
# standard 'gettext' approach and expects some standard functions to
# be defined - which they are not in my customized version.

-import os
+import os , sys
home = os.getcwd()
+OsPlatform_Win = sys.platform.startswith('win')

english = {}
french = {}
@@ -14,23 +15,34 @@

#---BUG HERE FOR UNIX-LINUX path // not \\ as in windows
def select(lang):
- global selected
- global english, french, spanish
- if lang == 'en':
- if english == {}:
- filename = os.path.join(home, "rur_locale\\en\\english.po")
- english = build_dict(filename)
- selected = english
- if lang == 'es':
- if spanish == {}:
- filename = os.path.join(home, "rur_locale\\es\\spanish.po")
- spanish = build_dict(filename)
- selected = spanish
- if lang == 'fr':
- if french == {}:
- filename = os.path.join(home, "rur_locale\\fr\\french.po")
- french = build_dict(filename)
- selected = french
+ global selected
+ global english, french, spanish
+ if lang == 'en':
+ if english == {}:
+ if OsPlatform_Win:
+ filename = os.path.join(home, "rur_localei\\en\\english.po")
+ else:
+ filename = os.path.join(home, "rur_locale/en/english.po")
+ english = build_dict(filename)
+ selected = english
+ if lang == 'es':
+ if spanish == {}:
+ if OsPlatform_Win:
+ filename = os.path.join(home, "rur_localei\\es\\spanish.po")
+ else:
+ filename = os.path.join(home, "rur_locale/es/spanish.po")
+ spanish = build_dict(filename)
+ selected = spanish
+ if lang == 'fr':
+ if french == {}:
+ if OsPlatform_Win:
+ filename = os.path.join(home, "rur_localei\\fr\\french.po")
+ else:
+ filename = os.path.join(home, "rur_locale/fr/french.po")
+ french = build_dict(filename)
+ selected = french
+
+

def _(message):
message = message.replace("\n","") # message is a key in a dict

8:34 PM

Spammers: none shall pass.
You can use some HTML tags, such as <b>, <i>, <a>

Comments on this blog are restricted to team members.

You will be asked to sign in after submitting your comment.
Please prove you're not a robot