Brushstroke Tools: Initial Version #328
@ -125,8 +125,6 @@ def draw_panel_ui_recursive(panel, panel_name, mod, items, display_mode, hide_pa
|
|||||||
col.prop(s, 'hide_ui', icon_only=True, icon='UNPINNED' if s.hide_ui else 'PINNED', emboss=False)
|
col.prop(s, 'hide_ui', icon_only=True, icon='UNPINNED' if s.hide_ui else 'PINNED', emboss=False)
|
||||||
|
|
||||||
def draw_material_settings(layout, material):
|
def draw_material_settings(layout, material):
|
||||||
settings = bpy.context.scene.BSBST_settings
|
|
||||||
|
|
||||||
layout.prop(material.node_tree.nodes['Opacity'].outputs[0], 'default_value', text='Opacity')
|
layout.prop(material.node_tree.nodes['Opacity'].outputs[0], 'default_value', text='Opacity')
|
||||||
layout.prop(material.node_tree.nodes['Use Strength'], 'mute', text='Use Brush Strength', invert_checkbox=True)
|
layout.prop(material.node_tree.nodes['Use Strength'], 'mute', text='Use Brush Strength', invert_checkbox=True)
|
||||||
layout.prop(material.node_tree.nodes['Color Variation'].inputs[0], 'default_value', text='Color Variation')
|
layout.prop(material.node_tree.nodes['Color Variation'].inputs[0], 'default_value', text='Color Variation')
|
||||||
@ -278,6 +276,12 @@ class BSBST_PT_brushstroke_tools_panel(bpy.types.Panel):
|
|||||||
style_panel.label(text='No Brushstroke Context Found', icon='ERROR')
|
style_panel.label(text='No Brushstroke Context Found', icon='ERROR')
|
||||||
return
|
return
|
||||||
if not is_preset and len(settings.context_brushstrokes)>0:
|
if not is_preset and len(settings.context_brushstrokes)>0:
|
||||||
|
row = style_panel.row()
|
||||||
|
row.template_list("BSBST_UL_brushstroke_objects", "", settings, "context_brushstrokes",
|
||||||
|
settings, "active_context_brushstrokes_index", rows=1, maxrows=5, sort_lock=True)
|
||||||
|
column = row.column(align=True)
|
||||||
|
column.operator('brushstroke_tools.delete_brushstrokes', text='', icon='TRASH')
|
||||||
|
|
||||||
row = style_panel.row()
|
row = style_panel.row()
|
||||||
row_edit = row.row(align=True)
|
row_edit = row.row(align=True)
|
||||||
row_edit.operator('brushstroke_tools.select_surface', icon='OUTLINER_OB_SURFACE', text='')
|
row_edit.operator('brushstroke_tools.select_surface', icon='OUTLINER_OB_SURFACE', text='')
|
||||||
@ -285,9 +289,6 @@ class BSBST_PT_brushstroke_tools_panel(bpy.types.Panel):
|
|||||||
text = 'Edit Flow' if getattr(bs_ob, '["BSBST_method"]', None)=='SURFACE_FILL' else 'Edit Brushstrokes'
|
text = 'Edit Flow' if getattr(bs_ob, '["BSBST_method"]', None)=='SURFACE_FILL' else 'Edit Brushstrokes'
|
||||||
row_edit.operator('brushstroke_tools.edit_brushstrokes', icon='GREASEPENCIL', text = text)
|
row_edit.operator('brushstroke_tools.edit_brushstrokes', icon='GREASEPENCIL', text = text)
|
||||||
row_edit.prop(settings, 'edit_toggle', icon='RESTRICT_SELECT_OFF' if settings.edit_toggle else 'RESTRICT_SELECT_ON', icon_only=True)
|
row_edit.prop(settings, 'edit_toggle', icon='RESTRICT_SELECT_OFF' if settings.edit_toggle else 'RESTRICT_SELECT_ON', icon_only=True)
|
||||||
row.operator('brushstroke_tools.delete_brushstrokes', text='', icon='TRASH')
|
|
||||||
style_panel.template_list("BSBST_UL_brushstroke_objects", "", settings, "context_brushstrokes",
|
|
||||||
settings, "active_context_brushstrokes_index", rows=1, maxrows=5, sort_lock=True)
|
|
||||||
|
|
||||||
if not settings.preset_object and is_preset:
|
if not settings.preset_object and is_preset:
|
||||||
style_panel.operator("brushstroke_tools.init_preset", icon='MODIFIER')
|
style_panel.operator("brushstroke_tools.init_preset", icon='MODIFIER')
|
||||||
|
Loading…
Reference in New Issue
Block a user