Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_scene.c
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
| Show First 20 Lines • Show All 2,828 Lines • ▼ Show 20 Lines | static const EnumPropertyItem gpencil_selectmode_items[] = { | ||||
| {GP_SELECTMODE_SEGMENT, | {GP_SELECTMODE_SEGMENT, | ||||
| "SEGMENT", | "SEGMENT", | ||||
| ICON_GP_SELECT_BETWEEN_STROKES, | ICON_GP_SELECT_BETWEEN_STROKES, | ||||
| "Segment", | "Segment", | ||||
| "Select all stroke points between other strokes"}, | "Select all stroke points between other strokes"}, | ||||
| {0, NULL, 0, NULL, NULL}, | {0, NULL, 0, NULL, NULL}, | ||||
| }; | }; | ||||
| static const EnumPropertyItem annotation_stroke_placement_items[] = { | static const EnumPropertyItem annotation_stroke_placement_view2d_items[] = { | ||||
| {GP_PROJECT_VIEWSPACE | GP_PROJECT_CURSOR, | |||||
| "IMAGE", | |||||
| ICON_IMAGE_DATA, | |||||
| "Image", | |||||
| "Strick stroke to the image"}, | |||||
| /* Weird, GP_PROJECT_VIEWALIGN is inverted. */ | |||||
| {0, "VIEW", ICON_RESTRICT_VIEW_ON, "View", "Stick stroke to the view"}, | |||||
| {0, NULL, 0, NULL, NULL}, | |||||
| }; | |||||
| static const EnumPropertyItem annotation_stroke_placement_view3d_items[] = { | |||||
| {GP_PROJECT_VIEWSPACE | GP_PROJECT_CURSOR, | {GP_PROJECT_VIEWSPACE | GP_PROJECT_CURSOR, | ||||
| "CURSOR", | "CURSOR", | ||||
| ICON_PIVOT_CURSOR, | ICON_PIVOT_CURSOR, | ||||
| "3D Cursor", | "3D Cursor", | ||||
| "Draw stroke at 3D cursor location"}, | "Draw stroke at 3D cursor location"}, | ||||
| /* Weird, GP_PROJECT_VIEWALIGN is inverted. */ | /* Weird, GP_PROJECT_VIEWALIGN is inverted. */ | ||||
| {0, "VIEW", ICON_RESTRICT_VIEW_ON, "View", "Stick stroke to the view"}, | {0, "VIEW", ICON_RESTRICT_VIEW_ON, "View", "Stick stroke to the view"}, | ||||
| {GP_PROJECT_VIEWSPACE | GP_PROJECT_DEPTH_VIEW, | {GP_PROJECT_VIEWSPACE | GP_PROJECT_DEPTH_VIEW, | ||||
| ▲ Show 20 Lines • Show All 487 Lines • ▼ Show 20 Lines | static void rna_def_tool_settings(BlenderRNA *brna) | ||||
| RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); | RNA_def_property_clear_flag(prop, PROP_ANIMATABLE); | ||||
| RNA_def_property_flag(prop, PROP_CONTEXT_UPDATE); | RNA_def_property_flag(prop, PROP_CONTEXT_UPDATE); | ||||
| RNA_def_property_update( | RNA_def_property_update( | ||||
| prop, NC_SPACE | ND_SPACE_VIEW3D, "rna_Gpencil_vertex_mask_segment_update"); | prop, NC_SPACE | ND_SPACE_VIEW3D, "rna_Gpencil_vertex_mask_segment_update"); | ||||
| /* Annotations - 2D Views Stroke Placement */ | /* Annotations - 2D Views Stroke Placement */ | ||||
| prop = RNA_def_property(srna, "annotation_stroke_placement_view2d", PROP_ENUM, PROP_NONE); | prop = RNA_def_property(srna, "annotation_stroke_placement_view2d", PROP_ENUM, PROP_NONE); | ||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "gpencil_v2d_align"); | RNA_def_property_enum_bitflag_sdna(prop, NULL, "gpencil_v2d_align"); | ||||
| RNA_def_property_enum_items(prop, annotation_stroke_placement_items); | RNA_def_property_enum_items(prop, annotation_stroke_placement_view2d_items); | ||||
| RNA_def_property_ui_text(prop, "Stroke Placement (2D View)", ""); | RNA_def_property_ui_text(prop, "Stroke Placement (2D View)", ""); | ||||
| RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | ||||
| /* Annotations - Sequencer Preview Stroke Placement */ | |||||
| prop = RNA_def_property( | |||||
| srna, "annotation_stroke_placement_sequencer_preview", PROP_ENUM, PROP_NONE); | |||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "gpencil_seq_align"); | |||||
| RNA_def_property_enum_items(prop, annotation_stroke_placement_items); | |||||
| RNA_def_property_ui_text(prop, "Stroke Placement (Sequencer Preview)", ""); | |||||
| RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | |||||
| /* Annotations - Image Editor Stroke Placement */ | |||||
| prop = RNA_def_property(srna, "annotation_stroke_placement_image_editor", PROP_ENUM, PROP_NONE); | |||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "gpencil_ima_align"); | |||||
| RNA_def_property_enum_items(prop, annotation_stroke_placement_items); | |||||
| RNA_def_property_ui_text(prop, "Stroke Placement (Image Editor)", ""); | |||||
| RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | |||||
| /* Annotations - 3D View Stroke Placement */ | /* Annotations - 3D View Stroke Placement */ | ||||
| /* XXX: Do we need to decouple the stroke_endpoints setting too? */ | /* XXX: Do we need to decouple the stroke_endpoints setting too? */ | ||||
| prop = RNA_def_property(srna, "annotation_stroke_placement_view3d", PROP_ENUM, PROP_NONE); | prop = RNA_def_property(srna, "annotation_stroke_placement_view3d", PROP_ENUM, PROP_NONE); | ||||
| RNA_def_property_enum_bitflag_sdna(prop, NULL, "annotate_v3d_align"); | RNA_def_property_enum_bitflag_sdna(prop, NULL, "annotate_v3d_align"); | ||||
| RNA_def_property_enum_items(prop, annotation_stroke_placement_items); | RNA_def_property_enum_items(prop, annotation_stroke_placement_view3d_items); | ||||
| RNA_def_property_enum_default(prop, GP_PROJECT_VIEWSPACE | GP_PROJECT_CURSOR); | RNA_def_property_enum_default(prop, GP_PROJECT_VIEWSPACE | GP_PROJECT_CURSOR); | ||||
| RNA_def_property_ui_text(prop, | RNA_def_property_ui_text(prop, | ||||
| "Annotation Stroke Placement (3D View)", | "Annotation Stroke Placement (3D View)", | ||||
| "How annotation strokes are orientated in 3D space"); | "How annotation strokes are orientated in 3D space"); | ||||
| RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | RNA_def_property_update(prop, NC_GPENCIL | ND_DATA, NULL); | ||||
| /* Annotations - Stroke Thickness */ | /* Annotations - Stroke Thickness */ | ||||
| prop = RNA_def_property(srna, "annotation_thickness", PROP_INT, PROP_PIXEL); | prop = RNA_def_property(srna, "annotation_thickness", PROP_INT, PROP_PIXEL); | ||||
| ▲ Show 20 Lines • Show All 4,650 Lines • Show Last 20 Lines | |||||