disable translations for some python buttons.
authorCampbell Barton <ideasman42@gmail.com>
Fri, 8 Feb 2013 16:41:02 +0000 (16:41 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Fri, 8 Feb 2013 16:41:02 +0000 (16:41 +0000)
release/scripts/modules/bpy_types.py
release/scripts/modules/rna_prop_ui.py
release/scripts/startup/bl_ui/space_console.py
release/scripts/startup/bl_ui/space_userpref.py
release/scripts/startup/bl_ui/space_view3d_toolbar.py

index b0a4e05b107fecf3178bc74553866d8cf873b2b3..4398b1721f7ce22b6016b7c3851a8f4bb579a413 100644 (file)
@@ -718,7 +718,9 @@ class Menu(StructRNA, _GenericUI, metaclass=RNAMeta):
         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)
index 124387955395edea1a93a2c4ff1279d5f6bcda12..5e8bccb815e439b05c333c70d82d4d902802933b 100644 (file)
@@ -135,11 +135,11 @@ def draw(layout, context, context_member, property_type, use_edit=True):
         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="")
index 23d16c14f2d6e015925baa65ee3d65a9d05cb03f..70e0fb4fcf2990509c461d07c8ed8f5fa2c70582 100644 (file)
@@ -80,7 +80,9 @@ class CONSOLE_MT_language(Menu):
         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):
index b4b6554d4fabb09cee85b8962d4dc1b76fc7222b..4ebd38ca0b22ee4d67ad58f7bf9cc1e248b22cc4 100644 (file)
@@ -1217,15 +1217,15 @@ class USERPREF_PT_addons(Panel):
                     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 @@ class USERPREF_PT_addons(Panel):
                 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
index 0faac7cce3ff451cb04944c54ee6d9f29b79827c..2fb420dabea126fdeed873e54b89e4f2a7a09c00 100644 (file)
@@ -1142,14 +1142,14 @@ class VIEW3D_PT_tools_projectpaint(View3DPanel, Panel):
         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 @@ class VIEW3D_MT_tools_projectpaint_clone(Menu):
         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 @@ class VIEW3D_MT_tools_projectpaint_stencil(Menu):
     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