[Bf-blender-cvs] [37285e9050d] greasepencil-object: GPencil: Remove old 2.7x Pie menus

Antonio Vazquez noreply at git.blender.org
Fri Nov 22 10:32:36 CET 2019


Commit: 37285e9050dcc1ef7410d2cd6ce872fd939f1b84
Author: Antonio Vazquez
Date:   Fri Nov 22 10:00:00 2019 +0100
Branches: greasepencil-object
https://developer.blender.org/rB37285e9050dcc1ef7410d2cd6ce872fd939f1b84

GPencil: Remove old 2.7x Pie menus

These menus are not used anymore.

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

M	release/scripts/startup/bl_ui/properties_grease_pencil_common.py

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

diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
index ee46f3dbba0..ffa62a3a668 100644
--- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
+++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py
@@ -309,243 +309,6 @@ class GreasePencilAppearancePanel:
             col.prop(gp_settings, "use_cursor", text="Show Brush")
 
 
-class GPENCIL_MT_pie_tool_palette(Menu):
-    """A pie menu for quick access to Grease Pencil tools"""
-    bl_label = "Grease Pencil Tools"
-
-    def draw(self, context):
-        layout = self.layout
-
-        pie = layout.menu_pie()
-        gpd = context.gpencil_data
-
-        # W - Drawing Types
-        col = pie.column()
-        col.operator("gpencil.draw", text="Draw", icon='GREASEPENCIL').mode = 'DRAW'
-        col.operator("gpencil.draw", text="Straight Lines", icon='LINE_DATA').mode = 'DRAW_STRAIGHT'
-        col.operator("gpencil.draw", text="Poly", icon='MESH_DATA').mode = 'DRAW_POLY'
-
-        # E - Eraser
-        # XXX: needs a dedicated icon...
-        col = pie.column()
-        col.operator("gpencil.draw", text="Eraser", icon='FORCE_CURVE').mode = 'ERASER'
-
-        # E - "Settings" Palette is included here too, since it needs to be in a stable position...
-        if gpd and gpd.layers.active:
-            col.separator()
-            col.operator(
-                "wm.call_menu_pie",
-                text="Settings...",
-                icon='SCRIPTWIN').name = "GPENCIL_MT_pie_settings_palette"
-
-        # Editing tools
-        if gpd:
-            if gpd.use_stroke_edit_mode and context.editable_gpencil_strokes:
-                # S - Exit Edit Mode
-                pie.operator("gpencil.editmode_toggle", text="Exit Edit Mode", icon='EDIT')
-
-                # N - Transforms
-                col = pie.column()
-                row = col.row(align=True)
-                row.operator("transform.translate", icon='MAN_TRANS')
-                row.operator("transform.rotate", icon='MAN_ROT')
-                row.operator("transform.resize", text="Scale", icon='MAN_SCALE')
-                row = col.row(align=True)
-                row.label(text="Proportional Edit:")
-                row.prop(context.tool_settings, "use_proportional_edit", text="", icon_only=True)
-                row.prop(context.tool_settings, "proportional_edit_falloff", text="", icon_only=True)
-
-                # NW - Select (Non-Modal)
-                col = pie.column()
-                col.operator("gpencil.select_all", text="Select All", icon='PARTICLE_POINT')
-                col.operator("gpencil.select_all", text="Select Inverse", icon='BLANK1')
-                col.operator("gpencil.select_linked", text="Select Linked", icon='LINKED')
-                col.operator("gpencil.palettecolor_select", text="Select Color", icon='COLOR')
-
-                # NE - Select (Modal)
-                col = pie.column()
-                col.operator("gpencil.select_box", text="Box Select", icon='BORDER_RECT')
-                col.operator("gpencil.select_circle", text="Circle Select", icon='META_EMPTY')
-                col.operator("gpencil.select_lasso", text="Lasso Select", icon='BORDER_LASSO')
-                col.operator("gpencil.select_alternate", text="Alternate Select", icon='BORDER_LASSO')
-
-                # SW - Edit Tools
-                col = pie.column()
-                col.operator("gpencil.duplicate_move", icon='PARTICLE_PATH', text="Duplicate")
-                col.operator("gpencil.delete", icon='X', text="Delete...")
-
-                # SE - More Tools
-                pie.operator("wm.call_menu_pie", text="More...").name = "GPENCIL_MT_pie_tools_more"
-            else:
-                # Toggle Edit Mode
-                pie.operator("gpencil.editmode_toggle", text="Enable Stroke Editing", icon='EDIT')
-
-
-class GPENCIL_MT_pie_settings_palette(Menu):
-    """A pie menu for quick access to Grease Pencil settings"""
-    bl_label = "Grease Pencil Settings"
-
-    @classmethod
-    def poll(cls, context):
-        return bool(context.gpencil_data and context.active_gpencil_layer)
-
-    def draw(self, context):
-        layout = self.layout
-
-        pie = layout.menu_pie()
-        gpd = context.gpencil_data
-        gpl = context.active_gpencil_layer
-        palcolor = None  # context.active_gpencil_palettecolor
-
-        is_editmode = bool(gpd and gpd.use_stroke_edit_mode and context.editable_gpencil_strokes)
-
-        # W - Stroke draw settings
-        col = pie.column(align=True)
-        if palcolor is not None:
-            col.enabled = not palcolor.lock
-            col.label(text="Stroke")
-            col.prop(palcolor, "color", text="")
-            col.prop(palcolor, "alpha", text="", slider=True)
-
-        # E - Fill draw settings
-        col = pie.column(align=True)
-        if palcolor is not None:
-            col.enabled = not palcolor.lock
-            col.label(text="Fill")
-            col.prop(palcolor, "fill_color", text="")
-            col.prop(palcolor, "fill_alpha", text="", slider=True)
-
-        # S Brush settings
-        gpencil_active_brush_settings_simple(context, pie)
-
-        # N - Active Layer
-        col = pie.column()
-        col.label(text="Active Layer:      ")
-
-        row = col.row()
-        row.operator_context = 'EXEC_REGION_WIN'
-        row.operator_menu_enum("gpencil.layer_change", "layer", text="", icon='GREASEPENCIL')
-        row.prop(gpl, "info", text="")
-        row.operator("gpencil.layer_remove", text="", icon='X')
-
-        row = col.row()
-        row.prop(gpl, "lock")
-        row.prop(gpl, "hide")
-        col.prop(gpl, "use_onion_skinning")
-
-        # NW/NE/SW/SE - These operators are only available in editmode
-        # as they require strokes to be selected to work
-        if is_editmode:
-            # NW - Move stroke Down
-            col = pie.column(align=True)
-            col.label(text="Arrange Strokes")
-            col.operator("gpencil.stroke_arrange", text="Send to Back").direction = 'BOTTOM'
-            col.operator("gpencil.stroke_arrange", text="Send Backward").direction = 'DOWN'
-
-            # NE - Move stroke Up
-            col = pie.column(align=True)
-            col.label(text="Arrange Strokes")
-            col.operator("gpencil.stroke_arrange", text="Bring to Front").direction = 'TOP'
-            col.operator("gpencil.stroke_arrange", text="Bring Forward").direction = 'UP'
-
-            # SW - Move stroke to color
-            col = pie.column(align=True)
-            col.operator("gpencil.stroke_change_color", text="Move to Color")
-
-            # SE - Join strokes
-            col = pie.column(align=True)
-            col.label(text="Join Strokes")
-            row = col.row()
-            row.operator("gpencil.stroke_join", text="Join").type = 'JOIN'
-            row.operator("gpencil.stroke_join", text="Join & Copy").type = 'JOINCOPY'
-            col.operator("gpencil.stroke_flip", text="Flip Direction")
-
-            col.prop(gpd, "show_stroke_direction", text="Show Drawing Direction")
-
-
-class GPENCIL_MT_pie_tools_more(Menu):
-    """A pie menu for accessing more Grease Pencil tools"""
-    bl_label = "More Grease Pencil Tools"
-
-    @classmethod
-    def poll(cls, context):
-        gpd = context.gpencil_data
-        return bool(gpd and gpd.use_stroke_edit_mode and context.editable_gpencil_strokes)
-
-    def draw(self, _context):
-        layout = self.layout
-
-        pie = layout.menu_pie()
-        # gpd = context.gpencil_data
-
-        col = pie.column(align=True)
-        col.operator("gpencil.copy", text="Copy", icon='COPYDOWN')
-        col.operator("gpencil.paste", text="Paste", icon='PASTEDOWN').type = 'ACTIVE'
-        col.operator("gpencil.paste", text="Paste by Layer").type = 'LAYER'
-
-        col = pie.column(align=True)
-        col.operator("gpencil.select_more", icon='ADD')
-        col.operator("gpencil.select_less", icon='REMOVE')
-
-        pie.operator("transform.mirror", icon='MOD_MIRROR')
-        pie.operator("transform.bend", icon='MOD_SIMPLEDEFORM')
-        pie.operator("transform.shear", icon='MOD_TRIANGULATE')
-        pie.operator("transform.tosphere", icon='MOD_MULTIRES')
-
-        pie.operator("gpencil.convert", icon='OUTLINER_OB_CURVE', text="Convert...")
-        pie.operator("wm.call_menu_pie", text="Back to Main Palette...").name = "GPENCIL_MT_pie_tool_palette"
-
-
-class GPENCIL_MT_pie_sculpt(Menu):
-    """A pie menu for accessing Grease Pencil stroke sculpt settings"""
-    bl_label = "Grease Pencil Sculpt"
-
-    @classmethod
-    def poll(cls, context):
-        gpd = context.gpencil_data
-        return bool(gpd and gpd.use_stroke_edit_mode and context.editable_gpencil_strokes)
-
-    def draw(self, context):
-        layout = self.layout
-
-        pie = layout.menu_pie()
-
-        settings = context.tool_settings.gpencil_sculpt
-        brush = settings.brush
-
-        # W - Launch Sculpt Mode
-        col = pie.column()
-        # col.label(text="Tool:")
-        col.prop(settings, "sculpt_tool", text="")
-        col.operator("gpencil.sculpt_paint", text="Sculpt", icon='SCULPTMODE_HLT')
-
-        # E - Common Settings
-        col = pie.column(align=True)
-        col.prop(brush, "size", slider=True)
-        row = col.row(align=True)
-        row.prop(brush, "strength", slider=True)
-        # row.prop(brush, "use_pressure_strength", text="", icon_only=True)
-        col.prop(brush, "use_falloff")
-        if settings.sculpt_tool in {'SMOOTH', 'RANDOMIZE'}:
-            row = col.row(align=True)
-            row.prop(settings, "use_edit_position", text="Position", icon='MESH_DATA', toggle=True)
-            row.prop(settings, "use_edit_strength", text="Strength", icon='COLOR', toggle=True)
-            row.prop(settings, "use_edit_thickness", text="Thickness", icon='LINE_DATA', toggle=True)
-
-        # S - Change Brush Type Shortcuts
-        row = pie.row()
-        row.prop_enum(settings, "tool", value='GRAB')
-        row.prop_enum(settings, "tool", value='PUSH')
-        row.prop_enum(settings, "tool", va

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list