[Bf-blender-cvs] [80a31d30a4f] blender2.8: Merge branch 'master' into blender2.8

Campbell Barton noreply at git.blender.org
Sat Jul 7 08:54:34 CEST 2018


Commit: 80a31d30a4f6b793902d5d5ccd91f4fe3971e2b1
Author: Campbell Barton
Date:   Sat Jul 7 08:53:00 2018 +0200
Branches: blender2.8
https://developer.blender.org/rB80a31d30a4f6b793902d5d5ccd91f4fe3971e2b1

Merge branch 'master' into blender2.8

===================================================================



===================================================================

diff --cc release/scripts/startup/bl_ui/space_view3d.py
index fa37197f3ff,0a365c6a20c..8a3acd033f3
--- a/release/scripts/startup/bl_ui/space_view3d.py
+++ b/release/scripts/startup/bl_ui/space_view3d.py
@@@ -3663,74 -3441,41 +3658,61 @@@ class VIEW3D_PT_view3d_camera_lock(Pane
      def draw(self, context):
          layout = self.layout
  
 +        layout.use_property_split = True
 +        layout.use_property_decorate = False  # No animation.
 +
          view = context.space_data
 -        layout.column().prop(view, "cursor_location", text="Location")
 +
 +        col = layout.column(align=True)
 +        subcol = col.column()
 +        subcol.active = bool(view.region_3d.view_perspective != 'CAMERA' or view.region_quadviews)
 +
 +        subcol.prop(view, "lock_object")
 +        lock_object = view.lock_object
 +        if lock_object:
 +            if lock_object.type == 'ARMATURE':
 +                subcol.prop_search(
 +                    view, "lock_bone", lock_object.data,
 +                    "edit_bones" if lock_object.mode == 'EDIT'
 +                    else "bones",
 +                    text=""
 +                )
 +        else:
 +            subcol.prop(view, "lock_cursor", text="Lock to 3D Cursor")
 +
 +        col.prop(view, "lock_camera")
  
  
 -class VIEW3D_PT_view3d_name(Panel):
 +class VIEW3D_PT_view3d_cursor(Panel):
      bl_space_type = 'VIEW_3D'
      bl_region_type = 'UI'
 -    bl_label = "Item"
 -
 -    @classmethod
 -    def poll(cls, context):
 -        return (context.active_object is not None)
 +    bl_label = "3D Cursor"
  
-     @classmethod
-     def poll(cls, context):
-         view = context.space_data
-         return (view is not None)
- 
      def draw(self, context):
          layout = self.layout
 +        layout.use_property_split = True
  
 -        ob = context.active_object
 -        row = layout.row()
 -        row.label(text="", icon='OBJECT_DATA')
 -        row.prop(ob, "name", text="")
 +        view = context.space_data
  
 -        if ob.type == 'ARMATURE' and ob.mode in {'EDIT', 'POSE'}:
 -            bone = context.active_bone
 -            if bone:
 -                row = layout.row()
 -                row.label(text="", icon='BONE_DATA')
 -                row.prop(bone, "name", text="")
 +        layout.column().prop(view, "cursor_location", text="Location")
  
  
 -class VIEW3D_PT_view3d_display(Panel):
 +class VIEW3D_PT_shading(Panel):
      bl_space_type = 'VIEW_3D'
 -    bl_region_type = 'UI'
 -    bl_label = "Display"
 -    bl_options = {'DEFAULT_CLOSED'}
 +    bl_region_type = 'HEADER'
 +    bl_label = "Shading"
 +    bl_ui_units_x = 11
 +
-     @classmethod
-     def poll(cls, context):
-         return True
- 
 +    def draw(self, context):
 +        pass
 +
 +
 +class VIEW3D_PT_shading_lighting(Panel):
 +    bl_space_type = 'VIEW_3D'
 +    bl_region_type = 'HEADER'
 +    bl_label = "Lighting"
 +    bl_parent_id = 'VIEW3D_PT_shading'
  
-     @classmethod
-     def poll(cls, context):
-         return True
- 
      def draw(self, context):
          layout = self.layout
  
@@@ -3807,129 -3542,35 +3789,125 @@@ class VIEW3D_PT_shading_options(Panel)
  
      def draw(self, context):
          layout = self.layout
 +
          view = context.space_data
 +        shading = view.shading
 +
 +        if not shading.light == 'MATCAP':
 +            row = layout.row()
 +            row.prop(shading, "show_specular_highlight")
 +
 +        row = layout.split(0.4)
 +        row.prop(shading, "show_xray")
 +        sub = row.row()
 +        sub.active = shading.show_xray
 +        sub.prop(shading, "xray_alpha", text="")
 +
 +        row = layout.split(0.4)
 +        row.active = not shading.show_xray
 +        row.prop(shading, "show_shadows")
 +        sub = row.row()
 +        sub.active = shading.show_shadows and not shading.show_xray
 +        sub.prop(shading, "shadow_intensity", text="")
 +
 +        row = layout.split(0.4)
 +        row.active = not shading.show_xray
 +        row.prop(shading, "show_cavity")
 +        sub = row.column(align=True)
 +        sub.active = not shading.show_xray and shading.show_cavity
 +        sub.prop(shading, "cavity_ridge_factor")
 +        sub.prop(shading, "cavity_valley_factor")
 +
 +        row = layout.split(0.4)
 +        row.prop(shading, "show_object_outline")
 +        sub = row.row()
 +        sub.active = shading.show_object_outline
 +        sub.prop(shading, "object_outline_color", text="")
 +
 +        layout.prop(view, "show_world")
 +
 +
 +class VIEW3D_PT_overlay(Panel):
 +    bl_space_type = 'VIEW_3D'
 +    bl_region_type = 'HEADER'
 +    bl_label = "Overlays"
 +    bl_ui_units_x = 14
  
-     @classmethod
-     def poll(cls, context):
-         return True
- 
 -        basic_stereo = context.scene.render.views_format == 'STEREO_3D'
 +    def draw(self, context):
 +        layout = self.layout
 +
 +        view = context.space_data
 +        shading = view.shading
 +        overlay = view.overlay
 +        display_all = overlay.show_overlays
  
          col = layout.column()
 -        col.row().prop(view, "stereo_3d_camera", expand=True)
 +        col.active = display_all
 +
 +        split = col.split()
 +
 +        sub = split.column()
 +        sub.prop(view, "show_manipulator", text="Manipulators")
 +        sub.prop(overlay, "show_text", text="Text")
 +        sub.prop(overlay, "show_cursor", text="3D Cursor")
 +        sub.prop(overlay, "show_outline_selected")
 +        sub.prop(overlay, "show_all_objects_origin")
 +
 +        sub = split.column()
 +        sub.prop(overlay, "show_relationship_lines")
 +        sub.prop(overlay, "show_motion_paths")
 +        #sub.prop(overlay, "show_onion_skins")
 +        sub.prop(overlay, "show_face_orientation")
 +        sub.prop(overlay, "show_backface_culling")
 +        if shading.type == 'MATERIAL':
 +            sub.prop(overlay, "show_look_dev")
  
 -        col.label(text="Display:")
 -        row = col.row()
 -        row.active = basic_stereo
 -        row.prop(view, "show_stereo_3d_cameras")
 -        row = col.row()
 -        row.active = basic_stereo
 -        split = row.split()
 -        split.prop(view, "show_stereo_3d_convergence_plane")
 -        split = row.split()
 -        split.prop(view, "stereo_3d_convergence_plane_alpha", text="Alpha")
 -        split.active = view.show_stereo_3d_convergence_plane
          row = col.row()
 -        split = row.split()
 -        split.prop(view, "show_stereo_3d_volume")
 -        split = row.split()
 -        split.prop(view, "stereo_3d_volume_alpha", text="Alpha")
 +        row.prop(overlay, "show_wireframes")
 +        sub = row.row()
 +        sub.active = overlay.show_wireframes
 +        sub.prop(overlay, "wireframe_threshold", text="")
  
  
 -class VIEW3D_PT_view3d_shading(Panel):
 +        col = layout.column()
 +        col.active = display_all
 +        split = col.split(percentage=0.55)
 +        split.prop(overlay, "show_floor", text="Grid Floor")
 +
 +        row = split.row(align=True)
 +        row.prop(overlay, "show_axis_x", text="X", toggle=True)
 +        row.prop(overlay, "show_axis_y", text="Y", toggle=True)
 +        row.prop(overlay, "show_axis_z", text="Z", toggle=True)
 +
 +        if overlay.show_floor:
 +            sub = col.column(align=True)
 +            sub.active = bool(overlay.show_floor or view.region_quadviews or not view.region_3d.is_perspective)
 +            subsub = sub.column(align=True)
 +            subsub.active = overlay.show_floor
 +            subsub.prop(overlay, "grid_scale", text="Scale")
 +            subsub.prop(overlay, "grid_subdivisions", text="Subdivisions")
 +
 +        col.prop(view, "show_reconstruction", text="Motion Tracking")
 +        if view.show_reconstruction:
 +            sub = col.column(align=True)
 +            sub.active = view.show_reconstruction
 +            sub.prop(view, "show_camera_path", text="Camera Path")
 +            sub.prop(view, "show_bundle_names", text="3D Marker Names")
 +            sub.label(text="Track Type and Size:")
 +            row = sub.row(align=True)
 +            row.prop(view, "tracks_draw_type", text="")
 +            row.prop(view, "tracks_draw_size", text="")
 +
 +
 +class VIEW3D_PT_overlay_edit_mesh(Panel):
      bl_space_type = 'VIEW_3D'
 -    bl_region_type = 'UI'
 -    bl_label = "Shading"
 +    bl_region_type = 'HEADER'
 +    bl_parent_id = 'VIEW3D_PT_overlay'
 +    bl_label = "Edit Mesh"
 +
 +    @classmethod
 +    def poll(cls, context):
 +        return context.mode == 'EDIT_MESH'
  
      def draw(self, context):
          layout = self.layout
@@@ -4263,37 -3886,30 +4241,32 @@@ class VIEW3D_PT_snapping(Panel)
  
  class VIEW3D_PT_transform_orientations(Panel):
      bl_space_type = 'VIEW_3D'
 -    bl_region_type = 'UI'
 +    bl_region_type = 'HEADER'
      bl_label = "Transform Orientations"
 -    bl_options = {'DEFAULT_CLOSED'}
 +    bl_ui_units_x = 8
  
-     @classmethod
-     def poll(cls, context):
-         view = context.space_data
-         return (view)
- 
      def draw(self, context):
          layout = self.layout
 +        layout.label("Transform Orientations")
  
 -        view = context.space_data
 -        orientation = view.current_orientation
 +        scene = context.scene
 +        orientation = scene.current_orientation
  
 -        row = layout.row(align=True)
 -        row.prop(view, "transform_orientation", text="")
 -        row.operator("transform.create_orientation", text="", icon='ZOOMIN')
 +        row = layout.row()
 +        col = row.column()
 +        col.prop(scene, "transform_orientation", expand=True)
 +        row.operator("transform.create_orientation", text="", icon='ZOOMIN', emboss=False).use = True
  
          if orientation:
 -            row = layout.row(align=True)
 +            row = layout.row(align=False)
              row.prop(orientation, "name", text="")
 -            row.operator("transform.delete_orientation", text="", icon='X')
 +            row.operator("transform.delete_orientation", text="", icon='X', emboss=False)
  
  
 -class VIEW3D_PT_etch_a_ton(Panel):
 +class VIEW3D_PT_quad_view(Panel):
      bl_space_type = 'VIEW_3D'
      bl_region_type = 'UI'
 -   

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list