forked from blender/blender
index-of-nearest-104619 #2
@ -1414,10 +1414,10 @@ def brush_basic_gpencil_weight_settings(layout, _context, brush, *, compact=Fals
|
|||||||
row = layout.row(align=True)
|
row = layout.row(align=True)
|
||||||
row.prop(brush, "strength", slider=True)
|
row.prop(brush, "strength", slider=True)
|
||||||
row.prop(brush, "use_pressure_strength", text="")
|
row.prop(brush, "use_pressure_strength", text="")
|
||||||
|
|
||||||
if brush.gpencil_weight_tool in {'WEIGHT'}:
|
if brush.gpencil_weight_tool in {'WEIGHT'}:
|
||||||
layout.prop(brush, "weight", slider=True)
|
layout.prop(brush, "weight", slider=True)
|
||||||
|
|
||||||
gp_settings = brush.gpencil_settings
|
gp_settings = brush.gpencil_settings
|
||||||
layout.prop(gp_settings, "direction", expand=True, text="" if compact else "Direction")
|
layout.prop(gp_settings, "direction", expand=True, text="" if compact else "Direction")
|
||||||
|
|
||||||
|
@ -414,11 +414,11 @@ class _draw_tool_settings_context_mode:
|
|||||||
return False
|
return False
|
||||||
paint = context.tool_settings.gpencil_weight_paint
|
paint = context.tool_settings.gpencil_weight_paint
|
||||||
brush = paint.brush
|
brush = paint.brush
|
||||||
|
|
||||||
layout.template_ID_preview(paint, "brush", rows=3, cols=8, hide_buttons=True)
|
layout.template_ID_preview(paint, "brush", rows=3, cols=8, hide_buttons=True)
|
||||||
|
|
||||||
brush_basic_gpencil_weight_settings(layout, context, brush, compact=True)
|
brush_basic_gpencil_weight_settings(layout, context, brush, compact=True)
|
||||||
|
|
||||||
layout.popover("VIEW3D_PT_tools_grease_pencil_weight_options", text="Options")
|
layout.popover("VIEW3D_PT_tools_grease_pencil_weight_options", text="Options")
|
||||||
layout.popover("VIEW3D_PT_tools_grease_pencil_brush_weight_falloff", text="Falloff")
|
layout.popover("VIEW3D_PT_tools_grease_pencil_brush_weight_falloff", text="Falloff")
|
||||||
|
|
||||||
@ -7666,7 +7666,7 @@ class VIEW3D_PT_gpencil_weight_context_menu(Panel):
|
|||||||
settings = tool_settings.gpencil_weight_paint
|
settings = tool_settings.gpencil_weight_paint
|
||||||
brush = settings.brush
|
brush = settings.brush
|
||||||
layout = self.layout
|
layout = self.layout
|
||||||
|
|
||||||
# Weight settings
|
# Weight settings
|
||||||
brush_basic_gpencil_weight_settings(layout, context, brush)
|
brush_basic_gpencil_weight_settings(layout, context, brush)
|
||||||
|
|
||||||
|
@ -2023,7 +2023,7 @@ class VIEW3D_PT_tools_grease_pencil_weight_paint_settings(Panel, View3DPanel, Gr
|
|||||||
def draw(self, context):
|
def draw(self, context):
|
||||||
if self.is_popover:
|
if self.is_popover:
|
||||||
return
|
return
|
||||||
|
|
||||||
layout = self.layout
|
layout = self.layout
|
||||||
layout.use_property_split = True
|
layout.use_property_split = True
|
||||||
layout.use_property_decorate = False
|
layout.use_property_decorate = False
|
||||||
@ -2055,13 +2055,13 @@ class VIEW3D_PT_tools_grease_pencil_brush_weight_falloff(GreasePencilBrushFallof
|
|||||||
class VIEW3D_PT_tools_grease_pencil_weight_options(Panel, View3DPanel, GreasePencilWeightPanel):
|
class VIEW3D_PT_tools_grease_pencil_weight_options(Panel, View3DPanel, GreasePencilWeightPanel):
|
||||||
bl_label = "Options"
|
bl_label = "Options"
|
||||||
bl_options = {'DEFAULT_CLOSED'}
|
bl_options = {'DEFAULT_CLOSED'}
|
||||||
|
|
||||||
def draw(self, context):
|
def draw(self, context):
|
||||||
layout = self.layout
|
layout = self.layout
|
||||||
layout.use_property_split = True
|
layout.use_property_split = True
|
||||||
layout.use_property_decorate = False
|
layout.use_property_decorate = False
|
||||||
tool_settings = context.scene.tool_settings
|
tool_settings = context.scene.tool_settings
|
||||||
|
|
||||||
col = layout.column()
|
col = layout.column()
|
||||||
col.prop(tool_settings, "use_auto_normalize", text="Auto Normalize")
|
col.prop(tool_settings, "use_auto_normalize", text="Auto Normalize")
|
||||||
|
|
||||||
|
@ -3665,7 +3665,8 @@ static bool do_mesh_box_select(ViewContext *vc,
|
|||||||
}
|
}
|
||||||
if (ts->selectmode & SCE_SELECT_EDGE) {
|
if (ts->selectmode & SCE_SELECT_EDGE) {
|
||||||
/* Does both use_zbuf and non-use_zbuf versions (need screen cos for both) */
|
/* Does both use_zbuf and non-use_zbuf versions (need screen cos for both) */
|
||||||
struct BoxSelectUserData_ForMeshEdge cb_data {};
|
struct BoxSelectUserData_ForMeshEdge cb_data {
|
||||||
|
};
|
||||||
cb_data.data = &data;
|
cb_data.data = &data;
|
||||||
cb_data.esel = use_zbuf ? esel : nullptr;
|
cb_data.esel = use_zbuf ? esel : nullptr;
|
||||||
cb_data.backbuf_offset = use_zbuf ? DRW_select_buffer_context_offset_for_object_elem(
|
cb_data.backbuf_offset = use_zbuf ? DRW_select_buffer_context_offset_for_object_elem(
|
||||||
|
Loading…
Reference in New Issue
Block a user