Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_userdef.c
| Show First 20 Lines • Show All 139 Lines • ▼ Show 20 Lines | |||||
| /* also used by buffer swap switching */ | /* also used by buffer swap switching */ | ||||
| static void rna_userdef_dpi_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | static void rna_userdef_dpi_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | ||||
| { | { | ||||
| /* font's are stored at each DPI level, without this we can easy load 100's of fonts */ | /* font's are stored at each DPI level, without this we can easy load 100's of fonts */ | ||||
| BLF_cache_clear(); | BLF_cache_clear(); | ||||
| BKE_blender_userdef_refresh(); | BKE_blender_userdef_refresh(); | ||||
| WM_main_add_notifier(NC_WINDOW, NULL); /* full redraw */ | WM_main_add_notifier(NC_WINDOW, NULL); /* full redraw */ | ||||
| WM_main_add_notifier(NC_SCREEN | NA_EDITED, NULL); /* refresh region sizes */ | WM_main_add_notifier(NC_WORKSPACE | NA_EDITED, NULL); /* refresh region sizes */ | ||||
| } | } | ||||
| static void rna_userdef_virtual_pixel_update(Main *bmain, Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | static void rna_userdef_virtual_pixel_update(Main *bmain, Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | ||||
| { | { | ||||
| /* font's are stored at each DPI level, without this we can easy load 100's of fonts */ | /* font's are stored at each DPI level, without this we can easy load 100's of fonts */ | ||||
| BLF_cache_clear(); | BLF_cache_clear(); | ||||
| BKE_blender_userdef_refresh(); | BKE_blender_userdef_refresh(); | ||||
| /* force setting drawable again */ | /* force setting drawable again */ | ||||
| wmWindowManager *wm = bmain->wm.first; | wmWindowManager *wm = bmain->wm.first; | ||||
| if (wm) { | if (wm) { | ||||
| wm->windrawable = NULL; | wm->windrawable = NULL; | ||||
| } | } | ||||
| WM_main_add_notifier(NC_WINDOW, NULL); /* full redraw */ | WM_main_add_notifier(NC_WINDOW, NULL); /* full redraw */ | ||||
| WM_main_add_notifier(NC_SCREEN | NA_EDITED, NULL); /* refresh region sizes */ | WM_main_add_notifier(NC_WORKSPACE | NA_EDITED, NULL); /* refresh region sizes */ | ||||
| } | } | ||||
| static void rna_userdef_language_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | static void rna_userdef_language_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *UNUSED(ptr)) | ||||
| { | { | ||||
| BLF_cache_clear(); | BLF_cache_clear(); | ||||
| BLT_lang_set(NULL); | BLT_lang_set(NULL); | ||||
| UI_reinit_font(); | UI_reinit_font(); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 3,161 Lines • ▼ Show 20 Lines | static void rna_def_userdef_view(BlenderRNA *brna) | ||||
| RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", USER_TOOLTIPS_PYTHON); | RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", USER_TOOLTIPS_PYTHON); | ||||
| RNA_def_property_ui_text(prop, "Python Tooltips", "Show Python references in tooltips"); | RNA_def_property_ui_text(prop, "Python Tooltips", "Show Python references in tooltips"); | ||||
| prop = RNA_def_property(srna, "show_object_info", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "show_object_info", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "uiflag", USER_DRAWVIEWINFO); | RNA_def_property_boolean_sdna(prop, NULL, "uiflag", USER_DRAWVIEWINFO); | ||||
| RNA_def_property_ui_text(prop, "Display Object Info", "Display objects name and frame number in 3D view"); | RNA_def_property_ui_text(prop, "Display Object Info", "Display objects name and frame number in 3D view"); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "use_global_scene", PROP_BOOLEAN, PROP_NONE); | |||||
| RNA_def_property_boolean_sdna(prop, NULL, "flag", USER_SCENEGLOBAL); | |||||
| RNA_def_property_ui_text(prop, "Global Scene", "Force the current Scene to be displayed in all Screens"); | |||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | |||||
| prop = RNA_def_property(srna, "show_large_cursors", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "show_large_cursors", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "curssize", 0); | RNA_def_property_boolean_sdna(prop, NULL, "curssize", 0); | ||||
| RNA_def_property_ui_text(prop, "Large Cursors", "Use large mouse cursors when available"); | RNA_def_property_ui_text(prop, "Large Cursors", "Use large mouse cursors when available"); | ||||
| RNA_def_property_update(prop, 0, "rna_userdef_update"); | RNA_def_property_update(prop, 0, "rna_userdef_update"); | ||||
| prop = RNA_def_property(srna, "show_view_name", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "show_view_name", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "uiflag", USER_SHOW_VIEWPORTNAME); | RNA_def_property_boolean_sdna(prop, NULL, "uiflag", USER_SHOW_VIEWPORTNAME); | ||||
| RNA_def_property_ui_text(prop, "Show View Name", "Show the name of the view's direction in each 3D View"); | RNA_def_property_ui_text(prop, "Show View Name", "Show the name of the view's direction in each 3D View"); | ||||
| ▲ Show 20 Lines • Show All 1,392 Lines • Show Last 20 Lines | |||||