Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_userdef.c
| Show First 20 Lines • Show All 1,573 Lines • ▼ Show 20 Lines | static void rna_def_userdef_theme_spaces_gpencil(StructRNA *srna) | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "gp_vertex_size", PROP_INT, PROP_NONE); | prop = RNA_def_property(srna, "gp_vertex_size", PROP_INT, PROP_NONE); | ||||
| RNA_def_property_range(prop, 1, 10); | RNA_def_property_range(prop, 1, 10); | ||||
| RNA_def_property_ui_text(prop, "Grease Pencil Vertex Size", ""); | RNA_def_property_ui_text(prop, "Grease Pencil Vertex Size", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| } | } | ||||
| static void advance_section(StructRNA *srna, char *id) | |||||
| { | |||||
| PropertyRNA *prop = RNA_def_property(srna, id, PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_float_sdna(prop, NULL, "empty"); | |||||
| } | |||||
| static void rna_def_userdef_theme_space_view3d(BlenderRNA *brna) | static void rna_def_userdef_theme_space_view3d(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| /* space_view3d */ | /* space_view3d */ | ||||
| srna = RNA_def_struct(brna, "ThemeView3D", NULL); | srna = RNA_def_struct(brna, "ThemeView3D", NULL); | ||||
| RNA_def_struct_sdna(srna, "ThemeSpace"); | RNA_def_struct_sdna(srna, "ThemeSpace"); | ||||
| RNA_def_struct_clear_flag(srna, STRUCT_UNDO); | RNA_def_struct_clear_flag(srna, STRUCT_UNDO); | ||||
| RNA_def_struct_ui_text(srna, "Theme 3D View", "Theme settings for the 3D View"); | RNA_def_struct_ui_text(srna, "Theme 3D View", "Theme settings for the 3D View"); | ||||
| rna_def_userdef_theme_spaces_gradient(srna); | rna_def_userdef_theme_spaces_gradient(srna); | ||||
| /* General Viewport options */ | |||||
| prop = RNA_def_property(srna, "grid", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "grid", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Grid", ""); | RNA_def_property_ui_text(prop, "Grid", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "clipping_border_3d", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 4); | |||||
| RNA_def_property_ui_text(prop, "Clipping Border", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "wire", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "wire", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Wire", ""); | RNA_def_property_ui_text(prop, "Wire", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "wire_edit", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "wire_edit", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Wire Edit", ""); | RNA_def_property_ui_text(prop, "Wire Edit", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| rna_def_userdef_theme_spaces_gpencil(srna); | |||||
| prop = RNA_def_property(srna, "lamp", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 4); | |||||
| RNA_def_property_ui_text(prop, "Lamp", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "speaker", PROP_FLOAT, PROP_COLOR_GAMMA); | /* Grease Pencil */ | ||||
| RNA_def_property_array(prop, 3); | |||||
| RNA_def_property_ui_text(prop, "Speaker", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "camera", PROP_FLOAT, PROP_COLOR_GAMMA); | rna_def_userdef_theme_spaces_gpencil(srna); | ||||
| RNA_def_property_array(prop, 3); | |||||
| RNA_def_property_ui_text(prop, "Camera", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "view_overlay", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "text_grease_pencil", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "time_gp_keyframe"); | |||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "View Overlay", ""); | RNA_def_property_ui_text(prop, "Grease Pencil Keyframe", "Color for indicating Grease Pencil keyframes"); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "empty", PROP_FLOAT, PROP_COLOR_GAMMA); | /* Object specific options */ | ||||
| RNA_def_property_array(prop, 3); | advance_section(srna, "userpref_section_object"); | ||||
| RNA_def_property_ui_text(prop, "Empty", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "object_selected", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "object_selected", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "select"); | RNA_def_property_float_sdna(prop, NULL, "select"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Object Selected", ""); | RNA_def_property_ui_text(prop, "Object Selected", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "object_active", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "object_active", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| Show All 9 Lines | static void rna_def_userdef_theme_space_view3d(BlenderRNA *brna) | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "object_grouped_active", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "object_grouped_active", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "group_active"); | RNA_def_property_float_sdna(prop, NULL, "group_active"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Object Grouped Active", ""); | RNA_def_property_ui_text(prop, "Object Grouped Active", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "transform", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "text_keyframe", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "time_keyframe"); | |||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Transform", ""); | RNA_def_property_ui_text(prop, "Object Keyframe", "Color for indicating Object keyframes"); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| /* Object type options */ | |||||
| advance_section(srna, "userpref_section_obtype"); | |||||
| prop = RNA_def_property(srna, "camera", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 3); | |||||
| RNA_def_property_ui_text(prop, "Camera", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "empty", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 3); | |||||
| RNA_def_property_ui_text(prop, "Empty", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "lamp", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 4); | |||||
| RNA_def_property_ui_text(prop, "Lamp", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "speaker", PROP_FLOAT, PROP_COLOR_GAMMA); | |||||
| RNA_def_property_array(prop, 3); | |||||
| RNA_def_property_ui_text(prop, "Speaker", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| /* Mesh Object specific */ | |||||
| advance_section(srna, "userpref_section_mesh"); | |||||
| rna_def_userdef_theme_spaces_vertex(srna); | rna_def_userdef_theme_spaces_vertex(srna); | ||||
| rna_def_userdef_theme_spaces_edge(srna); | rna_def_userdef_theme_spaces_edge(srna); | ||||
| rna_def_userdef_theme_spaces_face(srna); | rna_def_userdef_theme_spaces_face(srna); | ||||
| /* Mesh Object specific curves*/ | |||||
| advance_section(srna, "userpref_section_curves"); | |||||
| rna_def_userdef_theme_spaces_curves(srna, true, true, true, false); | rna_def_userdef_theme_spaces_curves(srna, true, true, true, false); | ||||
| prop = RNA_def_property(srna, "extra_edge_len", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "extra_edge_len", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Edge Length Text", ""); | RNA_def_property_ui_text(prop, "Edge Length Text", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "extra_edge_angle", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "extra_edge_angle", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| Show All 27 Lines | static void rna_def_userdef_theme_space_view3d(BlenderRNA *brna) | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "split_normal", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "split_normal", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "loop_normal"); | RNA_def_property_float_sdna(prop, NULL, "loop_normal"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Split Normal", ""); | RNA_def_property_ui_text(prop, "Split Normal", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "bone_solid", PROP_FLOAT, PROP_COLOR_GAMMA); | /* Armature Object specific */ | ||||
| RNA_def_property_array(prop, 3); | advance_section(srna, "userpref_section_armature"); | ||||
| RNA_def_property_ui_text(prop, "Bone Solid", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "bone_pose", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "bone_pose", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Bone Pose", ""); | RNA_def_property_ui_text(prop, "Bone Pose", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "bone_pose_active", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "bone_pose_active", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Bone Pose Active", ""); | RNA_def_property_ui_text(prop, "Bone Pose Active", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "frame_current", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "bone_solid", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "cframe"); | |||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Current Frame", ""); | RNA_def_property_ui_text(prop, "Bone Solid", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "outline_width", PROP_INT, PROP_NONE); | /* misc */ | ||||
| RNA_def_property_range(prop, 1, 5); | advance_section(srna, "userpref_section_misc"); | ||||
| RNA_def_property_ui_text(prop, "Outline Width", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "bundle_solid", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "bundle_solid", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "bundle_solid"); | RNA_def_property_float_sdna(prop, NULL, "bundle_solid"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Bundle Solid", ""); | RNA_def_property_ui_text(prop, "Bundle Solid", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "camera_path", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "camera_path", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "camera_path"); | RNA_def_property_float_sdna(prop, NULL, "camera_path"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Camera Path", ""); | RNA_def_property_ui_text(prop, "Camera Path", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "skin_root", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "skin_root", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Skin Root", ""); | RNA_def_property_ui_text(prop, "Skin Root", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "clipping_border_3d", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "view_overlay", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_array(prop, 4); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Clipping Border", ""); | RNA_def_property_ui_text(prop, "View Overlay", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "text_keyframe", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "transform", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "time_keyframe"); | |||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Keyframe", "Color for indicating Object keyframes"); | RNA_def_property_ui_text(prop, "Transform", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "text_grease_pencil", PROP_FLOAT, PROP_COLOR_GAMMA); | prop = RNA_def_property(srna, "frame_current", PROP_FLOAT, PROP_COLOR_GAMMA); | ||||
| RNA_def_property_float_sdna(prop, NULL, "time_gp_keyframe"); | RNA_def_property_float_sdna(prop, NULL, "cframe"); | ||||
| RNA_def_property_array(prop, 3); | RNA_def_property_array(prop, 3); | ||||
| RNA_def_property_ui_text(prop, "Grease Pencil", "Color for indicating Grease Pencil keyframes"); | RNA_def_property_ui_text(prop, "Current Frame", ""); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| rna_def_userdef_theme_spaces_paint_curves(srna); | rna_def_userdef_theme_spaces_paint_curves(srna); | ||||
| advance_section(srna, "userpref_section_values"); | |||||
| prop = RNA_def_property(srna, "outline_width", PROP_INT, PROP_NONE); | |||||
| RNA_def_property_range(prop, 1, 5); | |||||
| RNA_def_property_ui_text(prop, "Outline Width", ""); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| } | } | ||||
| static void rna_def_userdef_theme_space_graph(BlenderRNA *brna) | static void rna_def_userdef_theme_space_graph(BlenderRNA *brna) | ||||
| { | { | ||||
| StructRNA *srna; | StructRNA *srna; | ||||
| PropertyRNA *prop; | PropertyRNA *prop; | ||||
| ▲ Show 20 Lines • Show All 3,019 Lines • Show Last 20 Lines | |||||