diff options
Diffstat (limited to 'release/scripts/startup/bl_ui/space_userpref.py')
-rw-r--r-- | release/scripts/startup/bl_ui/space_userpref.py | 55 |
1 files changed, 34 insertions, 21 deletions
diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py index cccbb63d27c..49f0fef5849 100644 --- a/release/scripts/startup/bl_ui/space_userpref.py +++ b/release/scripts/startup/bl_ui/space_userpref.py @@ -5,8 +5,11 @@ from bpy.types import ( Menu, Panel, ) -from bpy.app.translations import pgettext_iface as iface_ -from bpy.app.translations import contexts as i18n_contexts +from bpy.app.translations import ( + contexts as i18n_contexts, + pgettext_iface as iface_, + pgettext_tip as tip_, +) # ----------------------------------------------------------------------------- @@ -383,9 +386,8 @@ class USERPREF_PT_edit_objects_duplicate_data(EditingPanel, CenterAlignMixIn, Pa col.prop(edit, "use_duplicate_camera", text="Camera") col.prop(edit, "use_duplicate_curve", text="Curve") # col.prop(edit, "use_duplicate_fcurve", text="F-Curve") # Not implemented. + col.prop(edit, "use_duplicate_curves", text="Curves") col.prop(edit, "use_duplicate_grease_pencil", text="Grease Pencil") - if hasattr(edit, "use_duplicate_curves"): - col.prop(edit, "use_duplicate_curves", text="Curves") col = flow.column() col.prop(edit, "use_duplicate_lattice", text="Lattice") @@ -589,12 +591,6 @@ class USERPREF_PT_system_cycles_devices(SystemPanel, CenterAlignMixIn, Panel): addon.preferences.draw_impl(col, context) del addon - # NOTE: Disabled for until GPU side of OpenSubdiv is brought back. - # system = prefs.system - # if hasattr(system, "opensubdiv_compute_type"): - # col.label(text="OpenSubdiv compute:") - # col.row().prop(system, "opensubdiv_compute_type", text="") - class USERPREF_PT_system_os_settings(SystemPanel, CenterAlignMixIn, Panel): bl_label = "Operating System Settings" @@ -640,7 +636,7 @@ class USERPREF_PT_system_memory(SystemPanel, CenterAlignMixIn, Panel): layout.separator() col = layout.column() - col.prop(system, "vbo_time_out", text="Vbo Time Out") + col.prop(system, "vbo_time_out", text="VBO Time Out") col.prop(system, "vbo_collection_rate", text="Garbage Collection Rate") @@ -656,7 +652,7 @@ class USERPREF_PT_system_video_sequencer(SystemPanel, CenterAlignMixIn, Panel): layout.separator() - layout.prop(system, "use_sequencer_disk_cache") + layout.prop(system, "use_sequencer_disk_cache", text="Disk Cache") col = layout.column() col.active = system.use_sequencer_disk_cache col.prop(system, "sequencer_disk_cache_dir", text="Directory") @@ -1485,11 +1481,13 @@ class USERPREF_PT_saveload_file_browser(SaveLoadPanel, CenterAlignMixIn, Panel): prefs = context.preferences paths = prefs.filepaths + col = layout.column(heading="Show Locations") + col.prop(paths, "show_recent_locations", text="Recent") + col.prop(paths, "show_system_bookmarks", text="System") + col = layout.column(heading="Defaults") col.prop(paths, "use_filter_files") col.prop(paths, "show_hidden_files_datablocks") - col.prop(paths, "show_recent_locations") - col.prop(paths, "show_system_bookmarks") # ----------------------------------------------------------------------------- @@ -1929,9 +1927,11 @@ class USERPREF_PT_addons(AddOnPanel, Panel): if is_visible: if search and not ( - (search in info["name"].lower()) or + (search in info["name"].lower() or + search in iface_(info["name"]).lower()) or (info["author"] and (search in info["author"].lower())) or - ((filter == "All") and (search in info["category"].lower())) + ((filter == "All") and (search in info["category"].lower() or + search in iface_(info["category"]).lower())) ): continue @@ -1955,7 +1955,7 @@ class USERPREF_PT_addons(AddOnPanel, Panel): sub = row.row() sub.active = is_enabled - sub.label(text="%s: %s" % (info["category"], info["name"])) + sub.label(text=iface_("%s: %s") % (iface_(info["category"]), iface_(info["name"]))) if info["warning"]: sub.label(icon='ERROR') @@ -1968,11 +1968,11 @@ class USERPREF_PT_addons(AddOnPanel, Panel): if info["description"]: split = colsub.row().split(factor=0.15) split.label(text="Description:") - split.label(text=info["description"]) + split.label(text=tip_(info["description"])) if info["location"]: split = colsub.row().split(factor=0.15) split.label(text="Location:") - split.label(text=info["location"]) + split.label(text=tip_(info["location"])) if mod: split = colsub.row().split(factor=0.15) split.label(text="File:") @@ -2094,7 +2094,10 @@ class StudioLightPanelMixin: for studio_light in lights: self.draw_studio_light(flow, studio_light) else: - layout.label(text=iface_("No custom %s configured") % self.bl_label) + layout.label(text=self.get_error_message()) + + def get_error_message(self): + return tip_("No custom %s configured") % self.bl_label def draw_studio_light(self, layout, studio_light): box = layout.box() @@ -2121,6 +2124,9 @@ class USERPREF_PT_studiolight_matcaps(StudioLightPanel, StudioLightPanelMixin, P layout.operator("preferences.studiolight_install", icon='IMPORT', text="Install...").type = 'MATCAP' layout.separator() + def get_error_message(self): + return tip_("No custom MatCaps configured") + class USERPREF_PT_studiolight_world(StudioLightPanel, StudioLightPanelMixin, Panel): bl_label = "HDRIs" @@ -2131,6 +2137,9 @@ class USERPREF_PT_studiolight_world(StudioLightPanel, StudioLightPanelMixin, Pan layout.operator("preferences.studiolight_install", icon='IMPORT', text="Install...").type = 'WORLD' layout.separator() + def get_error_message(self): + return tip_("No custom HDRIs configured") + class USERPREF_PT_studiolight_lights(StudioLightPanel, StudioLightPanelMixin, Panel): bl_label = "Studio Lights" @@ -2143,6 +2152,9 @@ class USERPREF_PT_studiolight_lights(StudioLightPanel, StudioLightPanelMixin, Pa op.filter_glob = ".sl" layout.separator() + def get_error_message(self): + return tip_("No custom Studio Lights configured") + class USERPREF_PT_studiolight_light_editor(StudioLightPanel, Panel): bl_label = "Editor" @@ -2262,6 +2274,7 @@ class USERPREF_PT_experimental_new_features(ExperimentalPanel, Panel): ({"property": "use_sculpt_tools_tilt"}, "T82877"), ({"property": "use_extended_asset_browser"}, ("project/view/130/", "Project Page")), ({"property": "use_override_templates"}, ("T73318", "Milestone 4")), + ({"property": "use_realtime_compositor"}, "T99210"), ), ) @@ -2278,7 +2291,6 @@ class USERPREF_PT_experimental_prototypes(ExperimentalPanel, Panel): ({"property": "use_full_frame_compositor"}, "T88150"), ({"property": "enable_eevee_next"}, "T93220"), ({"property": "use_draw_manager_acquire_lock"}, "T98016"), - ({"property": "use_override_new_fully_editable"}, None), ), ) @@ -2315,6 +2327,7 @@ class USERPREF_PT_experimental_debugging(ExperimentalPanel, Panel): ({"property": "use_cycles_debug"}, None), ({"property": "show_asset_debug_info"}, None), ({"property": "use_asset_indexing"}, None), + ({"property": "use_viewport_debug"}, None), ), ) |