merge with trunk r39834
authorXiao Xiangquan <xiaoxiangquan@gmail.com>
Thu, 1 Sep 2011 15:08:32 +0000 (15:08 +0000)
committerXiao Xiangquan <xiaoxiangquan@gmail.com>
Thu, 1 Sep 2011 15:08:32 +0000 (15:08 +0000)
165 files changed:
1  2 
SConstruct
intern/ffmpeg/ffmpeg_compat.h
intern/ghost/intern/GHOST_SystemSDL.cpp
release/scripts/startup/bl_operators/animsys_update.py
release/scripts/startup/bl_operators/object.py
release/scripts/startup/bl_operators/object_align.py
release/scripts/startup/bl_operators/object_quick_effects.py
release/scripts/startup/bl_operators/object_randomize_transform.py
release/scripts/startup/bl_operators/presets.py
release/scripts/startup/bl_operators/screen_play_rendered_anim.py
release/scripts/startup/bl_operators/sequencer.py
release/scripts/startup/bl_operators/wm.py
release/scripts/startup/bl_ui/properties_data_armature.py
release/scripts/startup/bl_ui/properties_data_bone.py
release/scripts/startup/bl_ui/properties_data_camera.py
release/scripts/startup/bl_ui/properties_data_curve.py
release/scripts/startup/bl_ui/properties_data_empty.py
release/scripts/startup/bl_ui/properties_data_lamp.py
release/scripts/startup/bl_ui/properties_data_lattice.py
release/scripts/startup/bl_ui/properties_data_mesh.py
release/scripts/startup/bl_ui/properties_data_metaball.py
release/scripts/startup/bl_ui/properties_data_modifier.py
release/scripts/startup/bl_ui/properties_game.py
release/scripts/startup/bl_ui/properties_material.py
release/scripts/startup/bl_ui/properties_object.py
release/scripts/startup/bl_ui/properties_object_constraint.py
release/scripts/startup/bl_ui/properties_particle.py
release/scripts/startup/bl_ui/properties_physics_cloth.py
release/scripts/startup/bl_ui/properties_physics_common.py
release/scripts/startup/bl_ui/properties_physics_field.py
release/scripts/startup/bl_ui/properties_physics_fluid.py
release/scripts/startup/bl_ui/properties_physics_smoke.py
release/scripts/startup/bl_ui/properties_physics_softbody.py
release/scripts/startup/bl_ui/properties_render.py
release/scripts/startup/bl_ui/properties_scene.py
release/scripts/startup/bl_ui/properties_texture.py
release/scripts/startup/bl_ui/properties_world.py
release/scripts/startup/bl_ui/space_console.py
release/scripts/startup/bl_ui/space_dopesheet.py
release/scripts/startup/bl_ui/space_graph.py
release/scripts/startup/bl_ui/space_image.py
release/scripts/startup/bl_ui/space_info.py
release/scripts/startup/bl_ui/space_logic.py
release/scripts/startup/bl_ui/space_nla.py
release/scripts/startup/bl_ui/space_node.py
release/scripts/startup/bl_ui/space_outliner.py
release/scripts/startup/bl_ui/space_sequencer.py
release/scripts/startup/bl_ui/space_text.py
release/scripts/startup/bl_ui/space_time.py
release/scripts/startup/bl_ui/space_userpref.py
release/scripts/startup/bl_ui/space_userpref_keymap.py
release/scripts/startup/bl_ui/space_view3d.py
release/scripts/startup/bl_ui/space_view3d_toolbar.py
source/blender/blenfont/intern/blf.c
source/blender/blenlib/BLI_callbacks.h
source/blender/blenlib/intern/callbacks.c
source/blender/blenlib/intern/fileops.c
source/blender/editors/animation/anim_channels_edit.c
source/blender/editors/animation/anim_markers.c
source/blender/editors/animation/anim_ops.c
source/blender/editors/animation/drivers.c
source/blender/editors/animation/keyframing.c
source/blender/editors/animation/keyingsets.c
source/blender/editors/armature/SConscript
source/blender/editors/armature/armature_ops.c
source/blender/editors/armature/editarmature.c
source/blender/editors/armature/poseSlide.c
source/blender/editors/armature/poselib.c
source/blender/editors/armature/poseobject.c
source/blender/editors/gpencil/gpencil_paint.c
source/blender/editors/interface/interface.c
source/blender/editors/interface/interface_handlers.c
source/blender/editors/interface/interface_layout.c
source/blender/editors/interface/interface_regions.c
source/blender/editors/interface/interface_templates.c
source/blender/editors/interface/interface_utils.c
source/blender/editors/mesh/SConscript
source/blender/editors/mesh/editmesh.c
source/blender/editors/mesh/editmesh_mods.c
source/blender/editors/mesh/editmesh_tools.c
source/blender/editors/object/SConscript
source/blender/editors/object/object_add.c
source/blender/editors/object/object_constraint.c
source/blender/editors/object/object_edit.c
source/blender/editors/object/object_modifier.c
source/blender/editors/object/object_ops.c
source/blender/editors/object/object_relations.c
source/blender/editors/object/object_select.c
source/blender/editors/object/object_transform.c
source/blender/editors/physics/SConscript
source/blender/editors/physics/particle_edit.c
source/blender/editors/physics/physics_pointcache.c
source/blender/editors/render/SConscript
source/blender/editors/render/render_shading.c
source/blender/editors/screen/area.c
source/blender/editors/screen/screen_ops.c
source/blender/editors/sculpt_paint/SConscript
source/blender/editors/sculpt_paint/paint_image.c
source/blender/editors/sculpt_paint/sculpt.c
source/blender/editors/sound/CMakeLists.txt
source/blender/editors/sound/sound_ops.c
source/blender/editors/space_action/action_edit.c
source/blender/editors/space_action/action_ops.c
source/blender/editors/space_action/action_select.c
source/blender/editors/space_buttons/buttons_header.c
source/blender/editors/space_console/console_ops.c
source/blender/editors/space_file/file_ops.c
source/blender/editors/space_graph/graph_buttons.c
source/blender/editors/space_graph/graph_edit.c
source/blender/editors/space_graph/graph_ops.c
source/blender/editors/space_graph/graph_select.c
source/blender/editors/space_image/image_buttons.c
source/blender/editors/space_image/image_ops.c
source/blender/editors/space_info/info_ops.c
source/blender/editors/space_logic/logic_window.c
source/blender/editors/space_nla/nla_buttons.c
source/blender/editors/space_nla/nla_channels.c
source/blender/editors/space_nla/nla_edit.c
source/blender/editors/space_nla/nla_select.c
source/blender/editors/space_node/node_edit.c
source/blender/editors/space_node/node_header.c
source/blender/editors/space_node/node_select.c
source/blender/editors/space_outliner/CMakeLists.txt
source/blender/editors/space_sequencer/SConscript
source/blender/editors/space_sequencer/sequencer_add.c
source/blender/editors/space_sequencer/sequencer_edit.c
source/blender/editors/space_sequencer/sequencer_select.c
source/blender/editors/space_text/text_ops.c
source/blender/editors/space_time/time_ops.c
source/blender/editors/space_view3d/view3d_edit.c
source/blender/editors/space_view3d/view3d_fly.c
source/blender/editors/space_view3d/view3d_header.c
source/blender/editors/space_view3d/view3d_select.c
source/blender/editors/space_view3d/view3d_toolbar.c
source/blender/editors/space_view3d/view3d_view.c
source/blender/editors/transform/transform.c
source/blender/editors/transform/transform_ops.c
source/blender/editors/uvedit/uvedit_ops.c
source/blender/editors/uvedit/uvedit_unwrap_ops.c
source/blender/makesrna/RNA_access.h
source/blender/makesrna/intern/rna_ID.c
source/blender/makesrna/intern/rna_access.c
source/blender/makesrna/intern/rna_action.c
source/blender/makesrna/intern/rna_constraint.c
source/blender/makesrna/intern/rna_curve.c
source/blender/makesrna/intern/rna_define.c
source/blender/makesrna/intern/rna_fcurve.c
source/blender/makesrna/intern/rna_modifier.c
source/blender/makesrna/intern/rna_object.c
source/blender/makesrna/intern/rna_object_force.c
source/blender/makesrna/intern/rna_particle.c
source/blender/makesrna/intern/rna_scene.c
source/blender/makesrna/intern/rna_space.c
source/blender/makesrna/intern/rna_texture.c
source/blender/makesrna/intern/rna_userdef.c
source/blender/makesrna/intern/rna_wm.c
source/blender/python/intern/bpy_app_handlers.c
source/blender/python/intern/bpy_intern_string.c
source/blender/python/mathutils/mathutils_Vector.c
source/blender/windowmanager/WM_api.h
source/blender/windowmanager/intern/wm_files.c
source/blender/windowmanager/intern/wm_init_exit.c
source/blender/windowmanager/intern/wm_operators.c
source/creator/CMakeLists.txt
source/gameengine/GamePlayer/ghost/GPG_ghost.cpp

diff --cc SConstruct
Simple merge
  # <pep8-80 compliant>
  
  import bpy
+ from bpy.types import Operator
  from bpy.props import StringProperty, BoolProperty, EnumProperty, IntProperty
 +from blf import gettext as _
  
  
- class SelectPattern(bpy.types.Operator):
+ class SelectPattern(Operator):
      '''Select object matching a naming pattern'''
      bl_idname = "object.select_pattern"
 -    bl_label = "Select Pattern"
 +    bl_label = _("Select Pattern")
      bl_options = {'REGISTER', 'UNDO'}
  
      pattern = StringProperty(
          row.prop(self, "extend")
  
  
- class SelectCamera(bpy.types.Operator):
+ class SelectCamera(Operator):
      '''Select object matching a naming pattern'''
      bl_idname = "object.select_camera"
 -    bl_label = "Select Camera"
 +    bl_label = _("Select Camera")
      bl_options = {'REGISTER', 'UNDO'}
  
      @classmethod
@@@ -192,15 -192,20 +193,19 @@@ class SubdivisionSet(Operator)
      '''Sets a Subdivision Surface Level (1-5)'''
  
      bl_idname = "object.subdivision_set"
 -    bl_label = "Subdivision Set"
 +    bl_label = _("Subdivision Set")
      bl_options = {'REGISTER', 'UNDO'}
  
-     level = IntProperty(name=_("Level"),
-             default=1, min=-100, max=100, soft_min=-6, soft_max=6)
+     level = IntProperty(
 -            name="Level",
++            name=_("Level"),
+             min=-100, max=100,
+             soft_min=-6, soft_max=6,
+             default=1,
+             )
  
      relative = BoolProperty(
 -            name="Relative",
 -            description=("Apply the subsurf level as an offset "
 -                         "relative to the current level"),
 +            name=_("Relative"),
 +            description=_("Apply the subsurf level as an offset relative to the current level"),
              default=False,
              )
  
@@@ -506,10 -512,10 +511,10 @@@ class ShapeTransfer(Operator)
          return self._main(ob_act, objects, self.mode, self.use_clamp)
  
  
- class JoinUVs(bpy.types.Operator):
+ class JoinUVs(Operator):
      '''Copy UV Layout to objects with matching geometry'''
      bl_idname = "object.join_uvs"
 -    bl_label = "Join as UVs"
 +    bl_label = _("Join as UVs")
  
      @classmethod
      def poll(cls, context):
          return {'FINISHED'}
  
  
- class MakeDupliFace(bpy.types.Operator):
+ class MakeDupliFace(Operator):
      '''Make linked objects into dupli-faces'''
      bl_idname = "object.make_dupli_face"
 -    bl_label = "Make Dupli-Face"
 +    bl_label = _("Make Dupli-Face")
  
      @classmethod
      def poll(cls, context):
@@@ -669,10 -675,10 +674,10 @@@ class IsolateTypeRender(Operator)
          return {'FINISHED'}
  
  
- class ClearAllRestrictRender(bpy.types.Operator):
+ class ClearAllRestrictRender(Operator):
      '''Reveal all render objects by setting the hide render flag'''
      bl_idname = "object.hide_render_clear_all"
 -    bl_label = "Clear All Restrict Render"
 +    bl_label = _("Clear All Restrict Render")
      bl_options = {'REGISTER', 'UNDO'}
  
      def execute(self, context):
@@@ -19,8 -19,8 +19,9 @@@
  # <pep8-80 compliant>
  
  import bpy
+ from bpy.types import Operator
  from mathutils import Vector
 +from blf import gettext as _
  
  
  def GlobalBB_LQ(bb_world):
@@@ -340,42 -340,45 +341,43 @@@ def align_objects(align_x
  from bpy.props import EnumProperty, BoolProperty
  
  
- class AlignObjects(bpy.types.Operator):
+ class AlignObjects(Operator):
      '''Align Objects'''
      bl_idname = "object.align"
 -    bl_label = "Align Objects"
 +    bl_label = _("Align Objects")
      bl_options = {'REGISTER', 'UNDO'}
  
      bb_quality = BoolProperty(
 -            name="High Quality",
 -            description=("Enables high quality calculation of the "
 -                         "bounding box for perfect results on complex "
 -                         "shape meshes with rotation/scale (Slow)"),
 +            name=_("High Quality"),
 +            description=_("Enables high quality calculation of the bounding box for perfect results on complex shape meshes with rotation/scale (Slow)"),
-             default=True)
-     align_mode = EnumProperty(items=(
-             ('OPT_1', "Negative Sides", ""),
-             ('OPT_2', "Centers", ""),
-             ('OPT_3', "Positive Sides", "")),
-         name="Align Mode:",
-         description="",
-         default='OPT_2')
-     relative_to = EnumProperty(items=(
-             ('OPT_1', "Scene Origin", ""),
-             ('OPT_2', "3D Cursor", ""),
-             ('OPT_3', "Selection", ""),
-             ('OPT_4', "Active", "")),
-         name="Relative To:",
-         description="",
-         default='OPT_4')
-     align_axis = EnumProperty(items=(
-             ('X', "X", ""),
-             ('Y', "Y", ""),
-             ('Z', "Z", ""),
-             ),
-                 name="Align",
-                 description="Align to axis",
-                 options={'ENUM_FLAG'})
+             default=True,
+             )
+     align_mode = EnumProperty(
 -            name="Align Mode:",
++            name=_("Align Mode:"),
+             items=(('OPT_1', "Negative Sides", ""),
+                    ('OPT_2', "Centers", ""),
+                    ('OPT_3', "Positive Sides", ""),
+                    ),
+             default='OPT_2',
+             )
+     relative_to = EnumProperty(
 -            name="Relative To:",
++            name=_("Relative To:"),
+             items=(('OPT_1', "Scene Origin", ""),
+                    ('OPT_2', "3D Cursor", ""),
+                    ('OPT_3', "Selection", ""),
+                    ('OPT_4', "Active", ""),
+                    ),
+             default='OPT_4',
+             )
+     align_axis = EnumProperty(
 -            name="Align",
 -            description="Align to axis",
++            name=_("Align"),
++            description=_("Align to axis"),
+             items=(('X', "X", ""),
+                    ('Y', "Y", ""),
+                    ('Z', "Z", ""),
+                    ),
+             options={'ENUM_FLAG'},
+             )
  
      @classmethod
      def poll(cls, context):
@@@ -389,19 -414,16 +414,16 @@@ class QuickFluid(Operator)
      bl_options = {'REGISTER', 'UNDO'}
  
      style = EnumProperty(
+             name="Fluid Style",
              items=(('INFLOW', "Inflow", ""),
-                    ('BASIC', "Basic", ""),
-                    ),
-                 name="Fluid Style",
-                 description="",
-                 default='BASIC',
-                 )
+                    ('BASIC', "Basic", "")),
+             default='BASIC',
+             )
      initial_velocity = FloatVectorProperty(
 -            name="Initial Velocity",
 -            description="Initial velocity of the fluid",
 +            name=_("Initial Velocity"),
 +            description=_("Initial velocity of the fluid"),
+             min=-100.0, max=100.0,
              default=(0.0, 0.0, 0.0),
-             min=-100.0,
-             max=100.0,
              subtype='VELOCITY',
              )
      show_flows = BoolProperty(
@@@ -19,7 -19,7 +19,9 @@@
  # <pep8-80 compliant>
  
  import bpy
++
+ from bpy.types import Operator
 +from blf import gettext as _
  
  
  def randomize_selected(seed, delta, loc, rot, scale, scale_even):
  from bpy.props import IntProperty, BoolProperty, FloatVectorProperty
  
  
- class RandomizeLocRotSize(bpy.types.Operator):
+ class RandomizeLocRotSize(Operator):
      '''Randomize objects loc/rot/scale'''
      bl_idname = "object.randomize_transform"
 -    bl_label = "Randomize Transform"
 +    bl_label = _("Randomize Transform")
      bl_options = {'REGISTER', 'UNDO'}
  
      random_seed = IntProperty(
              default=False,
              )
  
-     '''scale_min = FloatProperty(name="Minimun Scale Factor",
-         description="Lowest scale percentage possible",
-         default=0.15, min=-1.0, max=1.0, precision=3)'''
+     '''scale_min = FloatProperty(
+             name="Minimun Scale Factor",
+             description="Lowest scale percentage possible",
+             min=-1.0, max=1.0, precision=3,
+             default=0.15,
+             )'''
  
      scale = FloatVectorProperty(
 -            name="Scale",
 -            description="Maximum scale randomization over each axis",
 +            name=_("Scale"),
 +            description=_("Maximum scale randomization over each axis"),
              min=-100.0,
              max=100.0,
              default=(0.0, 0.0, 0.0),
@@@ -19,7 -19,7 +19,8 @@@
  # <pep8-80 compliant>
  
  import bpy
+ from bpy.types import Menu, Operator
 +from blf import gettext as _
  
  
  class AddPresetBase():
              return self.execute(context)
  
  
- class ExecutePreset(bpy.types.Operator):
+ class ExecutePreset(Operator):
      ''' Executes a preset '''
      bl_idname = "script.execute_preset"
 -    bl_label = "Execute a Python Preset"
 +    bl_label = _("Execute a Python Preset")
 +    __doc__ = _(" Executes a preset ")
  
      filepath = bpy.props.StringProperty(
 -            name="Path",
 -            description="Path of the Python file to execute",
 +            name=_("Path"),
 +            description=_("Path of the Python file to execute"),
              maxlen=512,
              )
      menu_idname = bpy.props.StringProperty(
          return {'FINISHED'}
  
  
- class AddPresetRender(AddPresetBase, bpy.types.Operator):
+ class AddPresetRender(AddPresetBase, Operator):
      '''Add a Render Preset'''
      bl_idname = "render.preset_add"
 -    bl_label = "Add Render Preset"
 +    bl_label = _("Add Render Preset")
      preset_menu = "RENDER_MT_presets"
  
      preset_defines = [
      preset_subdir = "render"
  
  
- class AddPresetSSS(AddPresetBase, bpy.types.Operator):
+ class AddPresetSSS(AddPresetBase, Operator):
      '''Add a Subsurface Scattering Preset'''
      bl_idname = "material.sss_preset_add"
 -    bl_label = "Add SSS Preset"
 +    bl_label = _("Add SSS Preset")
      preset_menu = "MATERIAL_MT_sss_presets"
 +    __doc__ = _("Add a Subsurface Scattering Preset")
  
      preset_defines = [
          ("material = "
      preset_subdir = "sss"
  
  
- class AddPresetCloth(AddPresetBase, bpy.types.Operator):
+ class AddPresetCloth(AddPresetBase, Operator):
      '''Add a Cloth Preset'''
      bl_idname = "cloth.preset_add"
 -    bl_label = "Add Cloth Preset"
 +    bl_label = _("Add Cloth Preset")
      preset_menu = "CLOTH_MT_presets"
  
      preset_defines = [
      preset_subdir = "cloth"
  
  
- class AddPresetSunSky(AddPresetBase, bpy.types.Operator):
+ class AddPresetSunSky(AddPresetBase, Operator):
      '''Add a Sky & Atmosphere Preset'''
      bl_idname = "lamp.sunsky_preset_add"
 -    bl_label = "Add Sunsky Preset"
 +    bl_label = _("Add Sunsky Preset")
      preset_menu = "LAMP_MT_sunsky_presets"
  
      preset_defines = [
      preset_subdir = "sunsky"
  
  
- class AddPresetInteraction(AddPresetBase, bpy.types.Operator):
+ class AddPresetInteraction(AddPresetBase, Operator):
      '''Add an Application Interaction Preset'''
      bl_idname = "wm.interaction_preset_add"
 -    bl_label = "Add Interaction Preset"
 +    bl_label = _("Add Interaction Preset")
      preset_menu = "USERPREF_MT_interaction_presets"
 +    __doc__ = _('Add an Application Interaction Preset')
  
      preset_defines = [
          "user_preferences = bpy.context.user_preferences"
      preset_subdir = "interaction"
  
  
- class AddPresetKeyconfig(AddPresetBase, bpy.types.Operator):
+ class AddPresetKeyconfig(AddPresetBase, Operator):
      '''Add a Keyconfig Preset'''
      bl_idname = "wm.keyconfig_preset_add"
 -    bl_label = "Add Keyconfig Preset"
 +    bl_label = _("Add Keyconfig Preset")
      preset_menu = "USERPREF_MT_keyconfigs"
      preset_subdir = "keyconfig"
 +    __doc__ = _('Add a Keyconfig Preset')
  
      def add(self, context, filepath):
          bpy.ops.wm.keyconfig_export(filepath=filepath)
              keyconfigs.remove(keyconfigs.active)
  
  
- class AddPresetOperator(AddPresetBase, bpy.types.Operator):
+ class AddPresetOperator(AddPresetBase, Operator):
      '''Add an Application Interaction Preset'''
      bl_idname = "wm.operator_preset_add"
 -    bl_label = "Operator Preset"
 +    bl_label = _("Operator Preset")
      preset_menu = "WM_MT_operator_presets"
 +    __doc__ = _("Add an Application Interaction Preset")
  
      operator = bpy.props.StringProperty(
 -            name="Operator",
 +            name=_("Operator"),
              maxlen=64,
              options={'HIDDEN'},
              )
          return os.path.join("operator", "%s.%s" % (prefix.lower(), suffix))
  
  
- class WM_MT_operator_presets(bpy.types.Menu):
+ class WM_MT_operator_presets(Menu):
 -    bl_label = "Operator Presets"
 +    bl_label = _("Operator Presets")
  
      def draw(self, context):
          self.operator = context.space_data.operator.bl_idname
@@@ -21,8 -21,8 +21,9 @@@
  # Originally written by Matt Ebb
  
  import bpy
+ from bpy.types import Operator
  import os
 +from blf import gettext as _
  
  
  def guess_player_path(preset):
      return player_path
  
  
- class PlayRenderedAnim(bpy.types.Operator):
+ class PlayRenderedAnim(Operator):
      '''Plays back rendered frames/movies using an external player.'''
      bl_idname = "render.play_rendered_anim"
 -    bl_label = "Play Rendered Animation"
 +    bl_label = _("Play Rendered Animation")
      bl_options = {'REGISTER'}
 +    __doc__ = _("Plays back rendered frames/movies using an external player.")
  
      def execute(self, context):
          import subprocess
  # <pep8 compliant>
  
  import bpy
+ from bpy.types import Operator
  
  from bpy.props import IntProperty
 +from blf import gettext as _
  
  
- class SequencerCrossfadeSounds(bpy.types.Operator):
+ class SequencerCrossfadeSounds(Operator):
      '''Do crossfading volume animation of two selected sound strips.'''
  
      bl_idname = "sequencer.crossfade_sounds"
@@@ -79,11 -79,15 +80,15 @@@ class SequencerCutMulticam(Operator)
      '''Cut multicam strip and select camera.'''
  
      bl_idname = "sequencer.cut_multicam"
 -    bl_label = "Cut multicam"
 +    bl_label = _("Cut multicam")
      bl_options = {'REGISTER', 'UNDO'}
  
-     camera = IntProperty(name=_("Camera"),
-             default=1, min=1, max=32, soft_min=1, soft_max=32)
+     camera = IntProperty(
 -            name="Camera",
++            name=_("Camera"),
+             min=1, max=32,
+             soft_min=1, soft_max=32,
+             default=1,
+             )
  
      @classmethod
      def poll(cls, context):
  # <pep8 compliant>
  
  import bpy
- from bpy.props import StringProperty, BoolProperty, IntProperty, \
-                       FloatProperty, EnumProperty
+ from bpy.types import Menu, Operator
+ from bpy.props import (StringProperty,
+                        BoolProperty,
+                        IntProperty,
+                        FloatProperty,
+                        EnumProperty,
+                        )
  
  from rna_prop_ui import rna_idprop_ui_prop_get, rna_idprop_ui_prop_clear
 +from blf import gettext as _
  
  
- class MESH_OT_delete_edgeloop(bpy.types.Operator):
+ class MESH_OT_delete_edgeloop(Operator):
      '''Delete an edge loop by merging the faces on each side to a single face loop'''
      bl_idname = "mesh.delete_edgeloop"
 -    bl_label = "Delete Edge Loop"
 +    bl_label = _("Delete Edge Loop")
  
      def execute(self, context):
          if 'FINISHED' in bpy.ops.transform.edge_slide(value=1.0):
  
          return {'CANCELLED'}
  
- rna_path_prop = StringProperty(name=_("Context Attributes"),
-         description=_("rna context string"), maxlen=1024, default="")
+ rna_path_prop = StringProperty(
 -        name="Context Attributes",
 -        description="rna context string",
++        name=_("Context Attributes"),
++        description=_("rna context string"),
+         maxlen=1024,
+         )
  
- rna_reverse_prop = BoolProperty(name=_("Reverse"),
-         description=_("Cycle backwards"), default=False)
+ rna_reverse_prop = BoolProperty(
 -        name="Reverse",
 -        description="Cycle backwards",
++        name=_("Reverse"),
++        description=_("Cycle backwards"),
+         default=False,
+         )
  
- rna_relative_prop = BoolProperty(name=_("Relative"),
+ rna_relative_prop = BoolProperty(
 -        name="Relative",
 -        description="Apply relative to the current value (delta)",
++        name=_("Relative"),
 +        description=_("Apply relative to the current value (delta)"),
-         default=False)
+         default=False,
+         )
  
  
  def context_path_validate(context, data_path):
@@@ -70,22 -130,27 +131,27 @@@ def execute_context_assign(self, contex
          return {'PASS_THROUGH'}
  
      if getattr(self, "relative", False):
-         exec("context.%s+=self.value" % self.data_path)
+         exec("context.%s += self.value" % data_path)
      else:
-         exec("context.%s=self.value" % self.data_path)
+         exec("context.%s = self.value" % data_path)
  
-     return {'FINISHED'}
+     return operator_path_undo_return(context, data_path)
  
  
- class BRUSH_OT_active_index_set(bpy.types.Operator):
+ class BRUSH_OT_active_index_set(Operator):
      '''Set active sculpt/paint brush from it's number'''
      bl_idname = "brush.active_index_set"
 -    bl_label = "Set Brush Number"
 +    bl_label = _("Set Brush Number")
  
-     mode = StringProperty(name=_("mode"),
-             description=_("Paint mode to set brush for"), maxlen=1024)
-     index = IntProperty(name=_("number"),
-             description=_("Brush number"))
+     mode = StringProperty(
 -            name="mode",
 -            description="Paint mode to set brush for",
++            name=_("mode"),
++            description=_("Paint mode to set brush for"),
+             maxlen=1024,
+             )
+     index = IntProperty(
 -            name="number",
 -            description="Brush number",
++            name=_("number"),
++            description=_("Brush number"),
+             )
  
      _attr_dict = {"sculpt": "use_paint_sculpt",
                    "vertex_paint": "use_paint_vertex",
          return {'CANCELLED'}
  
  
- class WM_OT_context_set_boolean(bpy.types.Operator):
+ class WM_OT_context_set_boolean(Operator):
      '''Set a context value.'''
      bl_idname = "wm.context_set_boolean"
 -    bl_label = "Context Set Boolean"
 +    bl_label = _("Context Set Boolean")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = BoolProperty(name=_("Value"),
-             description=_("Assignment value"), default=True)
+     value = BoolProperty(
 -            name="Value",
 -            description="Assignment value",
++            name=_("Value"),
++            description=_("Assignment value"),
+             default=True,
+             )
  
      execute = execute_context_assign
  
  
- class WM_OT_context_set_int(bpy.types.Operator):  # same as enum
+ class WM_OT_context_set_int(Operator):  # same as enum
      '''Set a context value.'''
      bl_idname = "wm.context_set_int"
 -    bl_label = "Context Set"
 +    bl_label = _("Context Set")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = IntProperty(name=_("Value"), description=_("Assign value"), default=0)
+     value = IntProperty(
 -            name="Value",
 -            description="Assign value",
++            name=_("Value"),
++            description=_("Assign value"),
+             default=0,
+             )
      relative = rna_relative_prop
  
      execute = execute_context_assign
  
  
- class WM_OT_context_scale_int(bpy.types.Operator):
+ class WM_OT_context_scale_int(Operator):
      '''Scale an int context value.'''
      bl_idname = "wm.context_scale_int"
 -    bl_label = "Context Set"
 +    bl_label = _("Context Set")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = FloatProperty(name=_("Value"), description=_("Assign value"), default=1.0)
-     always_step = BoolProperty(name=_("Always Step"),
-         description=_("Always adjust the value by a minimum of 1 when 'value' is not 1.0."),
-         default=True)
+     value = FloatProperty(
 -            name="Value",
 -            description="Assign value",
++            name=_("Value"),
++            description=_("Assign value"),
+             default=1.0,
+             )
+     always_step = BoolProperty(
 -            name="Always Step",
 -            description="Always adjust the value by a minimum of 1 when 'value' is not 1.0.",
++            name=_("Always Step"),
++            description=_("Always adjust the value by a minimum of 1 when 'value' is not 1.0."),
+             default=True,
+             )
  
      def execute(self, context):
-         if context_path_validate(context, self.data_path) is Ellipsis:
+         data_path = self.data_path
+         if context_path_validate(context, data_path) is Ellipsis:
              return {'PASS_THROUGH'}
  
          value = self.value
              else:
                  add = "-1"
                  func = "min"
-             exec("context.%s = %s(round(context.%s * value), context.%s + %s)" % (data_path, func, data_path, data_path, add))
+             exec("context.%s = %s(round(context.%s * value), context.%s + %s)" %
+                  (data_path, func, data_path, data_path, add))
          else:
-             exec("context.%s *= value" % self.data_path)
+             exec("context.%s *= value" % data_path)
  
-         return {'FINISHED'}
+         return operator_path_undo_return(context, data_path)
  
  
- class WM_OT_context_set_float(bpy.types.Operator):  # same as enum
+ class WM_OT_context_set_float(Operator):  # same as enum
      '''Set a context value.'''
      bl_idname = "wm.context_set_float"
 -    bl_label = "Context Set Float"
 +    bl_label = _("Context Set Float")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = FloatProperty(name=_("Value"),
-             description=_("Assignment value"), default=0.0)
+     value = FloatProperty(
 -            name="Value",
 -            description="Assignment value",
++            name=_("Value"),
++            description=_("Assignment value"),
+             default=0.0,
+             )
      relative = rna_relative_prop
  
      execute = execute_context_assign
  
  
- class WM_OT_context_set_string(bpy.types.Operator):  # same as enum
+ class WM_OT_context_set_string(Operator):  # same as enum
      '''Set a context value.'''
      bl_idname = "wm.context_set_string"
 -    bl_label = "Context Set String"
 +    bl_label = _("Context Set String")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = StringProperty(name=_("Value"),
-             description=_("Assign value"), maxlen=1024, default="")
+     value = StringProperty(
 -            name="Value",
 -            description="Assign value",
++            name=_("Value"),
++            description=_("Assign value"),
+             maxlen=1024,
+             )
  
      execute = execute_context_assign
  
  
- class WM_OT_context_set_enum(bpy.types.Operator):
+ class WM_OT_context_set_enum(Operator):
      '''Set a context value.'''
      bl_idname = "wm.context_set_enum"
 -    bl_label = "Context Set Enum"
 +    bl_label = _("Context Set Enum")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = StringProperty(name=_("Value"),
+     value = StringProperty(
 -            name="Value",
 -            description="Assignment value (as a string)",
++            name=_("Value"),
 +            description=_("Assignment value (as a string)"),
-             maxlen=1024, default="")
+             maxlen=1024,
+             )
  
      execute = execute_context_assign
  
  
- class WM_OT_context_set_value(bpy.types.Operator):
+ class WM_OT_context_set_value(Operator):
      '''Set a context value.'''
      bl_idname = "wm.context_set_value"
 -    bl_label = "Context Set Value"
 +    bl_label = _("Context Set Value")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = StringProperty(name=_("Value"),
+     value = StringProperty(
 -            name="Value",
 -            description="Assignment value (as a string)",
++            name=_("Value"),
 +            description=_("Assignment value (as a string)"),
-             maxlen=1024, default="")
+             maxlen=1024,
+             )
  
      def execute(self, context):
-         if context_path_validate(context, self.data_path) is Ellipsis:
+         data_path = self.data_path
+         if context_path_validate(context, data_path) is Ellipsis:
              return {'PASS_THROUGH'}
-         exec("context.%s=%s" % (self.data_path, self.value))
-         return {'FINISHED'}
+         exec("context.%s = %s" % (data_path, self.value))
+         return operator_path_undo_return(context, data_path)
  
  
- class WM_OT_context_toggle(bpy.types.Operator):
+ class WM_OT_context_toggle(Operator):
      '''Toggle a context value.'''
      bl_idname = "wm.context_toggle"
 -    bl_label = "Context Toggle"
 +    bl_label = _("Context Toggle")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
  
      def execute(self, context):
+         data_path = self.data_path
  
-         if context_path_validate(context, self.data_path) is Ellipsis:
+         if context_path_validate(context, data_path) is Ellipsis:
              return {'PASS_THROUGH'}
  
-         exec("context.%s=not (context.%s)" %
-             (self.data_path, self.data_path))
+         exec("context.%s = not (context.%s)" % (data_path, data_path))
  
-         return {'FINISHED'}
+         return operator_path_undo_return(context, data_path)
  
  
- class WM_OT_context_toggle_enum(bpy.types.Operator):
+ class WM_OT_context_toggle_enum(Operator):
      '''Toggle a context value.'''
      bl_idname = "wm.context_toggle_enum"
 -    bl_label = "Context Toggle Values"
 +    bl_label = _("Context Toggle Values")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value_1 = StringProperty(name=_("Value"), \
-                 description=_("Toggle enum"), maxlen=1024, default="")
-     value_2 = StringProperty(name=_("Value"), \
-                 description=_("Toggle enum"), maxlen=1024, default="")
+     value_1 = StringProperty(
 -            name="Value",
 -            description="Toggle enum",
++            name=_("Value"),
++            description=_("Toggle enum"),
+             maxlen=1024,
+             )
+     value_2 = StringProperty(
 -            name="Value",
 -            description="Toggle enum",
++            name=_("Value"),
++            description=_("Toggle enum"),
+             maxlen=1024,
+             )
  
      def execute(self, context):
+         data_path = self.data_path
  
-         if context_path_validate(context, self.data_path) is Ellipsis:
+         if context_path_validate(context, data_path) is Ellipsis:
              return {'PASS_THROUGH'}
  
-         exec("context.%s = ['%s', '%s'][context.%s!='%s']" % \
-             (self.data_path, self.value_1,\
-              self.value_2, self.data_path,
-              self.value_2))
+         exec("context.%s = ('%s', '%s')[context.%s != '%s']" %
+              (data_path, self.value_1,
+               self.value_2, data_path,
+               self.value_2,
+               ))
  
-         return {'FINISHED'}
+         return operator_path_undo_return(context, data_path)
  
  
- class WM_OT_context_cycle_int(bpy.types.Operator):
+ class WM_OT_context_cycle_int(Operator):
      '''Set a context value. Useful for cycling active material, '''
      '''vertex keys, groups' etc.'''
      bl_idname = "wm.context_cycle_int"
              else:
                  value = -1 << 31
  
-             exec("context.%s=value" % data_path)
+             exec("context.%s = value" % data_path)
  
-         return {'FINISHED'}
+         return operator_path_undo_return(context, data_path)
  
  
- class WM_OT_context_cycle_enum(bpy.types.Operator):
+ class WM_OT_context_cycle_enum(Operator):
      '''Toggle a context value.'''
      bl_idname = "wm.context_cycle_enum"
 -    bl_label = "Context Enum Cycle"
 +    bl_label = _("Context Enum Cycle")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
@@@ -406,9 -504,9 +505,9 @@@ class WM_MT_context_menu_enum(Menu)
              prop.value = identifier
  
  
- class WM_OT_context_menu_enum(bpy.types.Operator):
+ class WM_OT_context_menu_enum(Operator):
      bl_idname = "wm.context_menu_enum"
 -    bl_label = "Context Enum Menu"
 +    bl_label = _("Context Enum Menu")
      bl_options = {'UNDO', 'INTERNAL'}
      data_path = rna_path_prop
  
          return {'PASS_THROUGH'}
  
  
- class WM_OT_context_set_id(bpy.types.Operator):
+ class WM_OT_context_set_id(Operator):
      '''Toggle a context value.'''
      bl_idname = "wm.context_set_id"
 -    bl_label = "Set Library ID"
 +    bl_label = _("Set Library ID")
      bl_options = {'UNDO', 'INTERNAL'}
  
      data_path = rna_path_prop
-     value = StringProperty(name=_("Value"),
-             description=_("Assign value"), maxlen=1024, default="")
+     value = StringProperty(
 -            name="Value",
 -            description="Assign value",
++            name=_("Value"),
++            description=_("Assign value"),
+             maxlen=1024,
+             )
  
      def execute(self, context):
          value = self.value
  
          if id_iter:
              value_id = getattr(bpy.data, id_iter).get(value)
-             exec("context.%s=value_id" % data_path)
+             exec("context.%s = value_id" % data_path)
  
-         return {'FINISHED'}
+         return operator_path_undo_return(context, data_path)
  
  
- doc_id = StringProperty(name=_("Doc ID"),
-         description="", maxlen=1024, default="", options={'HIDDEN'})
+ doc_id = StringProperty(
 -        name="Doc ID",
++        name=_("Doc ID"),
+         maxlen=1024,
+         options={'HIDDEN'},
+         )
  
- doc_new = StringProperty(name=_("Edit Description"),
-         description="", maxlen=1024, default="")
+ doc_new = StringProperty(
 -        name="Edit Description",
++        name=_("Edit Description"),
+         maxlen=1024,
+         )
  
  data_path_iter = StringProperty(
          description="The data path relative to the context, must point to an iterable.")
@@@ -518,20 -629,26 +630,26 @@@ class WM_OT_context_collection_boolean_
          for item in items_ok:
              exec(exec_str)
  
-         return {'FINISHED'}
+         return operator_value_undo_return(item)
  
  
- class WM_OT_context_modal_mouse(bpy.types.Operator):
+ class WM_OT_context_modal_mouse(Operator):
      '''Adjust arbitrary values with mouse input'''
      bl_idname = "wm.context_modal_mouse"
 -    bl_label = "Context Modal Mouse"
 +    bl_label = _("Context Modal Mouse")
-     bl_options = {'GRAB_POINTER', 'BLOCKING', 'INTERNAL'}
+     bl_options = {'GRAB_POINTER', 'BLOCKING', 'UNDO', 'INTERNAL'}
  
      data_path_iter = data_path_iter
      data_path_item = data_path_item
  
-     input_scale = FloatProperty(default=0.01, description=_("Scale the mouse movement by this value before applying the delta"))
-     invert = BoolProperty(default=False, description=_("Invert the mouse input"))
+     input_scale = FloatProperty(
 -            description="Scale the mouse movement by this value before applying the delta",
++            description=_("Scale the mouse movement by this value before applying the delta"),
+             default=0.01,
+             )
+     invert = BoolProperty(
 -            description="Invert the mouse input",
++            description=_("Invert the mouse input"),
+             default=False,
+             )
      initial_x = IntProperty(options={'HIDDEN'})
  
      def _values_store(self, context):
              return {'RUNNING_MODAL'}
  
  
- class WM_OT_url_open(bpy.types.Operator):
+ class WM_OT_url_open(Operator):
      "Open a website in the Webbrowser"
 +    __doc__ = _("Open a website in the Webbrowser")
      bl_idname = "wm.url_open"
      bl_label = ""
  
@@@ -628,7 -747,11 +749,11 @@@ class WM_OT_path_open(Operator)
      bl_idname = "wm.path_open"
      bl_label = ""
  
-     filepath = StringProperty(name=_("File Path"), maxlen=1024, subtype='FILE_PATH')
+     filepath = StringProperty(
 -            name="File Path",
++            name=_("File Path"),
+             maxlen=1024,
+             subtype='FILE_PATH',
+             )
  
      def execute(self, context):
          import sys
          return {'FINISHED'}
  
  
- class WM_OT_doc_view(bpy.types.Operator):
+ class WM_OT_doc_view(Operator):
      '''Load online reference docs'''
      bl_idname = "wm.doc_view"
 -    bl_label = "View Documentation"
 +    bl_label = _("View Documentation")
  
      doc_id = doc_id
      if bpy.app.version_cycle == "release":
          return {'FINISHED'}
  
  
- class WM_OT_doc_edit(bpy.types.Operator):
+ class WM_OT_doc_edit(Operator):
      '''Load online reference docs'''
      bl_idname = "wm.doc_edit"
 -    bl_label = "Edit Documentation"
 +    bl_label = _("Edit Documentation")
  
      doc_id = doc_id
      doc_new = doc_new
          return wm.invoke_props_dialog(self, width=600)
  
  
- rna_path = StringProperty(name=_("Property Edit"),
-     description=_("Property data_path edit"), maxlen=1024, default="", options={'HIDDEN'})
+ rna_path = StringProperty(
 -        name="Property Edit",
 -        description="Property data_path edit",
++        name=_("Property Edit"),
++        description=_("Property data_path edit"),
+         maxlen=1024,
+         options={'HIDDEN'},
+         )
+ rna_value = StringProperty(
 -        name="Property Value",
 -        description="Property value edit",
++        name=_("Property Value"),
++        description=_("Property value edit"),
+         maxlen=1024,
+         )
  
- rna_value = StringProperty(name=_("Property Value"),
-     description=_("Property value edit"), maxlen=1024, default="")
+ rna_property = StringProperty(
 -        name="Property Name",
 -        description="Property name edit",
++        name=_("Property Name"),
++        description=_("Property name edit"),
+         maxlen=1024,
+         )
  
- rna_property = StringProperty(name=_("Property Name"),
-     description=_("Property name edit"), maxlen=1024, default="")
+ rna_min = FloatProperty(
 -        name="Min",
++        name=_("Min"),
+         default=0.0,
+         precision=3,
+         )
  
- rna_min = FloatProperty(name=_("Min"), default=0.0, precision=3)
- rna_max = FloatProperty(name=_("Max"), default=1.0, precision=3)
+ rna_max = FloatProperty(
+         name="Max",
+         default=1.0,
+         precision=3,
+         )
  
  
- class WM_OT_properties_edit(bpy.types.Operator):
+ class WM_OT_properties_edit(Operator):
      '''Internal use (edit a property data_path)'''
      bl_idname = "wm.properties_edit"
 -    bl_label = "Edit Property"
 +    bl_label = _("Edit Property")
 +    __doc__ = _("Internal use (edit a property data_path)")
      bl_options = {'REGISTER'}  # only because invoke_props_popup requires.
  
      data_path = rna_path
      value = rna_value
      min = rna_min
      max = rna_max
-     description = StringProperty(name=_("Tip"), default="")
+     description = StringProperty(
 -            name="Tip",
++            name=_("Tip"),
+             )
  
      def execute(self, context):
          data_path = self.data_path
          return wm.invoke_props_dialog(self)
  
  
- class WM_OT_properties_add(bpy.types.Operator):
+ class WM_OT_properties_add(Operator):
      '''Internal use (edit a property data_path)'''
      bl_idname = "wm.properties_add"
 -    bl_label = "Add Property"
 +    bl_label = _("Add Property")
 +    __doc__ = _("Internal use (edit a property data_path)")
  
      data_path = rna_path
  
@@@ -911,18 -1056,20 +1060,21 @@@ class WM_OT_properties_context_change(O
      bl_idname = "wm.properties_context_change"
      bl_label = ""
  
-     context = StringProperty(name=_("Context"), maxlen=32)
+     context = StringProperty(
 -            name="Context",
++            name=_("Context"),
+             maxlen=32,
+             )
  
      def execute(self, context):
-         context.space_data.context = (self.context)
+         context.space_data.context = self.context
          return {'FINISHED'}
  
  
- class WM_OT_properties_remove(bpy.types.Operator):
+ class WM_OT_properties_remove(Operator):
      '''Internal use (edit a property data_path)'''
      bl_idname = "wm.properties_remove"
 -    bl_label = "Remove Property"
 +    bl_label = _("Remove Property")
 +    __doc__ = _("Internal use (edit a property data_path)")
  
      data_path = rna_path
      property = rna_property
          return {'FINISHED'}
  
  
- class WM_OT_keyconfig_activate(bpy.types.Operator):
+ class WM_OT_keyconfig_activate(Operator):
      bl_idname = "wm.keyconfig_activate"
 -    bl_label = "Activate Keyconfig"
 +    bl_label = _("Activate Keyconfig")
  
-     filepath = StringProperty(name=_("File Path"), maxlen=1024)
+     filepath = StringProperty(
 -            name="File Path",
++            name=_("File Path"),
+             maxlen=1024,
+             )
  
      def execute(self, context):
          bpy.utils.keyconfig_set(self.filepath)
          return {'FINISHED'}
  
  
- class WM_OT_appconfig_default(bpy.types.Operator):
+ class WM_OT_appconfig_default(Operator):
      bl_idname = "wm.appconfig_default"
 -    bl_label = "Default Application Configuration"
 +    bl_label = _("Default Application Configuration")
  
      def execute(self, context):
          import os
          return {'FINISHED'}
  
  
- class WM_OT_appconfig_activate(bpy.types.Operator):
+ class WM_OT_appconfig_activate(Operator):
      bl_idname = "wm.appconfig_activate"
 -    bl_label = "Activate Application Configuration"
 +    bl_label = _("Activate Application Configuration")
  
-     filepath = StringProperty(name="File Path", maxlen=1024)
+     filepath = StringProperty(
+             name="File Path",
+             maxlen=1024,
+             )
  
      def execute(self, context):
          import os
          return {'FINISHED'}
  
  
- class WM_OT_sysinfo(bpy.types.Operator):
+ class WM_OT_sysinfo(Operator):
      '''Generate System Info'''
      bl_idname = "wm.sysinfo"
 -    bl_label = "System Info"
 +    bl_label = _("System Info")
 +    __doc__ = _("Generate System Info")
  
      def execute(self, context):
          import sys_info
          return {'FINISHED'}
  
  
- class WM_OT_copy_prev_settings(bpy.types.Operator):
+ class WM_OT_copy_prev_settings(Operator):
      '''Copy settings from previous version'''
      bl_idname = "wm.copy_prev_settings"
 -    bl_label = "Copy Previous Settings"
 +    bl_label = _("Copy Previous Settings")
  
      def execute(self, context):
          import os
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel, Menu
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class ArmatureButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -48,8 -49,8 +49,8 @@@ class DATA_PT_context_arm(ArmatureButto
              layout.template_ID(space, "pin_id")
  
  
- class DATA_PT_skeleton(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_skeleton(ArmatureButtonsPanel, Panel):
 -    bl_label = "Skeleton"
 +    bl_label = _("Skeleton")
  
      def draw(self, context):
          layout = self.layout
  
          layout.label(text="Deform:")
          flow = layout.column_flow()
 -        flow.prop(arm, "use_deform_vertex_groups", text="Vertex Groups")
 -        flow.prop(arm, "use_deform_envelopes", text="Envelopes")
 -        flow.prop(arm, "use_deform_preserve_volume", text="Quaternion")
 +        flow.prop(arm, "use_deform_vertex_groups", text=_("Vertex Groups"))
 +        flow.prop(arm, "use_deform_envelopes", text=_("Envelopes"))
 +        flow.prop(arm, "use_deform_preserve_volume", text=_("Quaternion"))
  
+         if context.scene.render.engine == "BLENDER_GAME":
+             layout.row().prop(arm, "vert_deformer", expand=True)
  
- class DATA_PT_display(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_display(ArmatureButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
  
      def draw(self, context):
          layout = self.layout
          split = layout.split()
  
          col = split.column()
 -        col.prop(arm, "show_names", text="Names")
 -        col.prop(arm, "show_axes", text="Axes")
 -        col.prop(arm, "show_bone_custom_shapes", text="Shapes")
 +        col.prop(arm, "show_names", text=_("Names"))
 +        col.prop(arm, "show_axes", text=_("Axes"))
 +        col.prop(arm, "show_bone_custom_shapes", text=_("Shapes"))
  
          col = split.column()
 -        col.prop(arm, "show_group_colors", text="Colors")
 +        col.prop(arm, "show_group_colors", text=_("Colors"))
          if ob:
 -            col.prop(ob, "show_x_ray", text="X-Ray")
 -        col.prop(arm, "use_deform_delay", text="Delay Refresh")
 +            col.prop(ob, "show_x_ray", text=_("X-Ray"))
 +        col.prop(arm, "use_deform_delay", text=_("Delay Refresh"))
  
  
- class DATA_PT_bone_groups(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_bone_group_specials(Menu):
 -    bl_label = "Bone Group Specials"
++    bl_label = _("Bone Group Specials")
+     def draw(self, context):
+         layout = self.layout
+         layout.operator("pose.group_sort", icon='SORTALPHA')
+ class DATA_PT_bone_groups(ArmatureButtonsPanel, Panel):
 -    bl_label = "Bone Groups"
 +    bl_label = _("Bone Groups")
  
      @classmethod
      def poll(cls, context):
          row.active = (ob.proxy is None)
  
          sub = row.row(align=True)
 -        sub.operator("pose.group_assign", text="Assign")
 -        sub.operator("pose.group_unassign", text="Remove")  # row.operator("pose.bone_group_remove_from", text="Remove")
 +        sub.operator("pose.group_assign", text=_("Assign"))
 +        sub.operator("pose.group_unassign", text=_("Remove"))  # row.operator("pose.bone_group_remove_from", text=_("Remove"))
  
          sub = row.row(align=True)
 -        sub.operator("pose.group_select", text="Select")
 -        sub.operator("pose.group_deselect", text="Deselect")
 +        sub.operator("pose.group_select", text=_("Select"))
 +        sub.operator("pose.group_deselect", text=_("Deselect"))
  
  
- class DATA_PT_pose_library(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_pose_library(ArmatureButtonsPanel, Panel):
 -    bl_label = "Pose Library"
 +    bl_label = _("Pose Library")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
  
  
  # TODO: this panel will soon be depreceated too
- class DATA_PT_ghost(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_ghost(ArmatureButtonsPanel, Panel):
 -    bl_label = "Ghost"
 +    bl_label = _("Ghost")
  
      def draw(self, context):
          layout = self.layout
          col = split.column(align=True)
  
          if arm.ghost_type == 'RANGE':
 -            col.prop(arm, "ghost_frame_start", text="Start")
 -            col.prop(arm, "ghost_frame_end", text="End")
 -            col.prop(arm, "ghost_size", text="Step")
 +            col.prop(arm, "ghost_frame_start", text=_("Start"))
 +            col.prop(arm, "ghost_frame_end", text=_("End"))
 +            col.prop(arm, "ghost_size", text=_("Step"))
          elif arm.ghost_type == 'CURRENT_FRAME':
 -            col.prop(arm, "ghost_step", text="Range")
 -            col.prop(arm, "ghost_size", text="Step")
 +            col.prop(arm, "ghost_step", text=_("Range"))
 +            col.prop(arm, "ghost_size", text=_("Step"))
  
          col = split.column()
 -        col.label(text="Display:")
 -        col.prop(arm, "show_only_ghost_selected", text="Selected Only")
 +        col.label(text=_("Display:"))
 +        col.prop(arm, "show_only_ghost_selected", text=_("Selected Only"))
  
  
- class DATA_PT_iksolver_itasc(ArmatureButtonsPanel, bpy.types.Panel):
+ class DATA_PT_iksolver_itasc(ArmatureButtonsPanel, Panel):
 -    bl_label = "iTaSC parameters"
 +    bl_label = _("iTaSC parameters")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -285,11 -306,11 +306,11 @@@ class DATA_PT_motion_paths(MotionPathBu
          layout.separator()
  
          split = layout.split()
 -        split.operator("pose.paths_calculate", text="Calculate Paths")
 -        split.operator("pose.paths_clear", text="Clear Paths")
 +        split.operator("pose.paths_calculate", text=_("Calculate Paths"))
 +        split.operator("pose.paths_clear", text=_("Clear Paths"))
  
  
- class DATA_PT_onion_skinning(OnionSkinButtonsPanel):  # , bpy.types.Panel): # inherit from panel when ready
+ class DATA_PT_onion_skinning(OnionSkinButtonsPanel):  # , Panel): # inherit from panel when ready
      #bl_label = "Bones Onion Skinning"
      bl_context = "data"
  
@@@ -19,8 -19,9 +19,9 @@@
  # <pep8 compliant>
  
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class BoneButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -48,8 -49,8 +49,8 @@@ class BONE_PT_context_bone(BoneButtonsP
          row.prop(bone, "name", text="")
  
  
- class BONE_PT_transform(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_transform(BoneButtonsPanel, Panel):
 -    bl_label = "Transform"
 +    bl_label = _("Transform")
  
      @classmethod
      def poll(cls, context):
              sub.prop(bone, "lock")
  
  
- class BONE_PT_transform_locks(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_transform_locks(BoneButtonsPanel, Panel):
 -    bl_label = "Transform Locks"
 +    bl_label = _("Transform Locks")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          row.column().prop(pchan, "lock_scale")
  
  
- class BONE_PT_relations(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_relations(BoneButtonsPanel, Panel):
 -    bl_label = "Relations"
 +    bl_label = _("Relations")
  
      def draw(self, context):
          layout = self.layout
          sub = col.column()
          sub.active = (bone.parent is not None)
          sub.prop(bone, "use_connect")
 -        sub.prop(bone, "use_inherit_rotation", text="Inherit Rotation")
 -        sub.prop(bone, "use_inherit_scale", text="Inherit Scale")
 +        sub.prop(bone, "use_inherit_rotation", text=_("Inherit Rotation"))
 +        sub.prop(bone, "use_inherit_scale", text=_("Inherit Scale"))
          sub = col.column()
          sub.active = (not bone.parent or not bone.use_connect)
 -        sub.prop(bone, "use_local_location", text="Local Location")
 +        sub.prop(bone, "use_local_location", text=_("Local Location"))
  
  
- class BONE_PT_display(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_display(BoneButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
  
      @classmethod
      def poll(cls, context):
              if pchan:
                  col = split.column()
  
 -                col.label(text="Custom Shape:")
 +                col.label(text=_("Custom Shape:"))
                  col.prop(pchan, "custom_shape", text="")
                  if pchan.custom_shape:
 -                    col.prop_search(pchan, "custom_shape_transform", ob.pose, "bones", text="At")
 +                    col.prop_search(pchan, "custom_shape_transform", ob.pose, "bones", text=_("At"))
  
  
- class BONE_PT_inverse_kinematics(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_inverse_kinematics(BoneButtonsPanel, Panel):
 -    bl_label = "Inverse Kinematics"
 +    bl_label = _("Inverse Kinematics")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
              col.active = pchan.is_in_ik_chain
              # not supported yet
              #row = layout.row()
 -            #row.prop(pchan, "use_ik_linear_control", text="Joint Size")
 -            #row.prop(pchan, "ik_linear_weight", text="Weight", slider=True)
 +            #row.prop(pchan, "use_ik_linear_control", text=_("Joint Size"))
 +            #row.prop(pchan, "ik_linear_weight", text=_("Weight"), slider=True)
  
  
- class BONE_PT_deform(BoneButtonsPanel, bpy.types.Panel):
+ class BONE_PT_deform(BoneButtonsPanel, Panel):
 -    bl_label = "Deform"
 +    bl_label = _("Deform")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw_header(self, context):
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class CameraButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -53,8 -54,8 +54,8 @@@ class DATA_PT_context_camera(CameraButt
              split.separator()
  
  
- class DATA_PT_camera(CameraButtonsPanel, bpy.types.Panel):
+ class DATA_PT_camera(CameraButtonsPanel, Panel):
 -    bl_label = "Lens"
 +    bl_label = _("Lens")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
  
          col = split.column()
  
-         if cam.dof_object != None:
+         if cam.dof_object is not None:
              col.enabled = False
 -        col.prop(cam, "dof_distance", text="Distance")
 +        col.prop(cam, "dof_distance", text=_("Distance"))
  
  
- class DATA_PT_camera_display(CameraButtonsPanel, bpy.types.Panel):
+ class DATA_PT_camera_display(CameraButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          col.prop_menu_enum(cam, "show_guide")
  
          col = split.column()
 -        col.prop(cam, "draw_size", text="Size")
 +        col.prop(cam, "draw_size", text=_("Size"))
          col.separator()
 -        col.prop(cam, "show_passepartout", text="Passepartout")
 +        col.prop(cam, "show_passepartout", text=_("Passepartout"))
          sub = col.column()
          sub.active = cam.show_passepartout
 -        sub.prop(cam, "passepartout_alpha", text="Alpha", slider=True)
 +        sub.prop(cam, "passepartout_alpha", text=_("Alpha"), slider=True)
  
  
- class DATA_PT_custom_props_camera(CameraButtonsPanel, PropertyPanel, bpy.types.Panel):
+ class DATA_PT_custom_props_camera(CameraButtonsPanel, PropertyPanel, Panel):
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      _context_path = "object.data"
      _property_type = bpy.types.Camera
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class CurveButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -65,8 -66,8 +66,8 @@@ class DATA_PT_context_curve(CurveButton
              layout.template_ID(space, "pin_id")  # XXX: broken
  
  
- class DATA_PT_shape_curve(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_shape_curve(CurveButtonsPanel, Panel):
 -    bl_label = "Shape"
 +    bl_label = _("Shape")
  
      def draw(self, context):
          layout = self.layout
              sub = col.column()
              sub.label(text="")
              sub = col.column(align=True)
 -            sub.prop(curve, "resolution_v", text="Preview V")
 -            sub.prop(curve, "render_resolution_v", text="Render V")
 +            sub.prop(curve, "resolution_v", text=_("Preview V"))
 +            sub.prop(curve, "render_resolution_v", text=_("Render V"))
  
          if (is_curve or is_text):
 -            col.label(text="Fill:")
 +            col.label(text=_("Fill:"))
              sub = col.column()
-             sub.active = (curve.bevel_object is None)
+             sub.active = (curve.dimensions == '2D' or (curve.bevel_object is None and curve.dimensions == '3D'))
              sub.prop(curve, "use_fill_front")
              sub.prop(curve, "use_fill_back")
 -            col.prop(curve, "use_fill_deform", text="Fill Deformed")
 +            col.prop(curve, "use_fill_deform", text=_("Fill Deformed"))
  
  
- class DATA_PT_curve_texture_space(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_curve_texture_space(CurveButtonsPanel, Panel):
 -    bl_label = "Texture Space"
 +    bl_label = _("Texture Space")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          row.prop(curve, "use_uv_as_generated")
  
          row = layout.row()
 -        row.column().prop(curve, "texspace_location", text="Location")
 -        row.column().prop(curve, "texspace_size", text="Size")
 +        row.column().prop(curve, "texspace_location", text=_("Location"))
 +        row.column().prop(curve, "texspace_size", text=_("Size"))
  
  
- class DATA_PT_geometry_curve(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_geometry_curve(CurveButtonsPanel, Panel):
 -    bl_label = "Geometry"
 +    bl_label = _("Geometry")
  
      @classmethod
      def poll(cls, context):
          col.prop(curve, "bevel_object", text="")
  
  
- class DATA_PT_pathanim(CurveButtonsPanelCurve, bpy.types.Panel):
+ class DATA_PT_pathanim(CurveButtonsPanelCurve, Panel):
 -    bl_label = "Path Animation"
 +    bl_label = _("Path Animation")
  
      def draw_header(self, context):
          curve = context.curve
  
          col = split.column()
          col.prop(curve, "use_radius")
 -        col.prop(curve, "use_time_offset", text="Offset Children")
 +        col.prop(curve, "use_time_offset", text=_("Offset Children"))
  
  
- class DATA_PT_active_spline(CurveButtonsPanelActive, bpy.types.Panel):
+ class DATA_PT_active_spline(CurveButtonsPanelActive, Panel):
 -    bl_label = "Active Spline"
 +    bl_label = _("Active Spline")
  
      def draw(self, context):
          layout = self.layout
              layout.prop(act_spline, "use_smooth")
  
  
- class DATA_PT_font(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_font(CurveButtonsPanel, Panel):
 -    bl_label = "Font"
 +    bl_label = _("Font")
  
      @classmethod
      def poll(cls, context):
          row.prop(char, "use_small_caps")
  
  
- class DATA_PT_paragraph(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_paragraph(CurveButtonsPanel, Panel):
 -    bl_label = "Paragraph"
 +    bl_label = _("Paragraph")
  
      @classmethod
      def poll(cls, context):
          col.prop(text, "offset_y", text="Y")
  
  
- class DATA_PT_text_boxes(CurveButtonsPanel, bpy.types.Panel):
+ class DATA_PT_text_boxes(CurveButtonsPanel, Panel):
 -    bl_label = "Text Boxes"
 +    bl_label = _("Text Boxes")
  
      @classmethod
      def poll(cls, context):
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class DataButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -30,8 -31,8 +31,8 @@@
          return (context.object and context.object.type == 'EMPTY')
  
  
- class DATA_PT_empty(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_empty(DataButtonsPanel, Panel):
 -    bl_label = "Empty"
 +    bl_label = _("Empty")
  
      def draw(self, context):
          layout = self.layout
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Menu, Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
- class LAMP_MT_sunsky_presets(bpy.types.Menu):
+ class LAMP_MT_sunsky_presets(Menu):
 -    bl_label = "Sun & Sky Presets"
 +    bl_label = _("Sun & Sky Presets")
      preset_subdir = "sunsky"
      preset_operator = "script.execute_preset"
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
@@@ -65,16 -66,16 +66,16 @@@ class DATA_PT_context_lamp(DataButtonsP
              split.label(text=str(texture_count), icon='TEXTURE')
  
  
- class DATA_PT_preview(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_preview(DataButtonsPanel, Panel):
 -    bl_label = "Preview"
 +    bl_label = _("Preview")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          self.layout.template_preview(context.lamp)
  
  
- class DATA_PT_lamp(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_lamp(DataButtonsPanel, Panel):
 -    bl_label = "Lamp"
 +    bl_label = _("Lamp")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          col.prop(lamp, "use_diffuse")
  
  
- class DATA_PT_sunsky(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_sunsky(DataButtonsPanel, Panel):
 -    bl_label = "Sky & Atmosphere"
 +    bl_label = _("Sky & Atmosphere")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
  
          col = split.column()
          col.active = lamp.use_atmosphere
 -        col.label(text="Scattering:")
 +        col.label(text=_("Scattering:"))
          sub = col.column(align=True)
 -        sub.prop(lamp, "atmosphere_inscattering", slider=True, text="Inscattering")
 -        sub.prop(lamp, "atmosphere_extinction", slider=True, text="Extinction")
 +        sub.prop(lamp, "atmosphere_inscattering", slider=True, text=_("Inscattering"))
 +        sub.prop(lamp, "atmosphere_extinction", slider=True, text=_("Extinction"))
  
  
- class DATA_PT_shadow(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_shadow(DataButtonsPanel, Panel):
 -    bl_label = "Shadow"
 +    bl_label = _("Shadow")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              split = layout.split()
  
              col = split.column()
 -            col.prop(lamp, "use_auto_clip_start", text="Autoclip Start")
 +            col.prop(lamp, "use_auto_clip_start", text=_("Autoclip Start"))
              sub = col.column()
              sub.active = not lamp.use_auto_clip_start
 -            sub.prop(lamp, "shadow_buffer_clip_start", text="Clip Start")
 +            sub.prop(lamp, "shadow_buffer_clip_start", text=_("Clip Start"))
  
              col = split.column()
 -            col.prop(lamp, "use_auto_clip_end", text="Autoclip End")
 +            col.prop(lamp, "use_auto_clip_end", text=_("Autoclip End"))
              sub = col.column()
              sub.active = not lamp.use_auto_clip_end
 -            sub.prop(lamp, "shadow_buffer_clip_end", text=" Clip End")
 +            sub.prop(lamp, "shadow_buffer_clip_end", text=_(" Clip End"))
  
  
- class DATA_PT_area(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_area(DataButtonsPanel, Panel):
 -    bl_label = "Area Shape"
 +    bl_label = _("Area Shape")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
          if (lamp.shape == 'SQUARE'):
              sub.prop(lamp, "size")
          elif (lamp.shape == 'RECTANGLE'):
 -            sub.prop(lamp, "size", text="Size X")
 -            sub.prop(lamp, "size_y", text="Size Y")
 +            sub.prop(lamp, "size", text=_("Size X"))
 +            sub.prop(lamp, "size_y", text=_("Size Y"))
  
  
- class DATA_PT_spot(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_spot(DataButtonsPanel, Panel):
 -    bl_label = "Spot Shape"
 +    bl_label = _("Spot Shape")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
          col.prop(lamp, "use_halo")
          sub = col.column(align=True)
          sub.active = lamp.use_halo
 -        sub.prop(lamp, "halo_intensity", text="Intensity")
 +        sub.prop(lamp, "halo_intensity", text=_("Intensity"))
          if lamp.shadow_method == 'BUFFER_SHADOW':
 -            sub.prop(lamp, "halo_step", text="Step")
 +            sub.prop(lamp, "halo_step", text=_("Step"))
  
  
- class DATA_PT_falloff_curve(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_falloff_curve(DataButtonsPanel, Panel):
 -    bl_label = "Falloff Curve"
 +    bl_label = _("Falloff Curve")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class DataButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -51,8 -52,8 +52,8 @@@ class DATA_PT_context_lattice(DataButto
              split.separator()
  
  
- class DATA_PT_lattice(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_lattice(DataButtonsPanel, Panel):
 -    bl_label = "Lattice"
 +    bl_label = _("Lattice")
  
      def draw(self, context):
          layout = self.layout
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Menu, Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
- class MESH_MT_vertex_group_specials(bpy.types.Menu):
+ class MESH_MT_vertex_group_specials(Menu):
 -    bl_label = "Vertex Group Specials"
 +    bl_label = _("Vertex Group Specials")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          layout.operator("object.vertex_group_copy_to_linked", icon='LINK_AREA')
          layout.operator("object.vertex_group_copy_to_selected", icon='LINK_AREA')
          layout.operator("object.vertex_group_mirror", icon='ARROW_LEFTRIGHT')
 -        layout.operator("object.vertex_group_remove", icon='X', text="Delete All").all = True
 +        layout.operator("object.vertex_group_remove", icon='X', text=_("Delete All")).all = True
  
  
- class MESH_MT_shape_key_specials(bpy.types.Menu):
+ class MESH_MT_shape_key_specials(Menu):
 -    bl_label = "Shape Key Specials"
 +    bl_label = _("Shape Key Specials")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
@@@ -79,8 -80,8 +80,8 @@@ class DATA_PT_context_mesh(MeshButtonsP
              layout.template_ID(space, "pin_id")
  
  
- class DATA_PT_normals(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_normals(MeshButtonsPanel, Panel):
 -    bl_label = "Normals"
 +    bl_label = _("Normals")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          split.prop(mesh, "show_double_sided")
  
  
- class DATA_PT_texture_space(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_texture_space(MeshButtonsPanel, Panel):
 -    bl_label = "Texture Space"
 +    bl_label = _("Texture Space")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
  
          layout.prop(mesh, "use_auto_texspace")
          row = layout.row()
 -        row.column().prop(mesh, "texspace_location", text="Location")
 -        row.column().prop(mesh, "texspace_size", text="Size")
 +        row.column().prop(mesh, "texspace_location", text=_("Location"))
 +        row.column().prop(mesh, "texspace_size", text=_("Size"))
  
  
- class DATA_PT_vertex_groups(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_vertex_groups(MeshButtonsPanel, Panel):
 -    bl_label = "Vertex Groups"
 +    bl_label = _("Vertex Groups")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              row = layout.row()
  
              sub = row.row(align=True)
 -            sub.operator("object.vertex_group_assign", text="Assign")
 -            sub.operator("object.vertex_group_remove_from", text="Remove")
 +            sub.operator("object.vertex_group_assign", text=_("Assign"))
 +            sub.operator("object.vertex_group_remove_from", text=_("Remove"))
  
              sub = row.row(align=True)
 -            sub.operator("object.vertex_group_select", text="Select")
 -            sub.operator("object.vertex_group_deselect", text="Deselect")
 +            sub.operator("object.vertex_group_select", text=_("Select"))
 +            sub.operator("object.vertex_group_deselect", text=_("Deselect"))
  
 -            layout.prop(context.tool_settings, "vertex_group_weight", text="Weight")
 +            layout.prop(context.tool_settings, "vertex_group_weight", text=_("Weight"))
  
  
- class DATA_PT_shape_keys(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_shape_keys(MeshButtonsPanel, Panel):
 -    bl_label = "Shape Keys"
 +    bl_label = _("Shape Keys")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
                  row.prop(key, "slurph")
  
  
- class DATA_PT_uv_texture(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_uv_texture(MeshButtonsPanel, Panel):
 -    bl_label = "UV Texture"
 +    bl_label = _("UV Texture")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
              layout.prop(lay, "name")
  
  
- class DATA_PT_texface(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_texface(MeshButtonsPanel, Panel):
 -    bl_label = "Texture Face"
 +    bl_label = _("Texture Face")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              col = layout.column()
              col.prop(tf, "blend_type")
          else:
 -            col.label(text="No UV Texture")
 +            col.label(text=_("No UV Texture"))
  
  
- class DATA_PT_vertex_colors(MeshButtonsPanel, bpy.types.Panel):
+ class DATA_PT_vertex_colors(MeshButtonsPanel, Panel):
 -    bl_label = "Vertex Colors"
 +    bl_label = _("Vertex Colors")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class DataButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -48,8 -49,8 +49,8 @@@ class DATA_PT_context_metaball(DataButt
              layout.template_ID(space, "pin_id")
  
  
- class DATA_PT_metaball(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_metaball(DataButtonsPanel, Panel):
 -    bl_label = "Metaball"
 +    bl_label = _("Metaball")
  
      def draw(self, context):
          layout = self.layout
@@@ -72,8 -73,8 +73,8 @@@
          layout.prop(mball, "update_method", expand=True)
  
  
- class DATA_PT_mball_texture_space(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_mball_texture_space(DataButtonsPanel, Panel):
 -    bl_label = "Texture Space"
 +    bl_label = _("Texture Space")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          layout.prop(mball, "use_auto_texspace")
  
          row = layout.row()
 -        row.column().prop(mball, "texspace_location", text="Location")
 -        row.column().prop(mball, "texspace_size", text="Size")
 +        row.column().prop(mball, "texspace_location", text=_("Location"))
 +        row.column().prop(mball, "texspace_size", text=_("Size"))
  
  
- class DATA_PT_metaball_element(DataButtonsPanel, bpy.types.Panel):
+ class DATA_PT_metaball_element(DataButtonsPanel, Panel):
 -    bl_label = "Active Element"
 +    bl_label = _("Active Element")
  
      @classmethod
      def poll(cls, context):
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class ModifierButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -26,8 -27,8 +27,8 @@@
      bl_context = "modifier"
  
  
- class DATA_PT_modifiers(ModifierButtonsPanel, bpy.types.Panel):
+ class DATA_PT_modifiers(ModifierButtonsPanel, Panel):
 -    bl_label = "Modifiers"
 +    bl_label = _("Modifiers")
  
      def draw(self, context):
          layout = self.layout
          col.prop(md, "offset")
          sub = col.column()
          sub.active = bool(md.vertex_group)
 -        sub.prop(md, "invert_vertex_group", text="Invert")
 -        sub.prop(md, "thickness_vertex_group", text="Factor")
 +        sub.prop(md, "invert_vertex_group", text=_("Invert"))
++        sub.prop(md, "thickness_vertex_group", text=_("Factor"))
  
          col.prop(md, "use_even_offset")
          col.prop(md, "use_quality_normals")
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class PhysicsButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -26,8 -27,8 +27,8 @@@
      bl_context = "physics"
  
  
- class PHYSICS_PT_game_physics(PhysicsButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_game_physics(PhysicsButtonsPanel, Panel):
 -    bl_label = "Physics"
 +    bl_label = _("Physics")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
              subsub.prop(game, "friction_coefficients", text="", slider=True)
  
          elif game.physics_type in {'SENSOR', 'INVISIBLE', 'NO_COLLISION', 'OCCLUDE'}:
 -            layout.prop(ob, "hide_render", text="Invisible")
 +            layout.prop(ob, "hide_render", text=_("Invisible"))
  
  
- class PHYSICS_PT_game_collision_bounds(PhysicsButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_game_collision_bounds(PhysicsButtonsPanel, Panel):
 -    bl_label = "Collision Bounds"
 +    bl_label = _("Collision Bounds")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
@@@ -206,8 -207,8 +207,8 @@@ class RenderButtonsPanel()
          return (rd.engine in cls.COMPAT_ENGINES)
  
  
- class RENDER_PT_game(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game(RenderButtonsPanel, Panel):
 -    bl_label = "Game"
 +    bl_label = _("Game")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
          row.label()
  
  
- class RENDER_PT_game_player(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game_player(RenderButtonsPanel, Panel):
 -    bl_label = "Standalone Player"
 +    bl_label = _("Standalone Player")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
              col.prop(gs, "frame_color", text="")
  
  
- class RENDER_PT_game_stereo(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game_stereo(RenderButtonsPanel, Panel):
 -    bl_label = "Stereo"
 +    bl_label = _("Stereo")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
              layout.prop(gs, "dome_text")
  
  
- class RENDER_PT_game_shading(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game_shading(RenderButtonsPanel, Panel):
 -    bl_label = "Shading"
 +    bl_label = _("Shading")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
              split = layout.split()
  
              col = split.column()
 -            col.prop(gs, "use_glsl_lights", text="Lights")
 -            col.prop(gs, "use_glsl_shaders", text="Shaders")
 -            col.prop(gs, "use_glsl_shadows", text="Shadows")
 -            col.prop(gs, "use_glsl_color_management", text="Color Management")
 +            col.prop(gs, "use_glsl_lights", text=_("Lights"))
 +            col.prop(gs, "use_glsl_shaders", text=_("Shaders"))
 +            col.prop(gs, "use_glsl_shadows", text=_("Shadows"))
 +            col.prop(gs, "use_glsl_color_management", text=_("Color Management"))
  
              col = split.column()
 -            col.prop(gs, "use_glsl_ramps", text="Ramps")
 -            col.prop(gs, "use_glsl_nodes", text="Nodes")
 -            col.prop(gs, "use_glsl_extra_textures", text="Extra Textures")
 +            col.prop(gs, "use_glsl_ramps", text=_("Ramps"))
 +            col.prop(gs, "use_glsl_nodes", text=_("Nodes"))
 +            col.prop(gs, "use_glsl_extra_textures", text=_("Extra Textures"))
  
  
- class RENDER_PT_game_performance(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game_performance(RenderButtonsPanel, Panel):
 -    bl_label = "Performance"
 +    bl_label = _("Performance")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
          layout = self.layout
  
          gs = context.scene.game_settings
-         row = layout.row()
+         col = layout.column()
+         row = col.row()
          row.prop(gs, "use_frame_rate")
          row.prop(gs, "use_display_lists")
+         
+         col.prop(gs, "restrict_animation_updates")
  
  
- class RENDER_PT_game_display(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_game_display(RenderButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      def draw(self, context):
  
          gs = context.scene.game_settings
          flow = layout.column_flow()
 -        flow.prop(gs, "show_debug_properties", text="Debug Properties")
 -        flow.prop(gs, "show_framerate_profile", text="Framerate and Profile")
 -        flow.prop(gs, "show_physics_visualization", text="Physics Visualization")
 +        flow.prop(gs, "show_debug_properties", text=_("Debug Properties"))
 +        flow.prop(gs, "show_framerate_profile", text=_("Framerate and Profile"))
 +        flow.prop(gs, "show_physics_visualization", text=_("Physics Visualization"))
          flow.prop(gs, "use_deprecation_warnings")
 -        flow.prop(gs, "show_mouse", text="Mouse Cursor")
 +        flow.prop(gs, "show_mouse", text=_("Mouse Cursor"))
 +
  
- class RENDER_PT_game_sound(RenderButtonsPanel, bpy.types.Panel):
-     bl_label = _("Sound")
-     COMPAT_ENGINES = {'BLENDER_GAME'}
-     def draw(self, context):
-         layout = self.layout
-         scene = context.scene
-         layout.prop(scene, "audio_distance_model")
-         layout.prop(scene, "audio_doppler_speed", text=_("Speed"))
-         layout.prop(scene, "audio_doppler_factor")
  
  class WorldButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -405,8 -394,8 +395,8 @@@ class WORLD_PT_game_context_world(World
              split.template_ID(space, "pin_id")
  
  
- class WORLD_PT_game_world(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_game_world(WorldButtonsPanel, Panel):
 -    bl_label = "World"
 +    bl_label = _("World")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
          row.column().prop(world, "ambient_color")
  
  
- class WORLD_PT_game_mist(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_game_mist(WorldButtonsPanel, Panel):
 -    bl_label = "Mist"
 +    bl_label = _("Mist")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
          row.prop(world.mist_settings, "depth")
  
  
- class WORLD_PT_game_physics(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_game_physics(WorldButtonsPanel, Panel):
 -    bl_label = "Physics"
 +    bl_label = _("Physics")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Menu, Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  def active_node_mat(mat):
      # TODO, 2.4x has a pipeline section, for 2.5 we need to communicate
@@@ -50,15 -51,15 +51,15 @@@ def simple_material(mat)
      return False
  
  
- class MATERIAL_MT_sss_presets(bpy.types.Menu):
+ class MATERIAL_MT_sss_presets(Menu):
 -    bl_label = "SSS Presets"
 +    bl_label = _("SSS Presets")
      preset_subdir = "sss"
      preset_operator = "script.execute_preset"
-     draw = bpy.types.Menu.draw_preset
+     draw = Menu.draw_preset
  
  
- class MATERIAL_MT_specials(bpy.types.Menu):
+ class MATERIAL_MT_specials(Menu):
 -    bl_label = "Material Specials"
 +    bl_label = _("Material Specials")
  
      def draw(self, context):
          layout = self.layout
@@@ -141,19 -142,19 +142,19 @@@ class MATERIAL_PT_context_material(Mate
                  if mat.active_node_material:
                      row.prop(mat.active_node_material, "name", text="")
                  else:
 -                    row.label(text="No material node selected")
 +                    row.label(text=_("No material node selected"))
  
  
- class MATERIAL_PT_preview(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_preview(MaterialButtonsPanel, Panel):
 -    bl_label = "Preview"
 +    bl_label = _("Preview")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
          self.layout.template_preview(context.material)
  
  
- class MATERIAL_PT_pipeline(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_pipeline(MaterialButtonsPanel, Panel):
 -    bl_label = "Render Pipeline Options"
 +    bl_label = _("Render Pipeline Options")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          col.prop(mat, "pass_index")
  
  
- class MATERIAL_PT_diffuse(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_diffuse(MaterialButtonsPanel, Panel):
 -    bl_label = "Diffuse"
 +    bl_label = _("Diffuse")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              col.separator()
  
              row = col.row()
 -            row.prop(mat, "diffuse_ramp_input", text="Input")
 -            row.prop(mat, "diffuse_ramp_blend", text="Blend")
 +            row.prop(mat, "diffuse_ramp_input", text=_("Input"))
 +            row.prop(mat, "diffuse_ramp_blend", text=_("Blend"))
  
 -            col.prop(mat, "diffuse_ramp_factor", text="Factor")
 +            col.prop(mat, "diffuse_ramp_factor", text=_("Factor"))
  
  
- class MATERIAL_PT_specular(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_specular(MaterialButtonsPanel, Panel):
 -    bl_label = "Specular"
 +    bl_label = _("Specular")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              layout.separator()
  
              row = layout.row()
 -            row.prop(mat, "specular_ramp_input", text="Input")
 -            row.prop(mat, "specular_ramp_blend", text="Blend")
 +            row.prop(mat, "specular_ramp_input", text=_("Input"))
 +            row.prop(mat, "specular_ramp_blend", text=_("Blend"))
  
 -            layout.prop(mat, "specular_ramp_factor", text="Factor")
 +            layout.prop(mat, "specular_ramp_factor", text=_("Factor"))
  
  
- class MATERIAL_PT_shading(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_shading(MaterialButtonsPanel, Panel):
 -    bl_label = "Shading"
 +    bl_label = _("Shading")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              sub.prop(mat, "use_cubic")
  
  
- class MATERIAL_PT_transp(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_transp(MaterialButtonsPanel, Panel):
 -    bl_label = "Transparency"
 +    bl_label = _("Transparency")
      # bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
              col.prop(rayt, "depth")
  
              col = split.column()
 -            col.label(text="Gloss:")
 -            col.prop(rayt, "gloss_factor", text="Amount")
 +            col.label(text=_("Gloss:"))
 +            col.prop(rayt, "gloss_factor", text=_("Amount"))
              sub = col.column()
              sub.active = rayt.gloss_factor < 1.0
 -            sub.prop(rayt, "gloss_threshold", text="Threshold")
 -            sub.prop(rayt, "gloss_samples", text="Samples")
 +            sub.prop(rayt, "gloss_threshold", text=_("Threshold"))
 +            sub.prop(rayt, "gloss_samples", text=_("Samples"))
  
  
- class MATERIAL_PT_mirror(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_mirror(MaterialButtonsPanel, Panel):
 -    bl_label = "Mirror"
 +    bl_label = _("Mirror")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(raym, "fade_to", text="")
  
          col = split.column()
 -        col.label(text="Gloss:")
 -        col.prop(raym, "gloss_factor", text="Amount")
 +        col.label(text=_("Gloss:"))
 +        col.prop(raym, "gloss_factor", text=_("Amount"))
          sub = col.column()
          sub.active = raym.gloss_factor < 1.0
 -        sub.prop(raym, "gloss_threshold", text="Threshold")
 -        sub.prop(raym, "gloss_samples", text="Samples")
 -        sub.prop(raym, "gloss_anisotropic", text="Anisotropic")
 +        sub.prop(raym, "gloss_threshold", text=_("Threshold"))
 +        sub.prop(raym, "gloss_samples", text=_("Samples"))
 +        sub.prop(raym, "gloss_anisotropic", text=_("Anisotropic"))
  
  
- class MATERIAL_PT_sss(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_sss(MaterialButtonsPanel, Panel):
 -    bl_label = "Subsurface Scattering"
 +    bl_label = _("Subsurface Scattering")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(sss, "front")
          sub.prop(sss, "back")
          col.separator()
 -        col.prop(sss, "error_threshold", text="Error")
 +        col.prop(sss, "error_threshold", text=_("Error"))
  
  
- class MATERIAL_PT_halo(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_halo(MaterialButtonsPanel, Panel):
 -    bl_label = "Halo"
 +    bl_label = _("Halo")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
          number_but(col, "use_star", "star_tip_count", "Star tips", "")
  
  
- class MATERIAL_PT_flare(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_flare(MaterialButtonsPanel, Panel):
 -    bl_label = "Flare"
 +    bl_label = _("Flare")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
          split = layout.split()
  
          col = split.column()
 -        col.prop(halo, "flare_size", text="Size")
 -        col.prop(halo, "flare_boost", text="Boost")
 -        col.prop(halo, "flare_seed", text="Seed")
 +        col.prop(halo, "flare_size", text=_("Size"))
 +        col.prop(halo, "flare_boost", text=_("Boost"))
 +        col.prop(halo, "flare_seed", text=_("Seed"))
  
          col = split.column()
 -        col.prop(halo, "flare_subflare_count", text="Subflares")
 -        col.prop(halo, "flare_subflare_size", text="Subsize")
 +        col.prop(halo, "flare_subflare_count", text=_("Subflares"))
 +        col.prop(halo, "flare_subflare_size", text=_("Subsize"))
  
  
- class MATERIAL_PT_physics(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_physics(MaterialButtonsPanel, Panel):
 -    bl_label = "Physics"
 +    bl_label = _("Physics")
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
      @classmethod
          row.prop(phys, "use_fh_normal")
  
  
- class MATERIAL_PT_strand(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_strand(MaterialButtonsPanel, Panel):
 -    bl_label = "Strand"
 +    bl_label = _("Strand")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          col.separator()
          sub = col.column()
          sub.active = (not mat.use_shadeless)
 -        sub.label("Surface diffuse:")
 +        sub.label(_("Surface diffuse:"))
          sub = col.column()
 -        sub.prop(tan, "blend_distance", text="Distance")
 +        sub.prop(tan, "blend_distance", text=_("Distance"))
  
  
- class MATERIAL_PT_options(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_options(MaterialButtonsPanel, Panel):
 -    bl_label = "Options"
 +    bl_label = _("Options")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              col.prop(mat, "pass_index")
  
  
- class MATERIAL_PT_shadow(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_shadow(MaterialButtonsPanel, Panel):
 -    bl_label = "Shadow"
 +    bl_label = _("Shadow")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
              col.prop(mat, "use_cast_approximate")
  
  
- class MATERIAL_PT_transp_game(MaterialButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_transp_game(MaterialButtonsPanel, Panel):
 -    bl_label = "Transparency"
 +    bl_label = _("Transparency")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_GAME'}
  
@@@ -824,8 -825,8 +825,8 @@@ class VolumeButtonsPanel()
          return mat and (mat.type == 'VOLUME') and (engine in cls.COMPAT_ENGINES)
  
  
- class MATERIAL_PT_volume_density(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_density(VolumeButtonsPanel, Panel):
 -    bl_label = "Density"
 +    bl_label = _("Density")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          row.prop(vol, "density_scale")
  
  
- class MATERIAL_PT_volume_shading(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_shading(VolumeButtonsPanel, Panel):
 -    bl_label = "Shading"
 +    bl_label = _("Shading")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          sub.prop(vol, "reflection_color", text="")
  
  
- class MATERIAL_PT_volume_lighting(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_lighting(VolumeButtonsPanel, Panel):
 -    bl_label = "Lighting"
 +    bl_label = _("Lighting")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
              sub.prop(vol, "ms_intensity")
  
  
- class MATERIAL_PT_volume_transp(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_transp(VolumeButtonsPanel, Panel):
 -    bl_label = "Transparency"
 +    bl_label = _("Transparency")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
          layout.prop(mat, "transparency_method", expand=True)
  
  
- class MATERIAL_PT_volume_integration(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_integration(VolumeButtonsPanel, Panel):
 -    bl_label = "Integration"
 +    bl_label = _("Integration")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          col.prop(vol, "depth_threshold")
  
  
- class MATERIAL_PT_volume_options(VolumeButtonsPanel, bpy.types.Panel):
+ class MATERIAL_PT_volume_options(VolumeButtonsPanel, Panel):
 -    bl_label = "Options"
 +    bl_label = _("Options")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      bl_options = {'DEFAULT_CLOSED'}
  
          col.prop(mat, "light_group", text="")
          row = col.row()
          row.active = bool(mat.light_group)
 -        row.prop(mat, "use_light_group_exclusive", text="Exclusive")
 +        row.prop(mat, "use_light_group_exclusive", text=_("Exclusive"))
  
  
- class MATERIAL_PT_custom_props(MaterialButtonsPanel, PropertyPanel, bpy.types.Panel):
+ class MATERIAL_PT_custom_props(MaterialButtonsPanel, PropertyPanel, Panel):
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      _context_path = "material"
      _property_type = bpy.types.Material
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class ObjectButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -42,8 -43,8 +43,8 @@@ class OBJECT_PT_context_object(ObjectBu
              row.template_ID(context.scene.objects, "active")
  
  
- class OBJECT_PT_transform(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_transform(ObjectButtonsPanel, Panel):
 -    bl_label = "Transform"
 +    bl_label = _("Transform")
  
      def draw(self, context):
          layout = self.layout
@@@ -68,8 -69,8 +69,8 @@@
          layout.prop(ob, "rotation_mode")
  
  
- class OBJECT_PT_delta_transform(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_delta_transform(ObjectButtonsPanel, Panel):
 -    bl_label = "Delta Transform"
 +    bl_label = _("Delta Transform")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
@@@ -94,8 -95,8 +95,8 @@@
          row.column().prop(ob, "delta_scale")
  
  
- class OBJECT_PT_transform_locks(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_transform_locks(ObjectButtonsPanel, Panel):
 -    bl_label = "Transform Locks"
 +    bl_label = _("Transform Locks")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
                  col.prop(ob, "lock_rotation_w", text="W")
              col.prop(ob, "lock_rotation", text="")
          else:
 -            col.prop(ob, "lock_rotation", text="Rotation")
 +            col.prop(ob, "lock_rotation", text=_("Rotation"))
  
 -        row.column().prop(ob, "lock_scale", text="Scale")
 +        row.column().prop(ob, "lock_scale", text=_("Scale"))
  
  
- class OBJECT_PT_relations(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_relations(ObjectButtonsPanel, Panel):
 -    bl_label = "Relations"
 +    bl_label = _("Relations")
  
      def draw(self, context):
          layout = self.layout
          sub.active = (parent is not None)
  
  
- class OBJECT_PT_groups(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_groups(ObjectButtonsPanel, Panel):
 -    bl_label = "Groups"
 +    bl_label = _("Groups")
  
      def draw(self, context):
          layout = self.layout
                  index += 1
  
  
- class OBJECT_PT_display(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_display(ObjectButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
  
      def draw(self, context):
          layout = self.layout
          split = layout.split()
  
          col = split.column()
 -        col.prop(ob, "show_name", text="Name")
 -        col.prop(ob, "show_axis", text="Axis")
 -        col.prop(ob, "show_wire", text="Wire")
 -        col.prop(ob, "color", text="Object Color")
 +        col.prop(ob, "show_name", text=_("Name"))
 +        col.prop(ob, "show_axis", text=_("Axis"))
 +        col.prop(ob, "show_wire", text=_("Wire"))
 +        col.prop(ob, "color", text=_("Object Color"))
  
          col = split.column()
 -        col.prop(ob, "show_texture_space", text="Texture Space")
 -        col.prop(ob, "show_x_ray", text="X-Ray")
 +        col.prop(ob, "show_texture_space", text=_("Texture Space"))
 +        col.prop(ob, "show_x_ray", text=_("X-Ray"))
          if ob.type == 'MESH':
 -            col.prop(ob, "show_transparent", text="Transparency")
 +            col.prop(ob, "show_transparent", text=_("Transparency"))
  
  
- class OBJECT_PT_duplication(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_duplication(ObjectButtonsPanel, Panel):
 -    bl_label = "Duplication"
 +    bl_label = _("Duplication")
  
      def draw(self, context):
          layout = self.layout
  
  # XXX: the following options are all quite buggy, ancient hacks that should be dropped
  
- class OBJECT_PT_animation(ObjectButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_animation(ObjectButtonsPanel, Panel):
 -    bl_label = "Animation Hacks"
 +    bl_label = _("Animation Hacks")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
@@@ -311,11 -312,11 +312,11 @@@ class OBJECT_PT_motion_paths(MotionPath
          layout.separator()
  
          row = layout.row()
 -        row.operator("object.paths_calculate", text="Calculate Paths")
 -        row.operator("object.paths_clear", text="Clear Paths")
 +        row.operator("object.paths_calculate", text=_("Calculate Paths"))
 +        row.operator("object.paths_clear", text=_("Clear Paths"))
  
  
- class OBJECT_PT_onion_skinning(OnionSkinButtonsPanel):  # , bpy.types.Panel): # inherit from panel when ready
+ class OBJECT_PT_onion_skinning(OnionSkinButtonsPanel):  # , Panel): # inherit from panel when ready
      #bl_label = "Object Onion Skinning"
      bl_context = "object"
  
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class ConstraintButtonsPanel():
      bl_space_type = 'PROPERTIES'
          col.prop(con, "use_limit_z")
          sub = col.column()
          sub.active = con.use_limit_z
 -        sub.prop(con, "min_z", text="Min")
 -        sub.prop(con, "max_z", text="Max")
 +        sub.prop(con, "min_z", text=_("Min"))
 +        sub.prop(con, "max_z", text=_("Max"))
  
-         row = layout.row()
-         row.prop(con, "use_transform_limit")
-         row.label()
+         layout.prop(con, "use_transform_limit")
  
          row = layout.row()
 -        row.label(text="Convert:")
 +        row.label(text=_("Convert:"))
          row.prop(con, "owner_space", text="")
  
      def LIMIT_LOCATION(self, context, layout, con):
          col.operator("constraint.limitdistance_reset")
  
          row = layout.row()
 -        row.label(text="Clamp Region:")
 +        row.label(text=_("Clamp Region:"))
          row.prop(con, "limit_mode", text="")
  
+         row = layout.row()
+         row.prop(con, "use_transform_limit")
+         row.label()
      def STRETCH_TO(self, context, layout, con):
          self.target_template(layout, con)
  
              col = layout.column()
              col.prop(con, "use_relative_location")
              if con.use_relative_location:
 -                col.prop(con, "offset", text="Relative Pivot Point")
 +                col.prop(con, "offset", text=_("Relative Pivot Point"))
              else:
 -                col.prop(con, "offset", text="Absolute Pivot Point")
 +                col.prop(con, "offset", text=_("Absolute Pivot Point"))
  
          col = layout.column()
 -        col.prop(con, "rotation_range", text="Pivot When")
 +        col.prop(con, "rotation_range", text=_("Pivot When"))
  
      def SCRIPT(self, context, layout, con):
 -        layout.label("Blender 2.5 has no py-constraints")
 +        layout.label( _("Blender 2.5 has no py-constraints") )
  
  
- class OBJECT_PT_constraints(ConstraintButtonsPanel, bpy.types.Panel):
+ class OBJECT_PT_constraints(ConstraintButtonsPanel, Panel):
 -    bl_label = "Object Constraints"
 +    bl_label = _("Object Constraints")
      bl_context = "constraint"
  
      @classmethod
              self.draw_constraint(context, con)
  
  
- class BONE_PT_constraints(ConstraintButtonsPanel, bpy.types.Panel):
+ class BONE_PT_constraints(ConstraintButtonsPanel, Panel):
 -    bl_label = "Bone Constraints"
 +    bl_label = _("Bone Constraints")
      bl_context = "bone_constraint"
  
      @classmethod
@@@ -18,8 -18,8 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 +from blf import gettext as _
  
  from bl_ui.properties_physics_common import (
      point_cache_ui,
@@@ -156,8 -156,8 +157,8 @@@ class PARTICLE_PT_context_particles(Par
          if part:
              split = layout.split(percentage=0.65)
              if part.type == 'HAIR':
-                 if psys != None and psys.is_edited:
+                 if psys is not None and psys.is_edited:
 -                    split.operator("particle.edited_clear", text="Free Edit")
 +                    split.operator("particle.edited_clear", text=_("Free Edit"))
                  else:
                      row = split.row()
                      row.enabled = particle_panel_enabled(context, psys)
                          layout.operator("particle.connect_hair")
                      else:
                          layout.operator("particle.disconnect_hair")
-             elif psys != None and part.type == 'REACTOR':
+             elif psys is not None and part.type == 'REACTOR':
                  split.enabled = particle_panel_enabled(context, psys)
                  split.prop(psys, "reactor_target_object")
 -                split.prop(psys, "reactor_target_particle_system", text="Particle System")
 +                split.prop(psys, "reactor_target_particle_system", text=_("Particle System"))
  
  
- class PARTICLE_PT_emission(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_emission(ParticleButtonsPanel, Panel):
 -    bl_label = "Emission"
 +    bl_label = _("Emission")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
  
              row = layout.row()
              if part.distribution == 'JIT':
 -                row.prop(part, "userjit", text="Particles/Face")
 -                row.prop(part, "jitter_factor", text="Jittering Amount", slider=True)
 +                row.prop(part, "userjit", text=_("Particles/Face"))
 +                row.prop(part, "jitter_factor", text=_("Jittering Amount"), slider=True)
              elif part.distribution == 'GRID':
                  row.prop(part, "grid_resolution")
 -                row.prop(part, "grid_random", text="Random", slider=True)
 +                row.prop(part, "grid_random", text=_("Random"), slider=True)
  
  
- class PARTICLE_PT_hair_dynamics(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_hair_dynamics(ParticleButtonsPanel, Panel):
 -    bl_label = "Hair dynamics"
 +    bl_label = _("Hair dynamics")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(cloth, "collider_friction", slider=True)
  
          col = split.column()
 -        col.label(text="Damping:")
 +        col.label(text=_("Damping:"))
          sub = col.column(align=True)
 -        sub.prop(cloth, "spring_damping", text="Spring")
 -        sub.prop(cloth, "air_damping", text="Air")
 +        sub.prop(cloth, "spring_damping", text=_("Spring"))
 +        sub.prop(cloth, "air_damping", text=_("Air"))
  
 -        col.label(text="Quality:")
 -        col.prop(cloth, "quality", text="Steps", slider=True)
 +        col.label(text=_("Quality:"))
 +        col.prop(cloth, "quality", text=_("Steps"), slider=True)
  
  
- class PARTICLE_PT_cache(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_cache(ParticleButtonsPanel, Panel):
 -    bl_label = "Cache"
 +    bl_label = _("Cache")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          point_cache_ui(self, context, psys.point_cache, True, 'HAIR' if (psys.settings.type == 'HAIR') else 'PSYS')
  
  
- class PARTICLE_PT_velocity(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_velocity(ParticleButtonsPanel, Panel):
 -    bl_label = "Velocity"
 +    bl_label = _("Velocity")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
          #    sub.prop(part, "reaction_shape", slider=True)
  
  
- class PARTICLE_PT_rotation(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_rotation(ParticleButtonsPanel, Panel):
 -    bl_label = "Rotation"
 +    bl_label = _("Rotation")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
              col.prop(part, "angular_velocity_factor", text="")
  
  
- class PARTICLE_PT_physics(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_physics(ParticleButtonsPanel, Panel):
 -    bl_label = "Physics"
 +    bl_label = _("Physics")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
                      #doesn't work yet
                      #sub.alert = key.valid
                      sub.prop(key, "object", text="")
 -                    sub.prop(key, "system", text="System")
 +                    sub.prop(key, "system", text=_("System"))
  
  
- class PARTICLE_PT_boidbrain(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_boidbrain(ParticleButtonsPanel, Panel):
 -    bl_label = "Boid Brain"
 +    bl_label = _("Boid Brain")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
                  row.prop(rule, "flee_distance")
  
  
- class PARTICLE_PT_render(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_render(ParticleButtonsPanel, Panel):
 -    bl_label = "Render"
 +    bl_label = _("Render")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
              row.prop(part, "size_random", slider=True)
  
  
- class PARTICLE_PT_draw(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_draw(ParticleButtonsPanel, Panel):
 -    bl_label = "Display"
 +    bl_label = _("Display")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
              col.prop(part, "draw_step")
  
  
- class PARTICLE_PT_children(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_children(ParticleButtonsPanel, Panel):
 -    bl_label = "Children"
 +    bl_label = _("Children")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(part, "kink_shape", slider=True)
  
  
- class PARTICLE_PT_field_weights(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_field_weights(ParticleButtonsPanel, Panel):
 -    bl_label = "Field Weights"
 +    bl_label = _("Field Weights")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
              row.prop(part, "effect_hair", slider=True)
  
  
- class PARTICLE_PT_force_fields(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_force_fields(ParticleButtonsPanel, Panel):
 -    bl_label = "Force Field Settings"
 +    bl_label = _("Force Field Settings")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          basic_force_field_falloff_ui(self, context, part.force_field_2)
  
  
- class PARTICLE_PT_vertexgroups(ParticleButtonsPanel, bpy.types.Panel):
+ class PARTICLE_PT_vertexgroups(ParticleButtonsPanel, Panel):
 -    bl_label = "Vertexgroups"
 +    bl_label = _("Vertexgroups")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Menu, Panel
 +from blf import gettext as _
  
  from bl_ui.properties_physics_common import (
      point_cache_ui,
@@@ -34,10 -35,10 +35,10 @@@ class CLOTH_MT_presets(Menu)
      '''
      Creates the menu items by scanning scripts/templates
      '''
 -    bl_label = "Cloth Presets"
 +    bl_label = _("Cloth Presets")
      preset_subdir = "cloth"
      preset_operator = "script.execute_preset"
-     draw = bpy.types.Menu.draw_preset
+     draw = Menu.draw_preset
  
  
  class PhysicButtonsPanel():
@@@ -52,8 -53,8 +53,8 @@@
          return (ob and ob.type == 'MESH') and (not rd.use_game_engine) and (context.cloth)
  
  
- class PHYSICS_PT_cloth(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_cloth(PhysicButtonsPanel, Panel):
 -    bl_label = "Cloth"
 +    bl_label = _("Cloth")
  
      def draw(self, context):
          layout = self.layout
                  col.prop_search(cloth, "rest_shape_key", key, "key_blocks", text="")
  
  
- class PHYSICS_PT_cloth_cache(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_cloth_cache(PhysicButtonsPanel, Panel):
 -    bl_label = "Cloth Cache"
 +    bl_label = _("Cloth Cache")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          point_cache_ui(self, context, md.point_cache, cloth_panel_enabled(md), 'CLOTH')
  
  
- class PHYSICS_PT_cloth_collision(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_cloth_collision(PhysicButtonsPanel, Panel):
 -    bl_label = "Cloth Collision"
 +    bl_label = _("Cloth Collision")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          layout.prop(cloth, "group")
  
  
- class PHYSICS_PT_cloth_stiffness(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_cloth_stiffness(PhysicButtonsPanel, Panel):
 -    bl_label = "Cloth Stiffness Scaling"
 +    bl_label = _("Cloth Stiffness Scaling")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          split = layout.split()
  
          col = split.column()
 -        col.label(text="Structural Stiffness:")
 +        col.label(text=_("Structural Stiffness:"))
          col.prop_search(cloth, "vertex_group_structural_stiffness", ob, "vertex_groups", text="")
 -        col.prop(cloth, "structural_stiffness_max", text="Max")
 +        col.prop(cloth, "structural_stiffness_max", text=_("Max"))
  
          col = split.column()
 -        col.label(text="Bending Stiffness:")
 +        col.label(text=_("Bending Stiffness:"))
          col.prop_search(cloth, "vertex_group_bending", ob, "vertex_groups", text="")
 -        col.prop(cloth, "bending_stiffness_max", text="Max")
 +        col.prop(cloth, "bending_stiffness_max", text=_("Max"))
  
  
- class PHYSICS_PT_cloth_field_weights(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_cloth_field_weights(PhysicButtonsPanel, Panel):
 -    bl_label = "Cloth Field Weights"
 +    bl_label = _("Cloth Field Weights")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -19,7 -19,8 +19,8 @@@
  # <pep8 compliant>
  
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class PhysicButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  from bl_ui.properties_physics_common import (
      basic_force_field_settings_ui,
@@@ -37,8 -38,8 +38,8 @@@ class PhysicButtonsPanel()
          return (context.object) and (not rd.use_game_engine)
  
  
- class PHYSICS_PT_field(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_field(PhysicButtonsPanel, Panel):
 -    bl_label = "Force Fields"
 +    bl_label = _("Force Fields")
  
      @classmethod
      def poll(cls, context):
  
                  sub = col.column()
                  sub.active = field.use_radial_max
 -                sub.prop(field, "radial_max", text="Distance")
 +                sub.prop(field, "radial_max", text=_("Distance"))
  
  
- class PHYSICS_PT_collision(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_collision(PhysicButtonsPanel, Panel):
 -    bl_label = "Collision"
 +    bl_label = _("Collision")
      #bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  class PhysicButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -32,8 -33,8 +33,8 @@@
          return (ob and ob.type == 'MESH') and (not rd.use_game_engine) and (context.fluid)
  
  
- class PHYSICS_PT_fluid(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_fluid(PhysicButtonsPanel, Panel):
 -    bl_label = "Fluid"
 +    bl_label = _("Fluid")
  
      def draw(self, context):
          layout = self.layout
                  split = layout.split()
  
                  col = split.column()
 -                col.label(text="Attraction Force:")
 +                col.label(text=_("Attraction Force:"))
                  sub = col.column(align=True)
 -                sub.prop(fluid, "attraction_strength", text="Strength")
 -                sub.prop(fluid, "attraction_radius", text="Radius")
 +                sub.prop(fluid, "attraction_strength", text=_("Strength"))
 +                sub.prop(fluid, "attraction_radius", text=_("Radius"))
  
                  col = split.column()
 -                col.label(text="Velocity Force:")
 +                col.label(text=_("Velocity Force:"))
                  sub = col.column(align=True)
 -                sub.prop(fluid, "velocity_strength", text="Strength")
 -                sub.prop(fluid, "velocity_radius", text="Radius")
 +                sub.prop(fluid, "velocity_strength", text=_("Strength"))
 +                sub.prop(fluid, "velocity_radius", text=_("Radius"))
  
  
- class PHYSICS_PT_domain_gravity(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_domain_gravity(PhysicButtonsPanel, Panel):
 -    bl_label = "Domain World"
 +    bl_label = _("Domain World")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          col.prop(fluid, "compressibility", slider=True)
  
  
- class PHYSICS_PT_domain_boundary(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_domain_boundary(PhysicButtonsPanel, Panel):
 -    bl_label = "Domain Boundary"
 +    bl_label = _("Domain Boundary")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          col.prop(fluid, "surface_noobs")
  
          col = split.column()
 -        col.label(text="Surface:")
 -        col.prop(fluid, "surface_smooth", text="Smoothing")
 -        col.prop(fluid, "surface_subdivisions", text="Subdivisions")
 +        col.label(text=_("Surface:"))
 +        col.prop(fluid, "surface_smooth", text=_("Smoothing"))
 +        col.prop(fluid, "surface_subdivisions", text=_("Subdivisions"))
  
  
- class PHYSICS_PT_domain_particles(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_domain_particles(PhysicButtonsPanel, Panel):
 -    bl_label = "Domain Particles"
 +    bl_label = _("Domain Particles")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  from bl_ui.properties_physics_common import (
      point_cache_ui,
@@@ -38,8 -39,8 +39,8 @@@ class PhysicButtonsPanel()
          return (ob and ob.type == 'MESH') and (not rd.use_game_engine) and (context.smoke)
  
  
- class PHYSICS_PT_smoke(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_smoke(PhysicButtonsPanel, Panel):
 -    bl_label = "Smoke"
 +    bl_label = _("Smoke")
  
      def draw(self, context):
          layout = self.layout
                  sub.prop(flow, "temperature")
  
  
- class PHYSICS_PT_smoke_groups(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_smoke_groups(PhysicButtonsPanel, Panel):
 -    bl_label = "Smoke Groups"
 +    bl_label = _("Smoke Groups")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          col.prop(group, "collision_group", text="")
  
  
- class PHYSICS_PT_smoke_highres(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_smoke_highres(PhysicButtonsPanel, Panel):
 -    bl_label = "Smoke High Resolution"
 +    bl_label = _("Smoke High Resolution")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          layout.prop(md, "show_high_resolution")
  
  
- class PHYSICS_PT_smoke_cache(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_smoke_cache(PhysicButtonsPanel, Panel):
 -    bl_label = "Smoke Cache"
 +    bl_label = _("Smoke Cache")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          point_cache_ui(self, context, cache, (cache.is_baked is False), 'SMOKE')
  
  
- class PHYSICS_PT_smoke_field_weights(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_smoke_field_weights(PhysicButtonsPanel, Panel):
 -    bl_label = "Smoke Field Weights"
 +    bl_label = _("Smoke Field Weights")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -18,7 -18,8 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
 -
+ from bpy.types import Panel
 +from blf import gettext as _
  
  from bl_ui.properties_physics_common import (
      point_cache_ui,
@@@ -44,8 -45,8 +45,8 @@@ class PhysicButtonsPanel()
          return (ob and (ob.type == 'MESH' or ob.type == 'LATTICE'or ob.type == 'CURVE')) and (not rd.use_game_engine) and (context.soft_body)
  
  
- class PHYSICS_PT_softbody(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body"
 +    bl_label = _("Soft Body")
  
      def draw(self, context):
          layout = self.layout
@@@ -71,8 -72,8 +72,8 @@@
              col.prop(softbody, "speed")
  
  
- class PHYSICS_PT_softbody_cache(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_cache(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Cache"
 +    bl_label = _("Soft Body Cache")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
@@@ -84,8 -85,8 +85,8 @@@
          point_cache_ui(self, context, md.point_cache, softbody_panel_enabled(md), 'SOFTBODY')
  
  
- class PHYSICS_PT_softbody_goal(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_goal(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Goal"
 +    bl_label = _("Soft Body Goal")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          split = layout.split()
  
          col = split.column()
 -        col.label(text="Goal Strengths:")
 -        col.prop(softbody, "goal_default", text="Default")
 +        col.label(text=_("Goal Strengths:"))
 +        col.prop(softbody, "goal_default", text=_("Default"))
          sub = col.column(align=True)
 -        sub.prop(softbody, "goal_min", text="Minimum")
 -        sub.prop(softbody, "goal_max", text="Maximum")
 +        sub.prop(softbody, "goal_min", text=_("Minimum"))
 +        sub.prop(softbody, "goal_max", text=_("Maximum"))
  
          col = split.column()
 -        col.label(text="Goal Settings:")
 -        col.prop(softbody, "goal_spring", text="Stiffness")
 -        col.prop(softbody, "goal_friction", text="Damping")
 +        col.label(text=_("Goal Settings:"))
 +        col.prop(softbody, "goal_spring", text=_("Stiffness"))
 +        col.prop(softbody, "goal_friction", text=_("Damping"))
  
 -        layout.prop_search(softbody, "vertex_group_goal", ob, "vertex_groups", text="Vertex Group")
 +        layout.prop_search(softbody, "vertex_group_goal", ob, "vertex_groups", text=_("Vertex Group"))
  
  
- class PHYSICS_PT_softbody_edge(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_edge(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Edges"
 +    bl_label = _("Soft Body Edges")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          #sub = col.column()
          #sub.enabled = softbody.aero > 0
  
 -        col.label(text="Collision:")
 -        col.prop(softbody, "use_edge_collision", text="Edge")
 -        col.prop(softbody, "use_face_collision", text="Face")
 +        col.label(text=_("Collision:"))
 +        col.prop(softbody, "use_edge_collision", text=_("Edge"))
 +        col.prop(softbody, "use_face_collision", text=_("Face"))
  
  
- class PHYSICS_PT_softbody_collision(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_collision(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Self Collision"
 +    bl_label = _("Soft Body Self Collision")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          layout.prop(softbody, "collision_type", expand=True)
  
          col = layout.column(align=True)
 -        col.label(text="Ball:")
 -        col.prop(softbody, "ball_size", text="Size")
 -        col.prop(softbody, "ball_stiff", text="Stiffness")
 -        col.prop(softbody, "ball_damp", text="Dampening")
 +        col.label(text=_("Ball:"))
 +        col.prop(softbody, "ball_size", text=_("Size"))
 +        col.prop(softbody, "ball_stiff", text=_("Stiffness"))
 +        col.prop(softbody, "ball_damp", text=_("Dampening"))
  
  
- class PHYSICS_PT_softbody_solver(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_solver(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Solver"
 +    bl_label = _("Soft Body Solver")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
          layout.prop(softbody, "use_estimate_matrix")
  
  
- class PHYSICS_PT_softbody_field_weights(PhysicButtonsPanel, bpy.types.Panel):
+ class PHYSICS_PT_softbody_field_weights(PhysicButtonsPanel, Panel):
 -    bl_label = "Soft Body Field Weights"
 +    bl_label = _("Soft Body Field Weights")
      bl_options = {'DEFAULT_CLOSED'}
  
      @classmethod
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Menu, Panel
 +from blf import gettext as _
  
  
- class RENDER_MT_presets(bpy.types.Menu):
+ class RENDER_MT_presets(Menu):
 -    bl_label = "Render Presets"
 +    bl_label = _("Render Presets")
      preset_subdir = "render"
      preset_operator = "script.execute_preset"
-     draw = bpy.types.Menu.draw_preset
+     draw = Menu.draw_preset
  
  
- class RENDER_MT_ffmpeg_presets(bpy.types.Menu):
+ class RENDER_MT_ffmpeg_presets(Menu):
 -    bl_label = "FFMPEG Presets"
 +    bl_label = _("FFMPEG Presets")
      preset_subdir = "ffmpeg"
      preset_operator = "script.python_file_run"
-     draw = bpy.types.Menu.draw_preset
+     draw = Menu.draw_preset
  
  
- class RENDER_MT_framerate_presets(bpy.types.Menu):
+ class RENDER_MT_framerate_presets(Menu):
 -    bl_label = "Frame Rate Presets"
 +    bl_label = _("Frame Rate Presets")
      preset_subdir = "framerate"
      preset_operator = "script.execute_preset"
-     draw = bpy.types.Menu.draw_preset
+     draw = Menu.draw_preset
  
  
  class RenderButtonsPanel():
@@@ -54,8 -54,8 +55,8 @@@
          return (context.scene and rd.use_game_engine is False) and (rd.engine in cls.COMPAT_ENGINES)
  
  
- class RENDER_PT_render(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_render(RenderButtonsPanel, Panel):
 -    bl_label = "Render"
 +    bl_label = _("Render")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          rd = context.scene.render
  
          row = layout.row()
 -        row.operator("render.render", text="Image", icon='RENDER_STILL')
 -        row.operator("render.render", text="Animation", icon='RENDER_ANIMATION').animation = True
 +        row.operator("render.render", text=_("Image"), icon='RENDER_STILL')
 +        row.operator("render.render", text=_("Animation"), icon='RENDER_ANIMATION').animation = True
  
 -        layout.prop(rd, "display_mode", text="Display")
 +        layout.prop(rd, "display_mode", text=_("Display"))
  
  
- class RENDER_PT_layers(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_layers(RenderButtonsPanel, Panel):
 -    bl_label = "Layers"
 +    bl_label = _("Layers")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          row.prop(rl, "exclude_refraction", text="")
  
  
- class RENDER_PT_dimensions(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_dimensions(RenderButtonsPanel, Panel):
 -    bl_label = "Dimensions"
 +    bl_label = _("Dimensions")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
              sub.prop(rd, "fps")
              sub.prop(rd, "fps_base", text="/")
          subrow = sub.row(align=True)
 -        subrow.label(text="Time Remapping:")
 +        subrow.label(text=_("Time Remapping:"))
          subrow = sub.row(align=True)
 -        subrow.prop(rd, "frame_map_old", text="Old")
 -        subrow.prop(rd, "frame_map_new", text="New")
 +        subrow.prop(rd, "frame_map_old", text=_("Old"))
 +        subrow.prop(rd, "frame_map_new", text=_("New"))
  
  
- class RENDER_PT_antialiasing(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_antialiasing(RenderButtonsPanel, Panel):
 -    bl_label = "Anti-Aliasing"
 +    bl_label = _("Anti-Aliasing")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
  
          col = split.column()
          col.prop(rd, "pixel_filter_type", text="")
 -        col.prop(rd, "filter_size", text="Size")
 +        col.prop(rd, "filter_size", text=_("Size"))
  
  
- class RENDER_PT_motion_blur(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_motion_blur(RenderButtonsPanel, Panel):
 -    bl_label = "Sampled Motion Blur"
 +    bl_label = _("Sampled Motion Blur")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          row.prop(rd, "motion_blur_shutter")
  
  
- class RENDER_PT_shading(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_shading(RenderButtonsPanel, Panel):
 -    bl_label = "Shading"
 +    bl_label = _("Shading")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          split = layout.split()
  
          col = split.column()
 -        col.prop(rd, "use_textures", text="Textures")
 -        col.prop(rd, "use_shadows", text="Shadows")
 -        col.prop(rd, "use_sss", text="Subsurface Scattering")
 -        col.prop(rd, "use_envmaps", text="Environment Map")
 +        col.prop(rd, "use_textures", text=_("Textures"))
 +        col.prop(rd, "use_shadows", text=_("Shadows"))
 +        col.prop(rd, "use_sss", text=_("Subsurface Scattering"))
 +        col.prop(rd, "use_envmaps", text=_("Environment Map"))
  
          col = split.column()
 -        col.prop(rd, "use_raytrace", text="Ray Tracing")
 +        col.prop(rd, "use_raytrace", text=_("Ray Tracing"))
          col.prop(rd, "use_color_management")
 -        col.prop(rd, "alpha_mode", text="Alpha")
 +        col.prop(rd, "alpha_mode", text=_("Alpha"))
  
  
- class RENDER_PT_performance(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_performance(RenderButtonsPanel, Panel):
 -    bl_label = "Performance"
 +    bl_label = _("Performance")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(rd, "use_free_unused_nodes")
          sub = col.column()
          sub.active = rd.use_raytrace
 -        sub.label(text="Acceleration structure:")
 +        sub.label(text=_("Acceleration structure:"))
          sub.prop(rd, "raytrace_method", text="")
          if rd.raytrace_method == 'OCTREE':
 -            sub.prop(rd, "octree_resolution", text="Resolution")
 +            sub.prop(rd, "octree_resolution", text=_("Resolution"))
          else:
 -            sub.prop(rd, "use_instances", text="Instances")
 -        sub.prop(rd, "use_local_coords", text="Local Coordinates")
 +            sub.prop(rd, "use_instances", text=_("Instances"))
 +        sub.prop(rd, "use_local_coords", text=_("Local Coordinates"))
  
  
- class RENDER_PT_post_processing(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_post_processing(RenderButtonsPanel, Panel):
 -    bl_label = "Post Processing"
 +    bl_label = _("Post Processing")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(rd, "edge_color", text="")
  
  
- class RENDER_PT_stamp(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_stamp(RenderButtonsPanel, Panel):
 -    bl_label = "Stamp"
 +    bl_label = _("Stamp")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          sub.prop(rd, "stamp_note_text", text="")
  
  
- class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_output(RenderButtonsPanel, Panel):
 -    bl_label = "Output"
 +    bl_label = _("Output")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
                  col.prop(rd, "quicktime_audio_resampling_hq")
  
  
- class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_encoding(RenderButtonsPanel, Panel):
 -    bl_label = "Encoding"
 +    bl_label = _("Encoding")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
  
          # Audio:
          if rd.ffmpeg_format not in {'MP3'}:
 -            layout.prop(rd, "ffmpeg_audio_codec", text="Audio Codec")
 +            layout.prop(rd, "ffmpeg_audio_codec", text=_("Audio Codec"))
  
-         split = layout.split()
-         col = split.column()
-         col.prop(rd, "ffmpeg_audio_bitrate")
-         col.prop(rd, "ffmpeg_audio_mixrate")
-         split.prop(rd, "ffmpeg_audio_volume", slider=True)
+         row = layout.row()
+         row.prop(rd, "ffmpeg_audio_bitrate")
+         row.prop(rd, "ffmpeg_audio_volume", slider=True)
  
  
- class RENDER_PT_bake(RenderButtonsPanel, bpy.types.Panel):
+ class RENDER_PT_bake(RenderButtonsPanel, Panel):
 -    bl_label = "Bake"
 +    bl_label = _("Bake")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
@@@ -18,8 -18,9 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Operator, Panel
  from rna_prop_ui import PropertyPanel
 -
 +from blf import gettext as _
  
  class SceneButtonsPanel():
      bl_space_type = 'PROPERTIES'
@@@ -31,8 -32,8 +32,8 @@@
          return context.scene
  
  
- class SCENE_PT_scene(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_scene(SceneButtonsPanel, Panel):
 -    bl_label = "Scene"
 +    bl_label = _("Scene")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          scene = context.scene
  
          layout.prop(scene, "camera")
 -        layout.prop(scene, "background_set", text="Background")
 +        layout.prop(scene, "background_set", text=_("Background"))
  
  
- class SCENE_PT_unit(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_audio(SceneButtonsPanel, Panel):
 -    bl_label = "Audio"
++    bl_label = _("Audio")
+     COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
+     def draw(self, context):
+         layout = self.layout
+         scene = context.scene
+         rd = context.scene.render
+         layout.prop(scene, "audio_volume")
+         layout.operator("sound.bake_animation")
+         split = layout.split()
+         col = split.column()
 -        col.label("Listener:")
++        col.label(_("Listener:"))
+         col.prop(scene, "audio_distance_model", text="")
 -        col.prop(scene, "audio_doppler_speed", text="Speed")
 -        col.prop(scene, "audio_doppler_factor", text="Doppler")
++        col.prop(scene, "audio_doppler_speed", text=_("Speed"))
++        col.prop(scene, "audio_doppler_factor", text=_("Doppler"))
+         col = split.column()
 -        col.label("Format:")
++        col.label(_("Format:"))
+         col.prop(rd, "ffmpeg_audio_channels", text="")
 -        col.prop(rd, "ffmpeg_audio_mixrate", text="Rate")
++        col.prop(rd, "ffmpeg_audio_mixrate", text=_("Rate"))
+         layout.operator("sound.mixdown")
+ class SCENE_PT_unit(SceneButtonsPanel, Panel):
 -    bl_label = "Units"
 +    bl_label = _("Units")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
@@@ -61,8 -90,8 +90,8 @@@
          row.prop(unit, "use_separate")
  
  
- class SCENE_PT_keying_sets(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_keying_sets(SceneButtonsPanel, Panel):
 -    bl_label = "Keying Sets"
 +    bl_label = _("Keying Sets")
  
      def draw(self, context):
          layout = self.layout
              col.prop(ks, "bl_options")
  
  
- class SCENE_PT_keying_set_paths(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_keying_set_paths(SceneButtonsPanel, Panel):
 -    bl_label = "Active Keying Set"
 +    bl_label = _("Active Keying Set")
  
      @classmethod
      def poll(cls, context):
              col.prop(ksp, "bl_options")
  
  
- class SCENE_PT_physics(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_physics(SceneButtonsPanel, Panel):
 -    bl_label = "Gravity"
 +    bl_label = _("Gravity")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
          layout.prop(scene, "gravity", text="")
  
  
- class SCENE_PT_simplify(SceneButtonsPanel, bpy.types.Panel):
+ class SCENE_PT_simplify(SceneButtonsPanel, Panel):
 -    bl_label = "Simplify"
 +    bl_label = _("Simplify")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
          col.prop(rd, "use_simplify_triangulate")
  
          col = split.column()
 -        col.prop(rd, "simplify_shadow_samples", text="Shadow Samples")
 -        col.prop(rd, "simplify_ao_sss", text="AO and SSS")
 +        col.prop(rd, "simplify_shadow_samples", text=_("Shadow Samples"))
 +        col.prop(rd, "simplify_ao_sss", text=_("AO and SSS"))
  
  
- class SCENE_PT_custom_props(SceneButtonsPanel, PropertyPanel, bpy.types.Panel):
+ class SCENE_PT_custom_props(SceneButtonsPanel, PropertyPanel, Panel):
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      _context_path = "scene"
      _property_type = bpy.types.Scene
  #  XXX, move operator to op/ dir
  
  
- class ANIM_OT_keying_set_export(bpy.types.Operator):
+ 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:
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Menu, Panel
  from rna_prop_ui import PropertyPanel
 +from blf import gettext as _
  
  
- class TEXTURE_MT_specials(bpy.types.Menu):
+ class TEXTURE_MT_specials(Menu):
 -    bl_label = "Texture Specials"
 +    bl_label = _("Texture Specials")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
@@@ -33,8 -33,8 +34,8 @@@
          layout.operator("texture.slot_paste", icon='PASTEDOWN')
  
  
- class TEXTURE_MT_envmap_specials(bpy.types.Menu):
+ class TEXTURE_MT_envmap_specials(Menu):
 -    bl_label = "Environment Map Specials"
 +    bl_label = _("Environment Map Specials")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
@@@ -151,8 -151,8 +152,8 @@@ class TEXTURE_PT_context_texture(Textur
                  split.prop(tex, "type", text="")
  
  
- class TEXTURE_PT_preview(TextureButtonsPanel, bpy.types.Panel):
+ class TEXTURE_PT_preview(TextureButtonsPanel, Panel):
 -    bl_label = "Preview"
 +    bl_label = _("Preview")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      def draw(self, context):
              layout.template_preview(tex, slot=slot)
  
  
- class TEXTURE_PT_colors(TextureButtonsPanel, bpy.types.Panel):
+ class TEXTURE_PT_colors(TextureButtonsPanel, Panel):
 -    bl_label = "Colors"
 +    bl_label = _("Colors")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
@@@ -224,8 -224,8 +225,8 @@@ class TextureTypePanel(TextureButtonsPa
          return tex and ((tex.type == cls.tex_type and not tex.use_nodes) and (engine in cls.COMPAT_ENGINES))
  
  
- class TEXTURE_PT_clouds(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_clouds(TextureTypePanel, Panel):
 -    bl_label = "Clouds"
 +    bl_label = _("Clouds")
      tex_type = 'CLOUDS'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          split = layout.split()
  
          col = split.column()
 -        col.prop(tex, "noise_scale", text="Size")
 -        col.prop(tex, "noise_depth", text="Depth")
 +        col.prop(tex, "noise_scale", text=_("Size"))
 +        col.prop(tex, "noise_depth", text=_("Depth"))
  
 -        split.prop(tex, "nabla", text="Nabla")
 +        split.prop(tex, "nabla", text=_("Nabla"))
  
  
- class TEXTURE_PT_wood(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_wood(TextureTypePanel, Panel):
 -    bl_label = "Wood"
 +    bl_label = _("Wood")
      tex_type = 'WOOD'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          split.prop(tex, "nabla")
  
  
- class TEXTURE_PT_marble(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_marble(TextureTypePanel, Panel):
 -    bl_label = "Marble"
 +    bl_label = _("Marble")
      tex_type = 'MARBLE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          col.prop(tex, "nabla")
  
  
- class TEXTURE_PT_magic(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_magic(TextureTypePanel, Panel):
 -    bl_label = "Magic"
 +    bl_label = _("Magic")
      tex_type = 'MAGIC'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          row.prop(tex, "turbulence")
  
  
- class TEXTURE_PT_blend(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_blend(TextureTypePanel, Panel):
 -    bl_label = "Blend"
 +    bl_label = _("Blend")
      tex_type = 'BLEND'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          sub.prop(tex, "use_flip_axis", expand=True)
  
  
- class TEXTURE_PT_stucci(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_stucci(TextureTypePanel, Panel):
 -    bl_label = "Stucci"
 +    bl_label = _("Stucci")
      tex_type = 'STUCCI'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          row.prop(tex, "turbulence")
  
  
- class TEXTURE_PT_image(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_image(TextureTypePanel, Panel):
 -    bl_label = "Image"
 +    bl_label = _("Image")
      tex_type = 'IMAGE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
@@@ -383,8 -383,8 +384,8 @@@ def texture_filter_common(tex, layout)
      layout.prop(tex, "use_filter_size_min")
  
  
- class TEXTURE_PT_image_sampling(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_image_sampling(TextureTypePanel, Panel):
 -    bl_label = "Image Sampling"
 +    bl_label = _("Image Sampling")
      bl_options = {'DEFAULT_CLOSED'}
      tex_type = 'IMAGE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
          texture_filter_common(tex, col)
  
  
- class TEXTURE_PT_image_mapping(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_image_mapping(TextureTypePanel, Panel):
 -    bl_label = "Image Mapping"
 +    bl_label = _("Image Mapping")
      bl_options = {'DEFAULT_CLOSED'}
      tex_type = 'IMAGE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
          col.prop(tex, "crop_max_y", text="Y")
  
  
- class TEXTURE_PT_envmap(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_envmap(TextureTypePanel, Panel):
 -    bl_label = "Environment Map"
 +    bl_label = _("Environment Map")
      tex_type = 'ENVIRONMENT_MAP'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
  
              col = split.column(align=True)
  
 -            col.label(text="Clipping:")
 -            col.prop(env, "clip_start", text="Start")
 -            col.prop(env, "clip_end", text="End")
 +            col.label(text=_("Clipping:"))
 +            col.prop(env, "clip_start", text=_("Start"))
 +            col.prop(env, "clip_end", text=_("End"))
  
  
- class TEXTURE_PT_envmap_sampling(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_envmap_sampling(TextureTypePanel, Panel):
 -    bl_label = "Environment Map Sampling"
 +    bl_label = _("Environment Map Sampling")
      bl_options = {'DEFAULT_CLOSED'}
      tex_type = 'ENVIRONMENT_MAP'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
          texture_filter_common(tex, layout)
  
  
- class TEXTURE_PT_musgrave(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_musgrave(TextureTypePanel, Panel):
 -    bl_label = "Musgrave"
 +    bl_label = _("Musgrave")
      tex_type = 'MUSGRAVE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          row.prop(tex, "nabla")
  
  
- class TEXTURE_PT_voronoi(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_voronoi(TextureTypePanel, Panel):
 -    bl_label = "Voronoi"
 +    bl_label = _("Voronoi")
      tex_type = 'VORONOI'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          row.prop(tex, "nabla")
  
  
- class TEXTURE_PT_distortednoise(TextureTypePanel, bpy.types.Panel):
+ class TEXTURE_PT_distortednoise(TextureTypePanel, Panel):
 -    bl_label = "Distorted Noise"
 +    bl_label = _("Distorted Noise")
      tex_type = 'DISTORTED_NOISE'
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
          split.prop(tex, "nabla")
  
  
- class TEXTURE_PT_voxeldata(TextureButtonsPanel, bpy.types.Panel):
+ class TEXTURE_PT_voxeldata(TextureButtonsPanel, Panel):
 -    bl_label = "Voxel Data"
 +    bl_label = _("Voxel Data")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
          layout.prop(vd, "intensity")
  
  
- class TEXTURE_PT_pointdensity(TextureButtonsPanel, bpy.types.Panel):
+ class TEXTURE_PT_pointdensity(TextureButtonsPanel, Panel):
 -    bl_label = "Point Density"
 +    bl_label = _("Point Density")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
              col.template_curve_mapping(pd, "falloff_curve", brush=False)
  
  
- class TEXTURE_PT_pointdensity_turbulence(TextureButtonsPanel, bpy.types.Panel):
+ class TEXTURE_PT_pointdensity_turbulence(TextureButtonsPanel, Panel):
 -    bl_label = "Turbulence"
 +    bl_label = _("Turbulence")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
          col.prop(pd, "turbulence_strength")
  
  
- class TEXTURE_PT_mapping(TextureSlotPanel, bpy.types.Panel):
+ class TEXTURE_PT_mapping(TextureSlotPanel, Panel):
 -    bl_label = "Mapping"
 +    bl_label = _("Mapping")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
          row.column().prop(tex, "scale")
  
  
- class TEXTURE_PT_influence(TextureSlotPanel, bpy.types.Panel):
+ class TEXTURE_PT_influence(TextureSlotPanel, Panel):
 -    bl_label = "Influence"
 +    bl_label = _("Influence")
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
  
      @classmethod
  
              # only show bump settings if activated but not for normalmap images
              row = layout.row()
-             row.active = (tex.use_map_normal or tex.use_map_warp) and not (tex.texture.type == 'IMAGE' and tex.texture.use_normal_map)
  
-             row.prop(tex, "bump_method", text=_("Method"))
+             sub = row.row()
+             sub.active = (tex.use_map_normal or tex.use_map_warp) and not (tex.texture.type == 'IMAGE' and (tex.texture.use_normal_map or tex.texture.use_derivative_map))
 -            sub.prop(tex, "bump_method", text="Method")
++            sub.prop(tex, "bump_method", text=_("Method"))
  
+             # the space setting is supported for: derivmaps + bumpmaps (DEFAULT,BEST_QUALITY), not for normalmaps
              sub = row.row()
-             sub.active = tex.bump_method in {'BUMP_DEFAULT', 'BUMP_BEST_QUALITY'}
+             sub.active = (tex.use_map_normal or tex.use_map_warp) and not (tex.texture.type == 'IMAGE' and tex.texture.use_normal_map) and ((tex.bump_method in {'BUMP_DEFAULT', 'BUMP_BEST_QUALITY'}) or (tex.texture.type == 'IMAGE' and tex.texture.use_derivative_map))
 -            sub.prop(tex, "bump_objectspace", text="Space")
 +            sub.prop(tex, "bump_objectspace", text=_("Space"))
  
  
- class TEXTURE_PT_custom_props(TextureButtonsPanel, PropertyPanel, bpy.types.Panel):
+ class TEXTURE_PT_custom_props(TextureButtonsPanel, PropertyPanel, Panel):
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      _context_path = "texture"
      _property_type = bpy.types.Texture
@@@ -18,8 -18,8 +18,9 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Panel
  from rna_prop_ui import PropertyPanel
 +from blf import gettext as _
  
  
  class WorldButtonsPanel():
@@@ -62,8 -62,8 +63,8 @@@ class WORLD_PT_context_world(WorldButto
              split.label(text=str(texture_count), icon='TEXTURE')
  
  
- class WORLD_PT_preview(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_preview(WorldButtonsPanel, Panel):
 -    bl_label = "Preview"
 +    bl_label = _("Preview")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      @classmethod
@@@ -75,8 -75,8 +76,8 @@@
          self.layout.template_preview(context.world)
  
  
- class WORLD_PT_world(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_world(WorldButtonsPanel, Panel):
 -    bl_label = "World"
 +    bl_label = _("World")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
          row.prop(world, "color_range")
  
  
- class WORLD_PT_ambient_occlusion(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_ambient_occlusion(WorldButtonsPanel, Panel):
 -    bl_label = "Ambient Occlusion"
 +    bl_label = _("Ambient Occlusion")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
          split.prop(light, "ao_blend_type", text="")
  
  
- class WORLD_PT_environment_lighting(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_environment_lighting(WorldButtonsPanel, Panel):
 -    bl_label = "Environment Lighting"
 +    bl_label = _("Environment Lighting")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
          split.prop(light, "environment_color", text="")
  
  
- class WORLD_PT_indirect_lighting(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_indirect_lighting(WorldButtonsPanel, Panel):
 -    bl_label = "Indirect Lighting"
 +    bl_label = _("Indirect Lighting")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw_header(self, context):
          layout.active = light.use_indirect_light and light.gather_method == 'APPROXIMATE'
  
          split = layout.split()
 -        split.prop(light, "indirect_factor", text="Factor")
 -        split.prop(light, "indirect_bounces", text="Bounces")
 +        split.prop(light, "indirect_factor", text=_("Factor"))
 +        split.prop(light, "indirect_bounces", text=_("Bounces"))
  
          if light.gather_method == 'RAYTRACE':
 -            layout.label(text="Only works with Approximate gather method")
 +            layout.label(text=_("Only works with Approximate gather method"))
  
  
- class WORLD_PT_gather(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_gather(WorldButtonsPanel, Panel):
 -    bl_label = "Gather"
 +    bl_label = _("Gather")
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
      def draw(self, context):
              col.prop(light, "correction")
  
  
- class WORLD_PT_mist(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_mist(WorldButtonsPanel, Panel):
 -    bl_label = "Mist"
 +    bl_label = _("Mist")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
          layout.prop(world.mist_settings, "falloff")
  
  
- class WORLD_PT_stars(WorldButtonsPanel, bpy.types.Panel):
+ class WORLD_PT_stars(WorldButtonsPanel, Panel):
 -    bl_label = "Stars"
 +    bl_label = _("Stars")
      bl_options = {'DEFAULT_CLOSED'}
      COMPAT_ENGINES = {'BLENDER_RENDER'}
  
  
          col = split.column()
          col.prop(world.star_settings, "size")
 -        col.prop(world.star_settings, "color_random", text="Colors")
 +        col.prop(world.star_settings, "color_random", text=_("Colors"))
  
          col = split.column()
 -        col.prop(world.star_settings, "distance_min", text="Min. Dist")
 -        col.prop(world.star_settings, "average_separation", text="Separation")
 +        col.prop(world.star_settings, "distance_min", text=_("Min. Dist"))
 +        col.prop(world.star_settings, "average_separation", text=_("Separation"))
  
  
- class WORLD_PT_custom_props(WorldButtonsPanel, PropertyPanel, bpy.types.Panel):
+ class WORLD_PT_custom_props(WorldButtonsPanel, PropertyPanel, Panel):
      COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_GAME'}
      _context_path = "world"
      _property_type = bpy.types.World
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Header, Menu, Operator
  from bpy.props import StringProperty
 +from blf import gettext as _
  
  
- class CONSOLE_HT_header(bpy.types.Header):
+ class CONSOLE_HT_header(Header):
      bl_space_type = 'CONSOLE'
  
      def draw(self, context):
-         layout = self.layout
+         layout = self.layout.row(align=True)
  
-         row = layout.row(align=True)
-         row.template_header()
+         layout.template_header()
  
          if context.area.show_menus:
-             sub = row.row(align=True)
-             sub.menu("CONSOLE_MT_console")
+             layout.menu("CONSOLE_MT_console")
  
-         row = layout.row(align=True)
-         row.operator("console.autocomplete", text=_("Autocomplete"))
 -        layout.operator("console.autocomplete", text="Autocomplete")
++        layout.operator("console.autocomplete", text=_("Autocomplete"))
  
  
- class CONSOLE_MT_console(bpy.types.Menu):
+ class CONSOLE_MT_console(Menu):
 -    bl_label = "Console"
 +    bl_label = _("Console")
  
      def draw(self, context):
          layout = self.layout
@@@ -56,8 -53,8 +54,8 @@@
          layout.operator("screen.screen_full_area")
  
  
- class CONSOLE_MT_language(bpy.types.Menu):
+ class CONSOLE_MT_language(Menu):
 -    bl_label = "Languages..."
 +    bl_label = _("Languages...")
  
      def draw(self, context):
          import sys
@@@ -83,10 -80,10 +81,10 @@@ def add_scrollback(text, text_type)
              type=text_type)
  
  
- class ConsoleExec(bpy.types.Operator):
+ class ConsoleExec(Operator):
      '''Execute the current console line as a python expression'''
      bl_idname = "console.execute"
 -    bl_label = "Console Execute"
 +    bl_label = _("Console Execute")
  
      def execute(self, context):
          sc = context.space_data
              return {'FINISHED'}
  
  
- class ConsoleAutocomplete(bpy.types.Operator):
+ class ConsoleAutocomplete(Operator):
      '''Evaluate the namespace up until the cursor and give a list of options or complete the name if there is only one'''
      bl_idname = "console.autocomplete"
 -    bl_label = "Console Autocomplete"
 +    bl_label = _("Console Autocomplete")
  
      def execute(self, context):
          sc = context.space_data
              return {'FINISHED'}
  
  
- class ConsoleBanner(bpy.types.Operator):
+ class ConsoleBanner(Operator):
      '''Print a message whem the terminal initializes'''
      bl_idname = "console.banner"
 -    bl_label = "Console Banner"
 +    bl_label = _("Console Banner")
  
      def execute(self, context):
          sc = context.space_data
              return {'FINISHED'}
  
  
- class ConsoleLanguage(bpy.types.Operator):
+ class ConsoleLanguage(Operator):
      '''Set the current language for this console'''
      bl_idname = "console.language"
 -    bl_label = "Console Language"
 +    bl_label = _("Console Language")
-     language = StringProperty(name="Language", maxlen=32, default="")
+     language = StringProperty(
 -            name="Language",
++            name=_("Language"),
+             maxlen=32,
+             )
  
      def execute(self, context):
          sc = context.space_data
@@@ -19,7 -19,7 +19,8 @@@
  # <pep8 compliant>
  
  import bpy
+ from bpy.types import Header, Menu
 +from blf import gettext as _
  
  
  #######################################
@@@ -97,24 -102,22 +103,22 @@@ class DOPESHEET_HT_header(Header)
          row.template_header()
  
          if context.area.show_menus:
-             sub = row.row(align=True)
+             row.menu("DOPESHEET_MT_view")
+             row.menu("DOPESHEET_MT_select")
+             row.menu("DOPESHEET_MT_marker")
  
-             sub.menu("DOPESHEET_MT_view")
-             sub.menu("DOPESHEET_MT_select")
-             sub.menu("DOPESHEET_MT_marker")
-             if st.mode == 'DOPESHEET' or (st.mode == 'ACTION' and st.action != None):
-                 sub.menu("DOPESHEET_MT_channel")
+             if st.mode == 'DOPESHEET' or (st.mode == 'ACTION' and st.action is not None):
+                 row.menu("DOPESHEET_MT_channel")
              elif st.mode == 'GPENCIL':
-                 sub.menu("DOPESHEET_MT_gpencil_channel")
+                 row.menu("DOPESHEET_MT_gpencil_channel")
  
              if st.mode != 'GPENCIL':
-                 sub.menu("DOPESHEET_MT_key")
+                 row.menu("DOPESHEET_MT_key")
              else:
-                 sub.menu("DOPESHEET_MT_gpencil_frame")
+                 row.menu("DOPESHEET_MT_gpencil_frame")
  
          layout.prop(st, "mode", text="")
 -        layout.prop(st.dopesheet, "show_summary", text="Summary")
 +        layout.prop(st.dopesheet, "show_summary", text=_("Summary"))
  
          if st.mode == 'DOPESHEET':
              dopesheet_filter(layout, context)
          row.operator("action.paste", text="", icon='PASTEDOWN')
  
  
- class DOPESHEET_MT_view(bpy.types.Menu):
+ class DOPESHEET_MT_view(Menu):
 -    bl_label = "View"
 +    bl_label = _("View")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("screen.screen_full_area")
  
  
- class DOPESHEET_MT_select(bpy.types.Menu):
+ class DOPESHEET_MT_select(Menu):
 -    bl_label = "Select"
 +    bl_label = _("Select")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
          # This is a bit misleading as the operator's default text is "Select All" while it actually *toggles* All/None
          layout.operator("action.select_all_toggle")
 -        layout.operator("action.select_all_toggle", text="Invert Selection").invert = True
 +        layout.operator("action.select_all_toggle", text=_("Invert Selection")).invert = True
  
          layout.separator()
          layout.operator("action.select_border")
              layout.operator("action.select_linked")
  
  
- class DOPESHEET_MT_marker(bpy.types.Menu):
+ class DOPESHEET_MT_marker(Menu):
 -    bl_label = "Marker"
 +    bl_label = _("Marker")
  
      def draw(self, context):
          layout = self.layout
  
          #layout.operator_context = 'EXEC_REGION_WIN'
  
-         layout.column()
 -        layout.operator("marker.add", "Add Marker")
 -        layout.operator("marker.duplicate", text="Duplicate Marker")
 -        layout.operator("marker.delete", text="Delete Marker")
 +        layout.operator("marker.add", _("Add Marker"))
 +        layout.operator("marker.duplicate", text=_("Duplicate Marker"))
 +        layout.operator("marker.delete", text=_("Delete Marker"))
  
          layout.separator()
  
  #######################################
  # Keyframe Editing
  
- class DOPESHEET_MT_channel(bpy.types.Menu):
+ class DOPESHEET_MT_channel(Menu):
 -    bl_label = "Channel"
 +    bl_label = _("Channel")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("anim.channels_fcurves_enable")
  
  
- class DOPESHEET_MT_key(bpy.types.Menu):
+ class DOPESHEET_MT_key(Menu):
 -    bl_label = "Key"
 +    bl_label = _("Key")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
 -        layout.menu("DOPESHEET_MT_key_transform", text="Transform")
 +        layout.menu("DOPESHEET_MT_key_transform", text=_("Transform"))
  
 -        layout.operator_menu_enum("action.snap", "type", text="Snap")
 -        layout.operator_menu_enum("action.mirror", "type", text="Mirror")
 +        layout.operator_menu_enum("action.snap", "type", text=_("Snap"))
 +        layout.operator_menu_enum("action.mirror", "type", text=_("Mirror"))
  
          layout.separator()
          layout.operator("action.keyframe_insert")
          layout.operator("action.paste")
  
  
- class DOPESHEET_MT_key_transform(bpy.types.Menu):
+ class DOPESHEET_MT_key_transform(Menu):
 -    bl_label = "Transform"
 +    bl_label = _("Transform")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
 -        layout.operator("transform.transform", text="Grab/Move").mode = 'TIME_TRANSLATE'
 -        layout.operator("transform.transform", text="Extend").mode = 'TIME_EXTEND'
 -        layout.operator("transform.transform", text="Slide").mode = 'TIME_SLIDE'
 -        layout.operator("transform.transform", text="Scale").mode = 'TIME_SCALE'
 +        layout.operator("transform.transform", text=_("Grab/Move")).mode = 'TIME_TRANSLATE'
 +        layout.operator("transform.transform", text=_("Extend")).mode = 'TIME_EXTEND'
 +        layout.operator("transform.transform", text=_("Slide")).mode = 'TIME_SLIDE'
 +        layout.operator("transform.transform", text=_("Scale")).mode = 'TIME_SCALE'
  
  
  #######################################
  # Grease Pencil Editing
  
- class DOPESHEET_MT_gpencil_channel(bpy.types.Menu):
+ class DOPESHEET_MT_gpencil_channel(Menu):
 -    bl_label = "Channel"
 +    bl_label = _("Channel")
  
      def draw(self, context):
          layout = self.layout
          #layout.operator_menu_enum("anim.channels_move", "direction", text="Move...")
  
  
- class DOPESHEET_MT_gpencil_frame(bpy.types.Menu):
+ class DOPESHEET_MT_gpencil_frame(Menu):
 -    bl_label = "Frame"
 +    bl_label = _("Frame")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
 -        layout.menu("DOPESHEET_MT_key_transform", text="Transform")
 +        layout.menu("DOPESHEET_MT_key_transform", text=_("Transform"))
  
          #layout.operator_menu_enum("action.snap", "type", text="Snap")
          #layout.operator_menu_enum("action.mirror", "type", text="Mirror")
  # <pep8 compliant>
  
  import bpy
+ from bpy.types import Header, Menu
 +from blf import gettext as _
  
  
- class GRAPH_HT_header(bpy.types.Header):
+ class GRAPH_HT_header(Header):
      bl_space_type = 'GRAPH_EDITOR'
  
      def draw(self, context):
@@@ -62,8 -60,8 +61,8 @@@
              row.operator("graph.ghost_curves_create", text="", icon='GHOST_ENABLED')
  
  
- class GRAPH_MT_view(bpy.types.Menu):
+ class GRAPH_MT_view(Menu):
 -    bl_label = "View"
 +    bl_label = _("View")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("screen.screen_full_area")
  
  
- class GRAPH_MT_select(bpy.types.Menu):
+ class GRAPH_MT_select(Menu):
 -    bl_label = "Select"
 +    bl_label = _("Select")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
          # This is a bit misleading as the operator's default text is "Select All" while it actually *toggles* All/None
          layout.operator("graph.select_all_toggle")
 -        layout.operator("graph.select_all_toggle", text="Invert Selection").invert = True
 +        layout.operator("graph.select_all_toggle", text=_("Invert Selection")).invert = True
  
          layout.separator()
          layout.operator("graph.select_border")
          layout.operator("graph.select_linked")
  
  
- class GRAPH_MT_marker(bpy.types.Menu):
+ class GRAPH_MT_marker(Menu):
 -    bl_label = "Marker"
 +    bl_label = _("Marker")
  
      def draw(self, context):
          layout = self.layout
  
          #layout.operator_context = 'EXEC_REGION_WIN'
  
-         layout.column()
 -        layout.operator("marker.add", "Add Marker")
 -        layout.operator("marker.duplicate", text="Duplicate Marker")
 -        layout.operator("marker.delete", text="Delete Marker")
 +        layout.operator("marker.add", _("Add Marker"))
 +        layout.operator("marker.duplicate", text=_("Duplicate Marker"))
 +        layout.operator("marker.delete", text=_("Delete Marker"))
  
          layout.separator()
  
          # TODO: pose markers for action edit mode only?
  
  
- class GRAPH_MT_channel(bpy.types.Menu):
+ class GRAPH_MT_channel(Menu):
 -    bl_label = "Channel"
 +    bl_label = _("Channel")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("anim.channels_fcurves_enable")
  
  
- class GRAPH_MT_key(bpy.types.Menu):
+ class GRAPH_MT_key(Menu):
 -    bl_label = "Key"
 +    bl_label = _("Key")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
 -        layout.menu("GRAPH_MT_key_transform", text="Transform")
 +        layout.menu("GRAPH_MT_key_transform", text=_("Transform"))
  
 -        layout.operator_menu_enum("graph.snap", "type", text="Snap")
 -        layout.operator_menu_enum("graph.mirror", "type", text="Mirror")
 +        layout.operator_menu_enum("graph.snap", "type", text=_("Snap"))
 +        layout.operator_menu_enum("graph.mirror", "type", text=_("Mirror"))
  
          layout.separator()
          layout.operator("graph.keyframe_insert")
          layout.operator("graph.paste")
  
          layout.separator()
 -        layout.operator("graph.euler_filter", text="Discontinuity (Euler) Filter")
 +        layout.operator("graph.euler_filter", text=_("Discontinuity (Euler) Filter"))
  
  
- class GRAPH_MT_key_transform(bpy.types.Menu):
+ class GRAPH_MT_key_transform(Menu):
 -    bl_label = "Transform"
 +    bl_label = _("Transform")
  
      def draw(self, context):
          layout = self.layout
  
-         layout.column()
 -        layout.operator("transform.translate", text="Grab/Move")
 -        layout.operator("transform.transform", text="Extend").mode = 'TIME_EXTEND'
 -        layout.operator("transform.rotate", text="Rotate")
 -        layout.operator("transform.resize", text="Scale")
 +        layout.operator("transform.translate", text=_("Grab/Move"))
 +        layout.operator("transform.transform", text=_("Extend")).mode = 'TIME_EXTEND'
 +        layout.operator("transform.rotate", text=_("Rotate"))
 +        layout.operator("transform.resize", text=_("Scale"))
  
  if __name__ == "__main__":  # only for live edit.
      bpy.utils.register_module(__name__)
@@@ -18,7 -18,7 +18,8 @@@
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Header, Menu, Panel
 +from blf import gettext as _
  
  
  class BrushButtonsPanel():
@@@ -32,8 -32,8 +33,8 @@@
          return sima.show_paint and toolsettings.brush
  
  
- class IMAGE_MT_view(bpy.types.Menu):
+ class IMAGE_MT_view(Menu):
 -    bl_label = "View"
 +    bl_label = _("View")
  
      def draw(self, context):
          layout = self.layout
@@@ -80,8 -80,8 +81,8 @@@
          layout.operator("screen.screen_full_area")
  
  
- class IMAGE_MT_select(bpy.types.Menu):
+ class IMAGE_MT_select(Menu):
 -    bl_label = "Select"
 +    bl_label = _("Select")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("uv.select_linked")
  
  
- class IMAGE_MT_image(bpy.types.Menu):
+ class IMAGE_MT_image(Menu):
 -    bl_label = "Image"
 +    bl_label = _("Image")
  
      def draw(self, context):
          layout = self.layout
              layout.prop(sima, "use_image_paint")
  
  
- class IMAGE_MT_image_invert(bpy.types.Menu):
+ class IMAGE_MT_image_invert(Menu):
 -    bl_label = "Invert"
 +    bl_label = _("Invert")
  
      def draw(self, context):
          layout = self.layout
          op.invert_a = True
  
  
- class IMAGE_MT_uvs_showhide(bpy.types.Menu):
+ class IMAGE_MT_uvs_showhide(Menu):
 -    bl_label = "Show/Hide Faces"
 +    bl_label = _("Show/Hide Faces")
  
      def draw(self, context):
          layout = self.layout
  
          layout.operator("uv.reveal")
 -        layout.operator("uv.hide", text="Hide Selected")
 -        layout.operator("uv.hide", text="Hide Unselected").unselected = True
 +        layout.operator("uv.hide", text=_("Hide Selected"))
 +        layout.operator("uv.hide", text=_("Hide Unselected")).unselected = True
  
  
- class IMAGE_MT_uvs_transform(bpy.types.Menu):
+ class IMAGE_MT_uvs_transform(Menu):
 -    bl_label = "Transform"
 +    bl_label = _("Transform")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("transform.shear")
  
  
- class IMAGE_MT_uvs_snap(bpy.types.Menu):
+ class IMAGE_MT_uvs_snap(Menu):
 -    bl_label = "Snap"
 +    bl_label = _("Snap")
  
      def draw(self, context):
          layout = self.layout
  
          layout.separator()
  
 -        layout.operator("uv.snap_cursor", text="Cursor to Pixels").target = 'PIXELS'
 -        layout.operator("uv.snap_cursor", text="Cursor to Selected").target = 'SELECTED'
 +        layout.operator("uv.snap_cursor", text=_("Cursor to Pixels")).target = 'PIXELS'
 +        layout.operator("uv.snap_cursor", text=_("Cursor to Selected")).target = 'SELECTED'
  
  
- class IMAGE_MT_uvs_mirror(bpy.types.Menu):
+ class IMAGE_MT_uvs_mirror(Menu):
 -    bl_label = "Mirror"
 +    bl_label = _("Mirror")
  
      def draw(self, context):
          layout = self.layout
          layout.operator_context = 'EXEC_REGION_WIN'
  
 -        layout.operator("transform.mirror", text="X Axis").constraint_axis[0] = True
 -        layout.operator("transform.mirror", text="Y Axis").constraint_axis[1] = True
 +        layout.operator("transform.mirror", text=_("X Axis")).constraint_axis[0] = True
 +        layout.operator("transform.mirror", text=_("Y Axis")).constraint_axis[1] = True
  
  
- class IMAGE_MT_uvs_weldalign(bpy.types.Menu):
+ class IMAGE_MT_uvs_weldalign(Menu):
 -    bl_label = "Weld/Align"
 +    bl_label = _("Weld/Align")
  
      def draw(self, context):
          layout = self.layout
@@@ -287,8 -287,8 +288,8 @@@ class IMAGE_MT_uvs(Menu)
          layout.menu("IMAGE_MT_uvs_showhide")
  
  
- class IMAGE_MT_uvs_select_mode(bpy.types.Menu):
+ class IMAGE_MT_uvs_select_mode(Menu):
 -    bl_label = "UV Select Mode"
 +    bl_label = _("UV Select Mode")
  
      def draw(self, context):
          layout = self.layout
@@@ -413,10 -413,10 +414,10 @@@ class IMAGE_HT_header(Header)
              layout.prop(sima, "use_realtime_update", text="", icon_only=True, icon='LOCKED')
  
  
- class IMAGE_PT_image_properties(bpy.types.Panel):
+ class IMAGE_PT_image_properties(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'UI'
 -    bl_label = "Image"
 +    bl_label = _("Image")
  
      @classmethod
      def poll(cls, context):
          layout.template_image(sima, "image", iuser)
  
  
- class IMAGE_PT_game_properties(bpy.types.Panel):
+ class IMAGE_PT_game_properties(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'UI'
 -    bl_label = "Game Properties"
 +    bl_label = _("Game Properties")
  
      @classmethod
      def poll(cls, context):
          col.prop(ima, "mapping", expand=True)
  
  
- class IMAGE_PT_view_histogram(bpy.types.Panel):
+ class IMAGE_PT_view_histogram(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'PREVIEW'
 -    bl_label = "Histogram"
 +    bl_label = _("Histogram")
  
      @classmethod
      def poll(cls, context):
          layout.prop(sima.scopes.histogram, "mode", icon_only=True)
  
  
- class IMAGE_PT_view_waveform(bpy.types.Panel):
+ class IMAGE_PT_view_waveform(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'PREVIEW'
 -    bl_label = "Waveform"
 +    bl_label = _("Waveform")
  
      @classmethod
      def poll(cls, context):
          layout = self.layout
  
          sima = context.space_data
          layout.template_waveform(sima, "scopes")
-         sub = layout.row().split(percentage=0.75)
-         sub.prop(sima.scopes, "waveform_alpha")
-         sub.prop(sima.scopes, "waveform_mode", text="", icon_only=True)
+         row = layout.split(percentage=0.75)
+         row.prop(sima.scopes, "waveform_alpha")
+         row.prop(sima.scopes, "waveform_mode", text="", icon_only=True)
  
  
- class IMAGE_PT_view_vectorscope(bpy.types.Panel):
+ class IMAGE_PT_view_vectorscope(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'PREVIEW'
 -    bl_label = "Vectorscope"
 +    bl_label = _("Vectorscope")
  
      @classmethod
      def poll(cls, context):
          layout.prop(sima.scopes, "vectorscope_alpha")
  
  
- class IMAGE_PT_sample_line(bpy.types.Panel):
+ class IMAGE_PT_sample_line(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'PREVIEW'
 -    bl_label = "Sample Line"
 +    bl_label = _("Sample Line")
  
      @classmethod
      def poll(cls, context):
          layout.prop(sima.sample_histogram, "mode")
  
  
- class IMAGE_PT_scope_sample(bpy.types.Panel):
+ class IMAGE_PT_scope_sample(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'PREVIEW'
 -    bl_label = "Scope Samples"
 +    bl_label = _("Scope Samples")
  
      @classmethod
      def poll(cls, context):
  
      def draw(self, context):
          layout = self.layout
          sima = context.space_data
-         split = layout.split()
-         row = split.row()
+         row = layout.row()
          row.prop(sima.scopes, "use_full_resolution")
-         row = split.row()
-         row.active = not sima.scopes.use_full_resolution
-         row.prop(sima.scopes, "accuracy")
+         sub = row.row()
+         sub.active = not sima.scopes.use_full_resolution
+         sub.prop(sima.scopes, "accuracy")
  
  
- class IMAGE_PT_view_properties(bpy.types.Panel):
+ class IMAGE_PT_view_properties(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'UI'
 -    bl_label = "Display"
 +    bl_label = _("Display")
  
      @classmethod
      def poll(cls, context):
          if show_uvedit:
  
              col = layout.column()
-             col.label(_("Cursor Location"))
-             row = col.row()
-             row.prop(uvedit, "cursor_location", text="")
 -            col.label("Cursor Location:")
++            col.label(_("Cursor Location:"))
+             col.row().prop(uvedit, "cursor_location", text="")
+             col.separator()
  
-             col = layout.column()
              col.label(text="UVs:")
-             row = col.row()
-             row.prop(uvedit, "edge_draw_type", expand=True)
+             col.row().prop(uvedit, "edge_draw_type", expand=True)
  
              split = layout.split()
              col = split.column()
              col.prop(uvedit, "show_faces")
 -            col.prop(uvedit, "show_smooth_edges", text="Smooth")
 -            col.prop(uvedit, "show_modified_edges", text="Modified")
 +            col.prop(uvedit, "show_smooth_edges", text=_("Smooth"))
 +            col.prop(uvedit, "show_modified_edges", text=_("Modified"))
  
              col = split.column()
 -            col.prop(uvedit, "show_stretch", text="Stretch")
 +            col.prop(uvedit, "show_stretch", text=_("Stretch"))
              sub = col.column()
              sub.active = uvedit.show_stretch
              sub.row().prop(uvedit, "draw_stretch_type", expand=True)
  
  
- class IMAGE_PT_paint(bpy.types.Panel):
+ class IMAGE_PT_paint(Panel):
      bl_space_type = 'IMAGE_EDITOR'
      bl_region_type = 'UI'
 -    bl_label = "Paint"
 +    bl_label = _("Paint")
  
      @classmethod
      def poll(cls, context):
  
              if brush.image_tool == 'CLONE':
                  col.separator()
 -                col.prop(brush, "clone_image", text="Image")
 -                col.prop(brush, "clone_alpha", text="Alpha")
 +                col.prop(brush, "clone_image", text=_("Image"))
 +                col.prop(brush, "clone_alpha", text=_("Alpha"))
  
  
- class IMAGE_PT_tools_brush_texture(BrushButtonsPanel, bpy.types.Panel):
+ class IMAGE_PT_tools_brush_texture(BrushButtonsPanel, Panel):
 -    bl_label = "Texture"
 +    bl_label = _("Texture")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
          col.prop(brush, "use_fixed_texture")
  
  
- class IMAGE_PT_tools_brush_tool(BrushButtonsPanel, bpy.types.Panel):
+ class IMAGE_PT_tools_brush_tool(BrushButtonsPanel, Panel):
 -    bl_label = "Tool"
 +    bl_label = _("Tool")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
          row.prop(brush, "use_paint_image", text="", icon='TPAINT_HLT')
  
  
- class IMAGE_PT_paint_stroke(BrushButtonsPanel, bpy.types.Panel):
+ class IMAGE_PT_paint_stroke(BrushButtonsPanel, Panel):
 -    bl_label = "Paint Stroke"
 +    bl_label = _("Paint Stroke")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
          layout.prop(brush, "use_wrap")
  
  
- class IMAGE_PT_paint_curve(BrushButtonsPanel, bpy.types.Panel):
+ class IMAGE_PT_paint_curve(BrushButtonsPanel, Panel):
 -    bl_label = "Paint Curve"
 +    bl_label = _("Paint Curve")
      bl_options = {'DEFAULT_CLOSED'}
  
      def draw(self, context):
  
  # <pep8 compliant>
  import bpy
+ from bpy.types import Header, Menu, Operator
 +from blf import gettext as _
  
  
- class INFO_HT_header(bpy.types.Header):
+ class INFO_HT_header(Header):
      bl_space_type = 'INFO'
  
      def draw(self, context):
@@@ -87,8 -87,8 +88,8 @@@
          """
  
  
- class INFO_MT_report(bpy.types.Menu):
+ class INFO_MT_report(Menu):
 -    bl_label = "Report"
 +    bl_label = _("Report")
  
      def draw(self, context):
          layout = self.layout
          layout.operator("console.report_copy")
  
  
- class INFO_MT_file(bpy.types.Menu):
+ class INFO_MT_file(Menu):
 -    bl_label = "File"
 +    bl_label = _("File");
  
      def draw(self, context):
          layout = self.layout
          layout.separator()
  
          layout.operator_context = 'EXEC_AREA'
 -        layout.operator("wm.quit_blender", text="Quit", icon='QUIT')
 +        layout.operator("wm.quit_blender", text=_("Quit"), icon='QUIT')
  
  
- class INFO_MT_file_import(bpy.types.Menu):
+ class INFO_MT_file_import(Menu):
      bl_idname = "INFO_MT_file_import"
 -    bl_label = "Import"