From 0eda51f2eabe24016efdc8f07825f1ba667cac33 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Thu, 15 Sep 2011 13:20:18 +0000 Subject: Fixing issues with i18n stuff: - Make gettext stuff draw-time. so switching between languages can happens without restart now. - Added option to translate visible interface (menus, buttons, labels) and tooltips. Now it's possible to have english UI and localized tooltips. - Clean-up sources, do not use gettext stuff for things which can be collected with RNA. - Fix issues with windows 64bit and ru_RU locale on my desktop (it was codepage issue). - Added operator "Get Messages" which generates new text block with with all strings collected from RNA. - Changed script for updating blender.pot so now it appends messages collected from rna to automatically gathered messages. To update .pot you have to re-generate messages.txt using "Get Messages" operator and then run update_pot script. - Clean up old translation stuff which wasn't used and most probably wouldn't be used. - Return back "International Fonts" option, so if it's disabled, no gettext lookups happens on draw. - Merged read_homefile function back. No need in splitting it. TODO: - Custom fonts and font size. Current font isn't nice at least for russian locale, it's difficult to read it. - Put references to messages.txt so gettext can merge translation when name/description of some property changes. --- release/scripts/startup/bl_ui/properties_scene.py | 24 +++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'release/scripts/startup/bl_ui/properties_scene.py') diff --git a/release/scripts/startup/bl_ui/properties_scene.py b/release/scripts/startup/bl_ui/properties_scene.py index 11e20a8cd2a..9735ff5c01b 100644 --- a/release/scripts/startup/bl_ui/properties_scene.py +++ b/release/scripts/startup/bl_ui/properties_scene.py @@ -33,7 +33,7 @@ class SceneButtonsPanel(): class SCENE_PT_scene(SceneButtonsPanel, Panel): - bl_label = _("Scene") + bl_label = "Scene" COMPAT_ENGINES = {'BLENDER_RENDER'} def draw(self, context): @@ -45,7 +45,7 @@ class SCENE_PT_scene(SceneButtonsPanel, Panel): class SCENE_PT_audio(SceneButtonsPanel, Panel): - bl_label = _("Audio") + bl_label = "Audio" COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'} def draw(self, context): @@ -73,7 +73,7 @@ class SCENE_PT_audio(SceneButtonsPanel, Panel): class SCENE_PT_unit(SceneButtonsPanel, Panel): - bl_label = _("Units") + bl_label = "Units" COMPAT_ENGINES = {'BLENDER_RENDER'} def draw(self, context): @@ -91,7 +91,7 @@ class SCENE_PT_unit(SceneButtonsPanel, Panel): class SCENE_PT_keying_sets(SceneButtonsPanel, Panel): - bl_label = _("Keying Sets") + bl_label = "Keying Sets" def draw(self, context): layout = self.layout @@ -124,7 +124,7 @@ class SCENE_PT_keying_sets(SceneButtonsPanel, Panel): class SCENE_PT_keying_set_paths(SceneButtonsPanel, Panel): - bl_label = _("Active Keying Set") + bl_label = "Active Keying Set" @classmethod def poll(cls, context): @@ -174,7 +174,7 @@ class SCENE_PT_keying_set_paths(SceneButtonsPanel, Panel): class SCENE_PT_physics(SceneButtonsPanel, Panel): - bl_label = _("Gravity") + bl_label = "Gravity" COMPAT_ENGINES = {'BLENDER_RENDER'} def draw_header(self, context): @@ -191,7 +191,7 @@ class SCENE_PT_physics(SceneButtonsPanel, Panel): class SCENE_PT_simplify(SceneButtonsPanel, Panel): - bl_label = _("Simplify") + bl_label = "Simplify" COMPAT_ENGINES = {'BLENDER_RENDER'} def draw_header(self, context): @@ -230,12 +230,12 @@ class SCENE_PT_custom_props(SceneButtonsPanel, PropertyPanel, Panel): class ANIM_OT_keying_set_export(Operator): "Export Keying Set to a python script." bl_idname = "anim.keying_set_export" - bl_label = _("Export Keying Set...") + bl_label = "Export Keying Set..." - filepath = bpy.props.StringProperty(name=_("File Path"), description=_("Filepath to write file to.")) - filter_folder = bpy.props.BoolProperty(name=_("Filter folders"), description="", default=True, options={'HIDDEN'}) - filter_text = bpy.props.BoolProperty(name=_("Filter text"), description="", default=True, options={'HIDDEN'}) - filter_python = bpy.props.BoolProperty(name=_("Filter python"), description="", default=True, options={'HIDDEN'}) + filepath = bpy.props.StringProperty(name="File Path", description="Filepath to write file to.") + filter_folder = bpy.props.BoolProperty(name="Filter folders", description="", default=True, options={'HIDDEN'}) + filter_text = bpy.props.BoolProperty(name="Filter text", description="", default=True, options={'HIDDEN'}) + filter_python = bpy.props.BoolProperty(name="Filter python", description="", default=True, options={'HIDDEN'}) def execute(self, context): if not self.filepath: -- cgit v1.2.3