[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [54396] trunk/blender/release/scripts: disable translations for some python buttons.

Campbell Barton ideasman42 at gmail.com
Fri Feb 8 17:41:02 CET 2013


Revision: 54396
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=54396
Author:   campbellbarton
Date:     2013-02-08 16:41:02 +0000 (Fri, 08 Feb 2013)
Log Message:
-----------
disable translations for some python buttons.

Modified Paths:
--------------
    trunk/blender/release/scripts/modules/bpy_types.py
    trunk/blender/release/scripts/modules/rna_prop_ui.py
    trunk/blender/release/scripts/startup/bl_ui/space_console.py
    trunk/blender/release/scripts/startup/bl_ui/space_userpref.py
    trunk/blender/release/scripts/startup/bl_ui/space_view3d_toolbar.py

Modified: trunk/blender/release/scripts/modules/bpy_types.py
===================================================================
--- trunk/blender/release/scripts/modules/bpy_types.py	2013-02-08 16:25:35 UTC (rev 54395)
+++ trunk/blender/release/scripts/modules/bpy_types.py	2013-02-08 16:41:02 UTC (rev 54396)
@@ -718,7 +718,9 @@
         files.sort()
 
         for f, filepath in files:
-            props = layout.operator(operator, text=bpy.path.display_name(f))
+            props = layout.operator(operator,
+                                    text=bpy.path.display_name(f),
+                                    translate=False)
 
             for attr, value in props_default.items():
                 setattr(props, attr, value)

Modified: trunk/blender/release/scripts/modules/rna_prop_ui.py
===================================================================
--- trunk/blender/release/scripts/modules/rna_prop_ui.py	2013-02-08 16:25:35 UTC (rev 54395)
+++ trunk/blender/release/scripts/modules/rna_prop_ui.py	2013-02-08 16:41:02 UTC (rev 54396)
@@ -135,11 +135,11 @@
         else:
             row = box.row()
 
-        row.label(text=key)
+        row.label(text=key, translate=False)
 
         # explicit exception for arrays
         if to_dict or to_list:
-            row.label(text=val_draw)
+            row.label(text=val_draw, translate=False)
         else:
             if key in rna_properties:
                 row.prop(rna_item, key, text="")

Modified: trunk/blender/release/scripts/startup/bl_ui/space_console.py
===================================================================
--- trunk/blender/release/scripts/startup/bl_ui/space_console.py	2013-02-08 16:25:35 UTC (rev 54395)
+++ trunk/blender/release/scripts/startup/bl_ui/space_console.py	2013-02-08 16:41:02 UTC (rev 54396)
@@ -80,7 +80,9 @@
         languages.sort()
 
         for language in languages:
-            layout.operator("console.language", text=language[0].upper() + language[1:]).language = language
+            layout.operator("console.language",
+                            text=language.title(),
+                            translate=False).language = language
 
 
 def add_scrollback(text, text_type):

Modified: trunk/blender/release/scripts/startup/bl_ui/space_userpref.py
===================================================================
--- trunk/blender/release/scripts/startup/bl_ui/space_userpref.py	2013-02-08 16:25:35 UTC (rev 54395)
+++ trunk/blender/release/scripts/startup/bl_ui/space_userpref.py	2013-02-08 16:41:02 UTC (rev 54396)
@@ -1217,15 +1217,15 @@
                     if mod:
                         split = colsub.row().split(percentage=0.15)
                         split.label(text="File:")
-                        split.label(text=mod.__file__)
+                        split.label(text=mod.__file__, translate=False)
                     if info["author"]:
                         split = colsub.row().split(percentage=0.15)
                         split.label(text="Author:")
-                        split.label(text=info["author"])
+                        split.label(text=info["author"], translate=False)
                     if info["version"]:
                         split = colsub.row().split(percentage=0.15)
                         split.label(text="Version:")
-                        split.label(text='.'.join(str(x) for x in info["version"]))
+                        split.label(text='.'.join(str(x) for x in info["version"]), translate=False)
                     if info["warning"]:
                         split = colsub.row().split(percentage=0.15)
                         split.label(text="Warning:")
@@ -1282,7 +1282,7 @@
                 colsub = box.column()
                 row = colsub.row()
 
-                row.label(text=module_name, icon='ERROR')
+                row.label(text=module_name, translate=False, icon='ERROR')
 
                 if is_enabled:
                     row.operator("wm.addon_disable", icon='CHECKBOX_HLT', text="", emboss=False).module = module_name

Modified: trunk/blender/release/scripts/startup/bl_ui/space_view3d_toolbar.py
===================================================================
--- trunk/blender/release/scripts/startup/bl_ui/space_view3d_toolbar.py	2013-02-08 16:25:35 UTC (rev 54395)
+++ trunk/blender/release/scripts/startup/bl_ui/space_view3d_toolbar.py	2013-02-08 16:41:02 UTC (rev 54396)
@@ -1142,14 +1142,14 @@
         row = split.row()
         row.active = (ipaint.use_stencil_layer)
         stencil_text = mesh.uv_texture_stencil.name if mesh.uv_texture_stencil else ""
-        row.menu("VIEW3D_MT_tools_projectpaint_stencil", text=stencil_text)
+        row.menu("VIEW3D_MT_tools_projectpaint_stencil", text=stencil_text, translate=False)
         row.prop(ipaint, "invert_stencil", text="", icon='IMAGE_ALPHA')
 
         col = layout.column()
         col.active = (settings.brush.image_tool == 'CLONE')
         col.prop(ipaint, "use_clone_layer", text="Clone from UV map")
         clone_text = mesh.uv_texture_clone.name if mesh.uv_texture_clone else ""
-        col.menu("VIEW3D_MT_tools_projectpaint_clone", text=clone_text)
+        col.menu("VIEW3D_MT_tools_projectpaint_clone", text=clone_text, translate=False)
 
         layout.prop(ipaint, "seam_bleed")
 
@@ -1188,7 +1188,7 @@
         layout = self.layout
 
         for i, tex in enumerate(context.active_object.data.uv_textures):
-            props = layout.operator("wm.context_set_int", text=tex.name)
+            props = layout.operator("wm.context_set_int", text=tex.name, translate=False)
             props.data_path = "active_object.data.uv_texture_clone_index"
             props.value = i
 
@@ -1199,7 +1199,7 @@
     def draw(self, context):
         layout = self.layout
         for i, tex in enumerate(context.active_object.data.uv_textures):
-            props = layout.operator("wm.context_set_int", text=tex.name)
+            props = layout.operator("wm.context_set_int", text=tex.name, translate=False)
             props.data_path = "active_object.data.uv_texture_stencil_index"
             props.value = i
 




More information about the Bf-blender-cvs mailing list