3D View: option not to draw center dots
While this is a fairly obscure option, it means it's possible to disable all overlays except for any overlays the users wants to see.
This commit is contained in:
@@ -4045,7 +4045,10 @@ class VIEW3D_PT_overlay_object(Panel):
|
||||
sub = split.column(align=True)
|
||||
sub.prop(overlay, "show_bones", text="Bones")
|
||||
sub.prop(overlay, "show_motion_paths")
|
||||
sub.prop(overlay, "show_all_objects_origin")
|
||||
sub.prop(overlay, "show_object_origins")
|
||||
subsub = sub.column()
|
||||
subsub.active = overlay.show_object_origins
|
||||
subsub.prop(overlay, "show_object_origins_all")
|
||||
|
||||
|
||||
class VIEW3D_PT_overlay_geometry(Panel):
|
||||
|
||||
@@ -1975,6 +1975,10 @@ static void DRW_shgroup_relationship_lines(OBJECT_StorageList *stl, Object *ob)
|
||||
|
||||
static void DRW_shgroup_object_center(OBJECT_StorageList *stl, Object *ob, ViewLayer *view_layer, View3D *v3d)
|
||||
{
|
||||
if (v3d->overlay.flag & V3D_OVERLAY_HIDE_OBJECT_ORIGINS) {
|
||||
return;
|
||||
}
|
||||
|
||||
const bool is_library = ob->id.us > 1 || ID_IS_LINKED(ob);
|
||||
DRWShadingGroup *shgroup;
|
||||
|
||||
|
||||
@@ -388,6 +388,7 @@ enum {
|
||||
V3D_OVERLAY_ONION_SKINS = (1 << 7),
|
||||
V3D_OVERLAY_HIDE_BONES = (1 << 8),
|
||||
V3D_OVERLAY_HIDE_OBJECT_XTRAS = (1 << 9),
|
||||
V3D_OVERLAY_HIDE_OBJECT_ORIGINS = (1 << 10),
|
||||
};
|
||||
|
||||
/* View3DOverlay->edit_flag */
|
||||
|
||||
@@ -2609,7 +2609,12 @@ static void rna_def_space_view3d_overlay(BlenderRNA *brna)
|
||||
"Show an outline highlight around selected objects in non-wireframe views");
|
||||
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
|
||||
|
||||
prop = RNA_def_property(srna, "show_all_objects_origin", PROP_BOOLEAN, PROP_NONE);
|
||||
prop = RNA_def_property(srna, "show_object_origins", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_negative_sdna(prop, NULL, "overlay.flag", V3D_OVERLAY_HIDE_OBJECT_ORIGINS);
|
||||
RNA_def_property_ui_text(prop, "Object Origins", "Show object center dots");
|
||||
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_VIEW3D, NULL);
|
||||
|
||||
prop = RNA_def_property(srna, "show_object_origins_all", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", V3D_DRAW_CENTERS);
|
||||
RNA_def_property_ui_text(prop, "All Object Origins",
|
||||
"Show the object origin center dot for all (selected and unselected) objects");
|
||||
|
||||
Reference in New Issue
Block a user