* Split Info and User preferences into two separate spaces.
* Renamed Buttons Window to Properties also in RNA identifiers.
This commit is contained in:
2009-08-18 12:58:51 +00:00
parent ac2451c6be
commit 990dcd0f7f
53 changed files with 923 additions and 480 deletions

View File

@@ -791,7 +791,7 @@ for member in dir(buttons_material):
del buttons_material
class RenderButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "scene"
# COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class BoneButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "bone"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"
@@ -319,4 +319,4 @@ bpy.types.register(DATA_PT_falloff_curve)
bpy.types.register(DATA_PT_area)
bpy.types.register(DATA_PT_spot)
bpy.types.register(DATA_PT_shadow)
bpy.types.register(DATA_PT_sunsky)
bpy.types.register(DATA_PT_sunsky)

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -1,7 +1,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "modifier"

View File

@@ -2,7 +2,7 @@
import bpy
class DataButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "data"

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicsButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"
@@ -171,7 +171,7 @@ bpy.types.register(PHYSICS_PT_game_physics)
bpy.types.register(PHYSICS_PT_game_collision_bounds)
class SceneButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "scene"
@@ -276,7 +276,7 @@ bpy.types.register(SCENE_PT_game_player)
bpy.types.register(SCENE_PT_game_stereo)
class WorldButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "world"

View File

@@ -2,7 +2,7 @@
import bpy
class MaterialButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "material"
# COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here

View File

@@ -2,7 +2,7 @@
import bpy
class ObjectButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "object"

View File

@@ -2,7 +2,7 @@
import bpy
class ConstraintButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "constraint"

View File

@@ -11,7 +11,7 @@ def particle_panel_poll(context):
return psys.settings.type in ('EMITTER', 'REACTOR', 'HAIR')
class ParticleButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "particle"

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"
@@ -156,4 +156,4 @@ class PHYSICS_PT_smoke_groups(PhysicButtonsPanel):
bpy.types.register(PHYSICS_PT_smoke)
bpy.types.register(PHYSICS_PT_smoke_highres)
bpy.types.register(PHYSICS_PT_smoke_groups)
bpy.types.register(PHYSICS_PT_smoke_groups)

View File

@@ -2,7 +2,7 @@
import bpy
class PhysicButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "physics"

View File

@@ -2,7 +2,7 @@
import bpy
class RenderButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "scene"
# COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here

View File

@@ -2,7 +2,7 @@
import bpy
class TextureButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "texture"

View File

@@ -2,7 +2,7 @@
import bpy
class WorldButtonsPanel(bpy.types.Panel):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__region_type__ = "WINDOW"
__context__ = "world"
# COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here

View File

@@ -2,7 +2,7 @@
import bpy
class Buttons_HT_header(bpy.types.Header):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
def draw(self, context):
layout = self.layout
@@ -21,7 +21,7 @@ class Buttons_HT_header(bpy.types.Header):
row.itemR(scene, "current_frame")
class Buttons_MT_view(bpy.types.Menu):
__space_type__ = "BUTTONS_WINDOW"
__space_type__ = "PROPERTIES"
__label__ = "View"
def draw(self, context):

View File

@@ -2,7 +2,7 @@
import bpy
class INFO_HT_header(bpy.types.Header):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
def draw(self, context):
layout = self.layout
@@ -34,7 +34,7 @@ class INFO_HT_header(bpy.types.Header):
layout.template_running_jobs()
class INFO_MT_file(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "File"
def draw(self, context):
@@ -70,14 +70,14 @@ class INFO_MT_file(bpy.types.Menu):
layout.itemO("wm.exit_blender", text="Quit")
class INFO_MT_file_import(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Import"
def draw(self, context):
layout = self.layout
class INFO_MT_file_export(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Export"
def draw(self, context):
@@ -86,7 +86,7 @@ class INFO_MT_file_export(bpy.types.Menu):
layout.itemO("export.ply", text="PLY")
class INFO_MT_file_external_data(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "External Data"
def draw(self, context):
@@ -103,7 +103,7 @@ class INFO_MT_file_external_data(bpy.types.Menu):
layout.itemO("file.find_missing_files")
class INFO_MT_add(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Add"
def draw(self, context):
@@ -129,7 +129,7 @@ class INFO_MT_add(bpy.types.Menu):
layout.item_enumO("OBJECT_OT_object_add", "type", 'LAMP', icon='ICON_OUTLINER_OB_LAMP')
class INFO_MT_game(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Game"
def draw(self, context):
@@ -138,7 +138,7 @@ class INFO_MT_game(bpy.types.Menu):
layout.itemO("view3d.game_start")
class INFO_MT_render(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Render"
def draw(self, context):
@@ -154,7 +154,7 @@ class INFO_MT_render(bpy.types.Menu):
layout.itemO("screen.render_view_show")
class INFO_MT_help(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__space_type__ = "INFO"
__label__ = "Help"
def draw(self, context):
@@ -170,397 +170,6 @@ class INFO_MT_help(bpy.types.Menu):
layout.itemO("help.developer_community")
layout.itemO("help.user_community")
class INFO_PT_tabs(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__show_header__ = False
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
layout.itemR(userpref, "active_section", expand=True)
class INFO_PT_view(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "View"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'VIEW_CONTROLS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
view = userpref.view
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Display:")
sub1.itemR(view, "tooltips")
sub1.itemR(view, "display_object_info", text="Object Info")
sub1.itemR(view, "use_large_cursors")
sub1.itemR(view, "show_view_name", text="View Name")
sub1.itemR(view, "show_playback_fps", text="Playback FPS")
sub1.itemR(view, "global_scene")
sub1.itemR(view, "pin_floating_panels")
sub1.itemR(view, "object_center_size")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemR(view, "show_mini_axis")
sub2 = sub1.column()
sub2.enabled = view.show_mini_axis
sub2.itemR(view, "mini_axis_size")
sub2.itemR(view, "mini_axis_brightness")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="View Manipulation:")
sub1.itemR(view, "auto_depth")
sub1.itemR(view, "global_pivot")
sub1.itemR(view, "zoom_to_mouse")
sub1.itemR(view, "rotate_around_selection")
sub1.itemS()
sub1.itemL(text="Zoom Style:")
sub1.row().itemR(view, "viewport_zoom_style", expand=True)
sub1.itemL(text="Orbit Style:")
sub1.row().itemR(view, "view_rotation", expand=True)
sub1.itemR(view, "perspective_orthographic_switch")
sub1.itemR(view, "smooth_view")
sub1.itemR(view, "rotation_angle")
sub1.itemS()
sub1.itemL(text="NDOF Device:")
sub1.itemR(view, "ndof_pan_speed", text="Pan Speed")
sub1.itemR(view, "ndof_rotate_speed", text="Orbit Speed")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Mouse Buttons:")
sub1.itemR(view, "left_mouse_button_select")
sub1.itemR(view, "right_mouse_button_select")
sub1.itemR(view, "emulate_3_button_mouse")
sub1.itemR(view, "use_middle_mouse_paste")
sub1.itemR(view, "middle_mouse_rotate")
sub1.itemR(view, "middle_mouse_pan")
sub1.itemR(view, "wheel_invert_zoom")
sub1.itemR(view, "wheel_scroll_lines")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Menus:")
sub1.itemR(view, "open_mouse_over")
sub1.itemL(text="Menu Open Delay:")
sub1.itemR(view, "open_toplevel_delay", text="Top Level")
sub1.itemR(view, "open_sublevel_delay", text="Sub Level")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
#manipulator
sub1.itemR(view, "use_manipulator")
sub2 = sub1.column()
sub2.enabled = view.use_manipulator
sub2.itemR(view, "manipulator_size", text="Size")
sub2.itemR(view, "manipulator_handle_size", text="Handle Size")
sub2.itemR(view, "manipulator_hotspot", text="Hotspot")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Toolbox:")
sub1.itemR(view, "use_column_layout")
sub1.itemL(text="Open Toolbox Delay:")
sub1.itemR(view, "open_left_mouse_delay", text="Hold LMB")
sub1.itemR(view, "open_right_mouse_delay", text="Hold RMB")
class INFO_PT_edit(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "Edit"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'EDIT_METHODS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
edit = userpref.edit
view = userpref.view
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Materials:")
sub1.itemR(edit, "material_linked_object", text="Linked to Object")
sub1.itemR(edit, "material_linked_obdata", text="Linked to ObData")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="New Objects:")
sub1.itemR(edit, "enter_edit_mode")
sub1.itemR(edit, "align_to_view")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Transform:")
sub1.itemR(edit, "drag_immediately")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Snap:")
sub1.itemR(edit, "snap_translate", text="Translate")
sub1.itemR(edit, "snap_rotate", text="Rotate")
sub1.itemR(edit, "snap_scale", text="Scale")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Grease Pencil:")
sub1.itemR(edit, "grease_pencil_manhattan_distance", text="Manhattan Distance")
sub1.itemR(edit, "grease_pencil_euclidean_distance", text="Euclidean Distance")
sub1.itemR(edit, "grease_pencil_smooth_stroke", text="Smooth Stroke")
# sub1.itemR(edit, "grease_pencil_simplify_stroke", text="Simplify Stroke")
sub1.itemR(edit, "grease_pencil_eraser_radius", text="Eraser Radius")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Keyframing:")
sub1.itemR(edit, "use_visual_keying")
sub1.itemR(edit, "new_interpolation_type")
sub1.itemS()
sub1.itemR(edit, "auto_keying_enable", text="Auto Keyframing")
sub2 = sub1.column()
sub2.enabled = edit.auto_keying_enable
sub2.row().itemR(edit, "auto_keying_mode", expand=True)
sub2.itemR(edit, "auto_keyframe_insert_available", text="Only Insert Available")
sub2.itemR(edit, "auto_keyframe_insert_needed", text="Only Insert Needed")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Undo:")
sub1.itemR(edit, "global_undo")
sub1.itemR(edit, "undo_steps", text="Steps")
sub1.itemR(edit, "undo_memory_limit", text="Memory Limit")
sub1.itemS()
sub1.itemS()
sub1.itemS()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Duplicate:")
sub1.itemR(edit, "duplicate_mesh", text="Mesh")
sub1.itemR(edit, "duplicate_surface", text="Surface")
sub1.itemR(edit, "duplicate_curve", text="Curve")
sub1.itemR(edit, "duplicate_text", text="Text")
sub1.itemR(edit, "duplicate_metaball", text="Metaball")
sub1.itemR(edit, "duplicate_armature", text="Armature")
sub1.itemR(edit, "duplicate_lamp", text="Lamp")
sub1.itemR(edit, "duplicate_material", text="Material")
sub1.itemR(edit, "duplicate_texture", text="Texture")
sub1.itemR(edit, "duplicate_ipo", text="F-Curve")
sub1.itemR(edit, "duplicate_action", text="Action")
class INFO_PT_system(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "System"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'SYSTEM_OPENGL')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
system = userpref.system
lan = userpref.language
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemR(system, "emulate_numpad")
sub1.itemS()
sub1.itemS()
#Weight Colors
sub1.itemL(text="Weight Colors:")
sub1.itemR(system, "use_weight_color_range", text="Use Custom Range")
sub2 = sub1.column()
sub2.active = system.use_weight_color_range
sub2.template_color_ramp(system.weight_color_range, expand=True)
sub1.itemS()
sub1.itemS()
#sequencer
sub1.itemL(text="Sequencer:")
sub1.itemR(system, "prefetch_frames")
sub1.itemR(system, "memory_cache_limit")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub .column()
#System
sub1.itemL(text="System:")
sub1.itemR(lan, "dpi")
sub1.itemR(system, "auto_run_python_scripts")
sub1.itemR(system, "frame_server_port")
sub1.itemR(system, "filter_file_extensions")
sub1.itemR(system, "hide_dot_files_datablocks")
sub1.itemR(lan, "scrollback", text="Console Scrollback")
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Sound:")
sub1.itemR(system, "audio_device")
sub2 = sub1.column()
sub2.active = system.audio_device != 'AUDIO_DEVICE_NULL'
sub2.itemR(system, "enable_all_codecs")
sub2.itemR(system, "game_sound")
sub2.itemR(system, "audio_channels")
sub2.itemR(system, "audio_mixing_buffer")
sub2.itemR(system, "audio_sample_rate")
sub2.itemR(system, "audio_sample_format")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
#OpenGL
sub1.itemL(text="OpenGL:")
sub1.itemR(system, "clip_alpha", slider=True)
sub1.itemR(system, "use_mipmaps")
sub1.itemL(text="Window Draw Method:")
sub1.row().itemR(system, "window_draw_method", expand=True)
sub1.itemL(text="Textures:")
sub1.itemR(system, "gl_texture_limit", text="Limit Size")
sub1.itemR(system, "texture_time_out", text="Time Out")
sub1.itemR(system, "texture_collection_rate", text="Collection Rate")
class INFO_PT_filepaths(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "File Paths"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'FILE_PATHS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
paths = userpref.filepaths
split = layout.split()
col = split.column()
col.itemL(text="File Paths:")
sub = col.split(percentage=0.3)
sub.itemL(text="Fonts:")
sub.itemR(paths, "fonts_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Textures:")
sub.itemR(paths, "textures_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Texture Plugins:")
sub.itemR(paths, "texture_plugin_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Sequence Plugins:")
sub.itemR(paths, "sequence_plugin_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Render Output:")
sub.itemR(paths, "render_output_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Scripts:")
sub.itemR(paths, "python_scripts_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Sounds:")
sub.itemR(paths, "sounds_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Temp:")
sub.itemR(paths, "temporary_directory", text="")
col = split.column()
sub = col.split(percentage=0.2)
sub1 = sub.column()
sub2 = sub.column()
sub2.itemL(text="Save & Load:")
sub2.itemR(paths, "use_relative_paths")
sub2.itemR(paths, "compress_file")
sub2.itemL(text="Auto Save:")
sub2.itemR(paths, "save_version")
sub2.itemR(paths, "recent_files")
sub2.itemR(paths, "save_preview_images")
sub2.itemR(paths, "auto_save_temporary_files")
sub3 = sub2.column()
sub3.enabled = paths.auto_save_temporary_files
sub3.itemR(paths, "auto_save_time")
class INFO_PT_language(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "Language"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'LANGUAGE_COLORS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
lan = userpref.language
split = layout.split()
col = split.column()
col.itemR(lan, "language")
col.itemR(lan, "translate_tooltips")
col.itemR(lan, "translate_buttons")
col.itemR(lan, "translate_toolbox")
col.itemR(lan, "use_textured_fonts")
class INFO_PT_bottombar(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = " "
__show_header__ = False
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
split = layout.split(percentage=0.8)
split.itemL(text="")
layout.operator_context = "EXEC_AREA"
split.itemO("wm.save_homefile", text="Save As Default")
bpy.types.register(INFO_HT_header)
bpy.types.register(INFO_MT_file)
bpy.types.register(INFO_MT_file_import)
@@ -570,13 +179,6 @@ bpy.types.register(INFO_MT_add)
bpy.types.register(INFO_MT_game)
bpy.types.register(INFO_MT_render)
bpy.types.register(INFO_MT_help)
bpy.types.register(INFO_PT_tabs)
bpy.types.register(INFO_PT_view)
bpy.types.register(INFO_PT_edit)
bpy.types.register(INFO_PT_system)
bpy.types.register(INFO_PT_filepaths)
bpy.types.register(INFO_PT_language)
bpy.types.register(INFO_PT_bottombar)
# Help operators
@@ -631,3 +233,4 @@ bpy.ops.add(HELP_OT_blender_website)
bpy.ops.add(HELP_OT_blender_eshop)
bpy.ops.add(HELP_OT_developer_community)
bpy.ops.add(HELP_OT_user_community)

View File

@@ -23,8 +23,6 @@ class TIME_HT_header(bpy.types.Header):
layout.itemR(scene, "use_preview_range", text="PR", toggle=True)
layout.itemS()
row = layout.row(align=True)
if not scene.use_preview_range:
row.itemR(scene, "start_frame", text="Start")
@@ -33,10 +31,7 @@ class TIME_HT_header(bpy.types.Header):
row.itemR(scene, "preview_range_start_frame", text="Start")
row.itemR(scene, "preview_range_end_frame", text="End")
layout.itemS()
layout.itemR(scene, "current_frame", text="")
layout.itemS()
row = layout.row(align=True)
row.item_booleanO("screen.frame_jump", "end", False, text="", icon='ICON_REW')
@@ -51,8 +46,6 @@ class TIME_HT_header(bpy.types.Header):
row.item_booleanO("screen.keyframe_jump", "next", True, text="", icon='ICON_NEXT_KEYFRAME')
row.item_booleanO("screen.frame_jump", "end", True, text="", icon='ICON_FF')
layout.itemS()
layout.itemR(rd, "sync_audio", text="", toggle=True, icon='ICON_SPEAKER')
layout.itemS()

View File

@@ -0,0 +1,418 @@
import bpy
class USERPREF_HT_header(bpy.types.Header):
__space_type__ = "USER_PREFERENCES"
def draw(self, context):
layout = self.layout
layout.template_header(menus=False)
class USERPREF_MT_view(bpy.types.Menu):
__space_type__ = "USER_PREFERENCES"
__label__ = "View"
def draw(self, context):
layout = self.layout
class USERPREF_PT_tabs(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__show_header__ = False
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
layout.itemR(userpref, "active_section", expand=True)
class USERPREF_PT_view(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "View"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'VIEW_CONTROLS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
view = userpref.view
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Display:")
sub1.itemR(view, "tooltips")
sub1.itemR(view, "display_object_info", text="Object Info")
sub1.itemR(view, "use_large_cursors")
sub1.itemR(view, "show_view_name", text="View Name")
sub1.itemR(view, "show_playback_fps", text="Playback FPS")
sub1.itemR(view, "global_scene")
sub1.itemR(view, "pin_floating_panels")
sub1.itemR(view, "object_center_size")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemR(view, "show_mini_axis")
sub2 = sub1.column()
sub2.enabled = view.show_mini_axis
sub2.itemR(view, "mini_axis_size")
sub2.itemR(view, "mini_axis_brightness")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="View Manipulation:")
sub1.itemR(view, "auto_depth")
sub1.itemR(view, "global_pivot")
sub1.itemR(view, "zoom_to_mouse")
sub1.itemR(view, "rotate_around_selection")
sub1.itemS()
sub1.itemL(text="Zoom Style:")
sub1.row().itemR(view, "viewport_zoom_style", expand=True)
sub1.itemL(text="Orbit Style:")
sub1.row().itemR(view, "view_rotation", expand=True)
sub1.itemR(view, "perspective_orthographic_switch")
sub1.itemR(view, "smooth_view")
sub1.itemR(view, "rotation_angle")
sub1.itemS()
sub1.itemL(text="NDOF Device:")
sub1.itemR(view, "ndof_pan_speed", text="Pan Speed")
sub1.itemR(view, "ndof_rotate_speed", text="Orbit Speed")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Mouse Buttons:")
sub1.itemR(view, "left_mouse_button_select")
sub1.itemR(view, "right_mouse_button_select")
sub1.itemR(view, "emulate_3_button_mouse")
sub1.itemR(view, "use_middle_mouse_paste")
sub1.itemR(view, "middle_mouse_rotate")
sub1.itemR(view, "middle_mouse_pan")
sub1.itemR(view, "wheel_invert_zoom")
sub1.itemR(view, "wheel_scroll_lines")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Menus:")
sub1.itemR(view, "open_mouse_over")
sub1.itemL(text="Menu Open Delay:")
sub1.itemR(view, "open_toplevel_delay", text="Top Level")
sub1.itemR(view, "open_sublevel_delay", text="Sub Level")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
#manipulator
sub1.itemR(view, "use_manipulator")
sub2 = sub1.column()
sub2.enabled = view.use_manipulator
sub2.itemR(view, "manipulator_size", text="Size")
sub2.itemR(view, "manipulator_handle_size", text="Handle Size")
sub2.itemR(view, "manipulator_hotspot", text="Hotspot")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Toolbox:")
sub1.itemR(view, "use_column_layout")
sub1.itemL(text="Open Toolbox Delay:")
sub1.itemR(view, "open_left_mouse_delay", text="Hold LMB")
sub1.itemR(view, "open_right_mouse_delay", text="Hold RMB")
class USERPREF_PT_edit(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "Edit"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'EDIT_METHODS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
edit = userpref.edit
view = userpref.view
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Materials:")
sub1.itemR(edit, "material_linked_object", text="Linked to Object")
sub1.itemR(edit, "material_linked_obdata", text="Linked to ObData")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="New Objects:")
sub1.itemR(edit, "enter_edit_mode")
sub1.itemR(edit, "align_to_view")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Transform:")
sub1.itemR(edit, "drag_immediately")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Snap:")
sub1.itemR(edit, "snap_translate", text="Translate")
sub1.itemR(edit, "snap_rotate", text="Rotate")
sub1.itemR(edit, "snap_scale", text="Scale")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Grease Pencil:")
sub1.itemR(edit, "grease_pencil_manhattan_distance", text="Manhattan Distance")
sub1.itemR(edit, "grease_pencil_euclidean_distance", text="Euclidean Distance")
sub1.itemR(edit, "grease_pencil_smooth_stroke", text="Smooth Stroke")
# sub1.itemR(edit, "grease_pencil_simplify_stroke", text="Simplify Stroke")
sub1.itemR(edit, "grease_pencil_eraser_radius", text="Eraser Radius")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Keyframing:")
sub1.itemR(edit, "use_visual_keying")
sub1.itemR(edit, "new_interpolation_type")
sub1.itemS()
sub1.itemR(edit, "auto_keying_enable", text="Auto Keyframing")
sub2 = sub1.column()
sub2.enabled = edit.auto_keying_enable
sub2.row().itemR(edit, "auto_keying_mode", expand=True)
sub2.itemR(edit, "auto_keyframe_insert_available", text="Only Insert Available")
sub2.itemR(edit, "auto_keyframe_insert_needed", text="Only Insert Needed")
sub1.itemS()
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Undo:")
sub1.itemR(edit, "global_undo")
sub1.itemR(edit, "undo_steps", text="Steps")
sub1.itemR(edit, "undo_memory_limit", text="Memory Limit")
sub1.itemS()
sub1.itemS()
sub1.itemS()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemL(text="Duplicate:")
sub1.itemR(edit, "duplicate_mesh", text="Mesh")
sub1.itemR(edit, "duplicate_surface", text="Surface")
sub1.itemR(edit, "duplicate_curve", text="Curve")
sub1.itemR(edit, "duplicate_text", text="Text")
sub1.itemR(edit, "duplicate_metaball", text="Metaball")
sub1.itemR(edit, "duplicate_armature", text="Armature")
sub1.itemR(edit, "duplicate_lamp", text="Lamp")
sub1.itemR(edit, "duplicate_material", text="Material")
sub1.itemR(edit, "duplicate_texture", text="Texture")
sub1.itemR(edit, "duplicate_ipo", text="F-Curve")
sub1.itemR(edit, "duplicate_action", text="Action")
class USERPREF_PT_system(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "System"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'SYSTEM_OPENGL')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
system = userpref.system
lan = userpref.language
split = layout.split()
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
sub1.itemR(system, "emulate_numpad")
sub1.itemS()
sub1.itemS()
#Weight Colors
sub1.itemL(text="Weight Colors:")
sub1.itemR(system, "use_weight_color_range", text="Use Custom Range")
sub2 = sub1.column()
sub2.active = system.use_weight_color_range
sub2.template_color_ramp(system.weight_color_range, expand=True)
sub1.itemS()
sub1.itemS()
#sequencer
sub1.itemL(text="Sequencer:")
sub1.itemR(system, "prefetch_frames")
sub1.itemR(system, "memory_cache_limit")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub .column()
#System
sub1.itemL(text="System:")
sub1.itemR(lan, "dpi")
sub1.itemR(system, "auto_run_python_scripts")
sub1.itemR(system, "frame_server_port")
sub1.itemR(system, "filter_file_extensions")
sub1.itemR(system, "hide_dot_files_datablocks")
sub1.itemR(lan, "scrollback", text="Console Scrollback")
sub1.itemS()
sub1.itemS()
sub1.itemL(text="Sound:")
sub1.itemR(system, "audio_device")
sub2 = sub1.column()
sub2.active = system.audio_device != 'AUDIO_DEVICE_NULL'
sub2.itemR(system, "enable_all_codecs")
sub2.itemR(system, "game_sound")
sub2.itemR(system, "audio_channels")
sub2.itemR(system, "audio_mixing_buffer")
sub2.itemR(system, "audio_sample_rate")
sub2.itemR(system, "audio_sample_format")
col = split.column()
sub = col.split(percentage=0.85)
sub1 = sub.column()
#OpenGL
sub1.itemL(text="OpenGL:")
sub1.itemR(system, "clip_alpha", slider=True)
sub1.itemR(system, "use_mipmaps")
sub1.itemL(text="Window Draw Method:")
sub1.row().itemR(system, "window_draw_method", expand=True)
sub1.itemL(text="Textures:")
sub1.itemR(system, "gl_texture_limit", text="Limit Size")
sub1.itemR(system, "texture_time_out", text="Time Out")
sub1.itemR(system, "texture_collection_rate", text="Collection Rate")
class USERPREF_PT_filepaths(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "File Paths"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'FILE_PATHS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
paths = userpref.filepaths
split = layout.split()
col = split.column()
col.itemL(text="File Paths:")
sub = col.split(percentage=0.3)
sub.itemL(text="Fonts:")
sub.itemR(paths, "fonts_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Textures:")
sub.itemR(paths, "textures_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Texture Plugins:")
sub.itemR(paths, "texture_plugin_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Sequence Plugins:")
sub.itemR(paths, "sequence_plugin_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Render Output:")
sub.itemR(paths, "render_output_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Scripts:")
sub.itemR(paths, "python_scripts_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Sounds:")
sub.itemR(paths, "sounds_directory", text="")
sub = col.split(percentage=0.3)
sub.itemL(text="Temp:")
sub.itemR(paths, "temporary_directory", text="")
col = split.column()
sub = col.split(percentage=0.2)
sub1 = sub.column()
sub2 = sub.column()
sub2.itemL(text="Save & Load:")
sub2.itemR(paths, "use_relative_paths")
sub2.itemR(paths, "compress_file")
sub2.itemL(text="Auto Save:")
sub2.itemR(paths, "save_version")
sub2.itemR(paths, "recent_files")
sub2.itemR(paths, "save_preview_images")
sub2.itemR(paths, "auto_save_temporary_files")
sub3 = sub2.column()
sub3.enabled = paths.auto_save_temporary_files
sub3.itemR(paths, "auto_save_time")
class USERPREF_PT_language(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = "Language"
__show_header__ = False
def poll(self, context):
userpref = context.user_preferences
return (userpref.active_section == 'LANGUAGE_COLORS')
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
lan = userpref.language
split = layout.split()
col = split.column()
col.itemR(lan, "language")
col.itemR(lan, "translate_tooltips")
col.itemR(lan, "translate_buttons")
col.itemR(lan, "translate_toolbox")
col.itemR(lan, "use_textured_fonts")
class USERPREF_PT_bottombar(bpy.types.Panel):
__space_type__ = "USER_PREFERENCES"
__label__ = " "
__show_header__ = False
def draw(self, context):
layout = self.layout
userpref = context.user_preferences
split = layout.split(percentage=0.8)
split.itemL(text="")
layout.operator_context = "EXEC_AREA"
split.itemO("wm.save_homefile", text="Save As Default")
bpy.types.register(USERPREF_HT_header)
bpy.types.register(USERPREF_MT_view)
bpy.types.register(USERPREF_PT_tabs)
bpy.types.register(USERPREF_PT_view)
bpy.types.register(USERPREF_PT_edit)
bpy.types.register(USERPREF_PT_system)
bpy.types.register(USERPREF_PT_filepaths)
bpy.types.register(USERPREF_PT_language)
bpy.types.register(USERPREF_PT_bottombar)

View File

@@ -152,6 +152,7 @@ struct SpaceLogic *CTX_wm_space_logic(const bContext *C);
struct SpaceIpo *CTX_wm_space_graph(const bContext *C);
struct SpaceAction *CTX_wm_space_action(const bContext *C);
struct SpaceInfo *CTX_wm_space_info(const bContext *C);
struct SpaceUserPref *CTX_wm_space_userpref(const bContext *C);
void CTX_wm_manager_set(bContext *C, struct wmWindowManager *wm);
void CTX_wm_window_set(bContext *C, struct wmWindow *win);

View File

@@ -338,6 +338,13 @@ struct SpaceInfo *CTX_wm_space_info(const bContext *C)
return NULL;
}
struct SpaceUserPref *CTX_wm_space_userpref(const bContext *C)
{
if(C->wm.area && C->wm.area->spacetype==SPACE_USERPREF)
return C->wm.area->spacedata.first;
return NULL;
}
void CTX_wm_manager_set(bContext *C, wmWindowManager *wm)
{
C->wm.manager= wm;

View File

@@ -2023,6 +2023,10 @@ static void write_screens(WriteData *wd, ListBase *scrbase)
else if(sl->spacetype==SPACE_CONSOLE) {
writestruct(wd, DATA, "SpaceConsole", 1, sl);
}
else if(sl->spacetype==SPACE_USERPREF) {
writestruct(wd, DATA, "SpaceUserPref", 1, sl);
}
sl= sl->next;
}
}

View File

@@ -65,5 +65,6 @@ DIRS = armature \
space_text \
space_sequencer \
space_logic \
space_userpref \
include nan_subdirs.mk

View File

@@ -32,6 +32,7 @@ SConscript(['datafiles/SConscript',
'space_sequencer/SConscript',
'space_logic/SConscript',
'space_console/SConscript',
'space_userpref/SConscript',
'transform/SConscript',
'screen/SConscript',
'sculpt_paint/SConscript',

View File

@@ -52,6 +52,7 @@ void ED_spacetype_text(void);
void ED_spacetype_sequencer(void);
void ED_spacetype_logic(void);
void ED_spacetype_console(void);
void ED_spacetype_userpref(void);
/* calls for instancing and freeing spacetype static data
called in WM_init_exit */

View File

@@ -104,7 +104,7 @@ static int panel_aligned(ScrArea *sa, ARegion *ar)
SpaceButs *sbuts= sa->spacedata.first;
return sbuts->align;
}
else if(sa->spacetype==SPACE_INFO && ar->regiontype == RGN_TYPE_WINDOW)
else if(sa->spacetype==SPACE_USERPREF && ar->regiontype == RGN_TYPE_WINDOW)
return BUT_VERTICAL;
else if(sa->spacetype==SPACE_FILE && ar->regiontype == RGN_TYPE_CHANNELS)
return BUT_VERTICAL;

View File

@@ -150,6 +150,9 @@ char *UI_ThemeGetColorPtr(bTheme *btheme, int spacetype, int colorid)
case SPACE_INFO:
ts= &btheme->tinfo;
break;
case SPACE_USERPREF:
ts= &btheme->tuserpref;
break;
case SPACE_TIME:
ts= &btheme->ttime;
break;
@@ -402,6 +405,7 @@ static void ui_theme_init_new(bTheme *btheme)
ui_theme_init_new_do(&btheme->ttime);
ui_theme_init_new_do(&btheme->tnode);
ui_theme_init_new_do(&btheme->tlogic);
ui_theme_init_new_do(&btheme->tuserpref);
}
@@ -583,6 +587,10 @@ void ui_theme_init_userdef(void)
btheme->tinfo= btheme->tv3d;
SETCOLF(btheme->tinfo.back, 0.45, 0.45, 0.45, 1.0);
/* space user preferences */
btheme->tuserpref= btheme->tv3d;
SETCOLF(btheme->tuserpref.back, 0.45, 0.45, 0.45, 1.0);
/* space sound */
btheme->tsnd= btheme->tv3d;
SETCOLF(btheme->tsnd.back, 0.45, 0.45, 0.45, 1.0);
@@ -1233,6 +1241,7 @@ void init_userdef_do_versions(void)
}
SETCOLF(btheme->tinfo.back, 0.45, 0.45, 0.45, 1.0);
SETCOLF(btheme->tuserpref.back, 0.45, 0.45, 0.45, 1.0);
}
}

View File

@@ -1066,8 +1066,9 @@ static char *windowtype_pup(void)
"|%l"
"|Properties %x4"
"|User Preferences %x7"
"|Outliner %x3"
"|User Preferences %x19"
"|Info%x7"
"|%l"
"|%l"

View File

@@ -77,6 +77,7 @@ void ED_spacetypes_init(void)
ED_spacetype_sequencer();
ED_spacetype_logic();
ED_spacetype_console();
ED_spacetype_userpref();
// ...
/* register operator types for screen and all spaces */

View File

@@ -311,7 +311,6 @@ static int buttons_context_path_brush(const bContext *C, ButsContextPath *path)
ToolSettings *ts;
Brush *br= NULL;
PointerRNA *ptr= &path->ptr[path->len-1];
const Object *obact = CTX_data_active_object(C);
/* if we already have a (pinned) brush, we're done */
if(RNA_struct_is_a(ptr->type, &RNA_Brush)) {
@@ -333,7 +332,7 @@ static int buttons_context_path_brush(const bContext *C, ButsContextPath *path)
}
}
/* no path to a world possible */
/* no path to a brush possible */
return 0;
}

View File

@@ -916,7 +916,7 @@ static int toolbox_invoke(bContext *C, wmOperator *op, wmEvent *event)
uiPopupMenu *pup;
uiLayout *layout;
RNA_pointer_create(&sc->id, &RNA_SpaceButtonsWindow, sbuts, &ptr);
RNA_pointer_create(&sc->id, &RNA_SpaceProperties, sbuts, &ptr);
pup= uiPupMenuBegin(C, "Align", 0);
layout= uiPupMenuLayout(pup);

View File

@@ -32,9 +32,6 @@
struct wmOperatorType;
/* info_header.c */
void info_header_buttons(const bContext *C, ARegion *ar);
void FILE_OT_pack_all(struct wmOperatorType *ot);
void FILE_OT_unpack_all(struct wmOperatorType *ot);
void FILE_OT_make_paths_relative(struct wmOperatorType *ot);

View File

@@ -0,0 +1,55 @@
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# The Original Code is Copyright (C) 2007 Blender Foundation
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): none yet.
#
# ***** END GPL LICENSE BLOCK *****
#
# Makes module object directory and bounces make to subdirectories.
LIBNAME = ed_userpref
DIR = $(OCGDIR)/blender/$(LIBNAME)
include nan_compile.mk
CFLAGS += $(LEVEL_1_C_WARNINGS)
CPPFLAGS += -I$(NAN_GLEW)/include
CPPFLAGS += -I$(OPENGL_HEADERS)
# not very neat....
CPPFLAGS += -I../../windowmanager
CPPFLAGS += -I../../blenloader
CPPFLAGS += -I../../blenkernel
CPPFLAGS += -I../../blenlib
CPPFLAGS += -I../../makesdna
CPPFLAGS += -I../../makesrna
CPPFLAGS += -I../../imbuf
CPPFLAGS += -I../../python
CPPFLAGS += -I../../blenfont
CPPFLAGS += -I$(NAN_GUARDEDALLOC)/include
# own include
CPPFLAGS += -I../include

View File

@@ -0,0 +1,14 @@
#!/usr/bin/python
Import ('env')
sources = env.Glob('*.c')
incs = '../include ../../blenlib ../../blenkernel ../../makesdna ../../makesrna ../../imbuf ../../blenfont'
incs += ' ../../windowmanager #/intern/guardedalloc #/extern/glew/include'
defs = []
if env['WITH_BF_GAMEENGINE']:
defs.append('GAMEBLENDER=1')
env.BlenderLib ( 'bf_editors_space_userpref', sources, Split(incs), defs, libtype=['core'], priority=[70] )

View File

@@ -0,0 +1,188 @@
/**
* $Id:
*
* ***** BEGIN GPL LICENSE BLOCK *****
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
* The Original Code is Copyright (C) 2008 Blender Foundation.
* All rights reserved.
*
*
* Contributor(s): Blender Foundation
*
* ***** END GPL LICENSE BLOCK *****
*/
#include <string.h>
#include <stdio.h>
#include "DNA_space_types.h"
#include "DNA_screen_types.h"
#include "MEM_guardedalloc.h"
#include "BLI_blenlib.h"
#include "BKE_context.h"
#include "BKE_screen.h"
#include "ED_space_api.h"
#include "ED_screen.h"
#include "BIF_gl.h"
#include "WM_api.h"
#include "WM_types.h"
#include "userpref_intern.h" // own include
/* ******************** default callbacks for userpref space ***************** */
static SpaceLink *userpref_new(const bContext *C)
{
ARegion *ar;
SpaceUserPref *spref;
spref= MEM_callocN(sizeof(SpaceUserPref), "inituserpref");
spref->spacetype= SPACE_USERPREF;
/* header */
ar= MEM_callocN(sizeof(ARegion), "header for userpref");
BLI_addtail(&spref->regionbase, ar);
ar->regiontype= RGN_TYPE_HEADER;
ar->alignment= RGN_ALIGN_BOTTOM;
/* main area */
ar= MEM_callocN(sizeof(ARegion), "main area for userpref");
BLI_addtail(&spref->regionbase, ar);
ar->regiontype= RGN_TYPE_WINDOW;
return (SpaceLink *)spref;
}
/* not spacelink itself */
static void userpref_free(SpaceLink *sl)
{
// SpaceUserPref *spref= (SpaceUserPref*) sl;
}
/* spacetype; init callback */
static void userpref_init(struct wmWindowManager *wm, ScrArea *sa)
{
}
static SpaceLink *userpref_duplicate(SpaceLink *sl)
{
SpaceUserPref *sprefn= MEM_dupallocN(sl);
/* clear or remove stuff from old */
return (SpaceLink *)sprefn;
}
/* add handlers, stuff you only do once or on area/region changes */
static void userpref_main_area_init(wmWindowManager *wm, ARegion *ar)
{
ED_region_panels_init(wm, ar);
}
static void userpref_main_area_draw(const bContext *C, ARegion *ar)
{
ED_region_panels(C, ar, 1, NULL, -1);
}
void userpref_operatortypes(void)
{
}
void userpref_keymap(struct wmWindowManager *wm)
{
}
/* add handlers, stuff you only do once or on area/region changes */
static void userpref_header_area_init(wmWindowManager *wm, ARegion *ar)
{
ED_region_header_init(ar);
}
static void userpref_header_area_draw(const bContext *C, ARegion *ar)
{
ED_region_header(C, ar);
}
static void userpref_main_area_listener(ARegion *ar, wmNotifier *wmn)
{
/* context changes */
}
static void userpref_header_listener(ARegion *ar, wmNotifier *wmn)
{
/* context changes */
switch(wmn->category) {
default:
break;
}
}
/* only called once, from space/spacetypes.c */
void ED_spacetype_userpref(void)
{
SpaceType *st= MEM_callocN(sizeof(SpaceType), "spacetype userpref");
ARegionType *art;
st->spaceid= SPACE_USERPREF;
st->new= userpref_new;
st->free= userpref_free;
st->init= userpref_init;
st->duplicate= userpref_duplicate;
st->operatortypes= userpref_operatortypes;
st->keymap= userpref_keymap;
/* regions: main window */
art= MEM_callocN(sizeof(ARegionType), "spacetype userpref region");
art->regionid = RGN_TYPE_WINDOW;
art->init= userpref_main_area_init;
art->draw= userpref_main_area_draw;
art->listener= userpref_main_area_listener;
art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D;
BLI_addhead(&st->regiontypes, art);
/* regions: header */
art= MEM_callocN(sizeof(ARegionType), "spacetype userpref region");
art->regionid = RGN_TYPE_HEADER;
art->minsizey= HEADERY;
art->keymapflag= ED_KEYMAP_UI|ED_KEYMAP_VIEW2D;
art->listener= userpref_header_listener;
art->init= userpref_header_area_init;
art->draw= userpref_header_area_draw;
BLI_addhead(&st->regiontypes, art);
BKE_spacetype_register(st);
}

View File

@@ -0,0 +1,34 @@
/**
* $Id:
*
* ***** BEGIN GPL LICENSE BLOCK *****
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
* The Original Code is Copyright (C) 2008 Blender Foundation.
* All rights reserved.
*
*
* Contributor(s): Blender Foundation
*
* ***** END GPL LICENSE BLOCK *****
*/
#ifndef ED_USERPREF_INTERN_H
#define ED_USERPREF_INTERN_H
/* internal exports only */
#endif /* ED_USERPREF_INTERN_H */

View File

@@ -0,0 +1,33 @@
/**
* $Id$
*
* ***** BEGIN GPL LICENSE BLOCK *****
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software Foundation,
* Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
* The Original Code is Copyright (C) 2008 Blender Foundation.
* All rights reserved.
*
*
* Contributor(s): Blender Foundation
*
* ***** END GPL LICENSE BLOCK *****
*/
#include <string.h>
#include <stdio.h>
#include "userpref_intern.h"

View File

@@ -508,6 +508,13 @@ typedef struct SpaceConsole {
} SpaceConsole;
typedef struct SpaceUserPref {
SpaceLink *next, *prev;
ListBase regionbase; /* storage of regions for inactive spaces */
int spacetype;
int pad;
} SpaceUserPref;
/* view3d Now in DNA_view3d_types.h */
@@ -861,7 +868,8 @@ enum {
SPACE_NODE,
SPACE_LOGIC,
SPACE_CONSOLE,
SPACEICONMAX = SPACE_CONSOLE
SPACE_USERPREF,
SPACEICONMAX = SPACE_USERPREF
};
#endif

View File

@@ -260,6 +260,7 @@ typedef struct bTheme {
ThemeSpace ttime;
ThemeSpace tnode;
ThemeSpace tlogic;
ThemeSpace tuserpref;
/* 20 sets of bone colors for this theme */
ThemeWireColor tarm[20];

View File

@@ -252,6 +252,7 @@ extern StructRNA RNA_MarbleTexture;
extern StructRNA RNA_MaskModifier;
extern StructRNA RNA_Material;
extern StructRNA RNA_MaterialHalo;
extern StructRNA RNA_MaterialPhysics;
extern StructRNA RNA_MaterialRaytraceMirror;
extern StructRNA RNA_MaterialRaytraceTransparency;
extern StructRNA RNA_MaterialSlot;
@@ -304,8 +305,11 @@ extern StructRNA RNA_OperatorStrokeElement;
extern StructRNA RNA_OrController;
extern StructRNA RNA_OutflowFluidSettings;
extern StructRNA RNA_PackedFile;
extern StructRNA RNA_Paint;
extern StructRNA RNA_Panel;
extern StructRNA RNA_Particle;
extern StructRNA RNA_ParticleBrush;
extern StructRNA RNA_ParticleEdit;
extern StructRNA RNA_ParticleFluidSettings;
extern StructRNA RNA_ParticleHairKey;
extern StructRNA RNA_ParticleInstanceModifier;
@@ -328,6 +332,7 @@ extern StructRNA RNA_RadarSensor;
extern StructRNA RNA_RandomSensor;
extern StructRNA RNA_RaySensor;
extern StructRNA RNA_Region;
extern StructRNA RNA_RenderEngine;
extern StructRNA RNA_RenderLayer;
extern StructRNA RNA_RenderPass;
extern StructRNA RNA_RenderResult;
@@ -378,6 +383,9 @@ extern StructRNA RNA_ShapeKeyPoint;
extern StructRNA RNA_ShrinkwrapConstraint;
extern StructRNA RNA_ShrinkwrapModifier;
extern StructRNA RNA_SimpleDeformModifier;
extern StructRNA RNA_SmokeCollSettings;
extern StructRNA RNA_SmokeDomainSettings;
extern StructRNA RNA_SmokeFlowSettings;
extern StructRNA RNA_SmokeModifier;
extern StructRNA RNA_SmoothModifier;
extern StructRNA RNA_SoftBodyModifier;
@@ -386,18 +394,22 @@ extern StructRNA RNA_Sound;
extern StructRNA RNA_SoundSequence;
extern StructRNA RNA_Space;
extern StructRNA RNA_Space3DView;
extern StructRNA RNA_SpaceButtonsWindow;
extern StructRNA RNA_SpaceConsole;
extern StructRNA RNA_SpaceDopeSheetEditor;
extern StructRNA RNA_SpaceFileBrowser;
extern StructRNA RNA_SpaceGraphEditor;
extern StructRNA RNA_SpaceImageEditor;
extern StructRNA RNA_SpaceInfo;
extern StructRNA RNA_SpaceLogicEditor;
extern StructRNA RNA_SpaceNLA;
extern StructRNA RNA_SpaceTimeline;
extern StructRNA RNA_SpaceNodeEditor;
extern StructRNA RNA_SpaceOutliner;
extern StructRNA RNA_SpaceProperties;
extern StructRNA RNA_SpaceSequenceEditor;
extern StructRNA RNA_SpaceTextEditor;
extern StructRNA RNA_SpaceTimeline;
extern StructRNA RNA_SpaceUVEditor;
extern StructRNA RNA_SpaceUserPreferences;
extern StructRNA RNA_SpeedControlSequence;
extern StructRNA RNA_SpotLamp;
extern StructRNA RNA_StretchToConstraint;
@@ -443,16 +455,17 @@ extern StructRNA RNA_TextureSlot;
extern StructRNA RNA_Theme;
extern StructRNA RNA_ThemeAudioWindow;
extern StructRNA RNA_ThemeBoneColorSet;
extern StructRNA RNA_ThemeButtonsWindow;
extern StructRNA RNA_ThemeDopeSheet;
extern StructRNA RNA_ThemeFileBrowser;
extern StructRNA RNA_ThemeFontStyle;
extern StructRNA RNA_ThemeGraphEditor;
extern StructRNA RNA_ThemeImageEditor;
extern StructRNA RNA_ThemeInfo;
extern StructRNA RNA_ThemeLogicEditor;
extern StructRNA RNA_ThemeNLAEditor;
extern StructRNA RNA_ThemeNodeEditor;
extern StructRNA RNA_ThemeOutliner;
extern StructRNA RNA_ThemeProperties;
extern StructRNA RNA_ThemeSequenceEditor;
extern StructRNA RNA_ThemeStyle;
extern StructRNA RNA_ThemeTextEditor;
@@ -474,17 +487,16 @@ extern StructRNA RNA_UVProjectModifier;
extern StructRNA RNA_UnitSettings;
extern StructRNA RNA_UnknownType;
extern StructRNA RNA_UserPreferences;
extern StructRNA RNA_UserPreferencesAutosave;
extern StructRNA RNA_UserPreferencesEdit;
extern StructRNA RNA_UserPreferencesFilePaths;
extern StructRNA RNA_UserPreferencesLanguage;
extern StructRNA RNA_UserPreferencesSystem;
extern StructRNA RNA_UserPreferencesView;
extern StructRNA RNA_UserSolidLight;
extern StructRNA RNA_VertexPaint;
extern StructRNA RNA_VectorFont;
extern StructRNA RNA_VertexGroup;
extern StructRNA RNA_VertexGroupElement;
extern StructRNA RNA_VertexPaint;
extern StructRNA RNA_VoronoiTexture;
extern StructRNA RNA_WaveModifier;
extern StructRNA RNA_Window;

View File

@@ -49,7 +49,7 @@ EnumPropertyItem space_type_items[] = {
{SPACE_BUTS, "PROPERTIES", 0, "Properties", ""},
{SPACE_FILE, "FILE_BROWSER", 0, "File Browser", ""},
{SPACE_IMAGE, "IMAGE_EDITOR", 0, "Image Editor", ""},
{SPACE_INFO, "USER_PREFERENCES", 0, "User Preferences", ""},
{SPACE_INFO, "INFO", 0, "Info", ""},
{SPACE_SEQ, "SEQUENCE_EDITOR", 0, "Sequence Editor", ""},
{SPACE_TEXT, "TEXT_EDITOR", 0, "Text Editor", ""},
//{SPACE_IMASEL, "IMAGE_BROWSER", 0, "Image Browser", ""},
@@ -61,6 +61,7 @@ EnumPropertyItem space_type_items[] = {
{SPACE_NODE, "NODE_EDITOR", 0, "Node Editor", ""},
{SPACE_LOGIC, "LOGIC_EDITOR", 0, "Logic Editor", ""},
{SPACE_CONSOLE, "CONSOLE", 0, "Console", ""},
{SPACE_USERPREF, "USER_PREFERENCES", 0, "User Preferences", ""},
{0, NULL, 0, NULL, NULL}};
#define DC_RGB {0, "COLOR", ICON_IMAGE_RGB, "Color", "Draw image with RGB colors."}
@@ -101,13 +102,13 @@ static StructRNA* rna_Space_refine(struct PointerRNA *ptr)
case SPACE_OUTLINER:
return &RNA_SpaceOutliner;
case SPACE_BUTS:
return &RNA_SpaceButtonsWindow;
return &RNA_SpaceProperties;
case SPACE_FILE:
return &RNA_SpaceFileBrowser;
case SPACE_IMAGE:
return &RNA_SpaceImageEditor;
/*case SPACE_INFO:
return &RNA_SpaceUserPreferences;*/
case SPACE_INFO:
return &RNA_SpaceInfo;
case SPACE_SEQ:
return &RNA_SpaceSequenceEditor;
case SPACE_TEXT:
@@ -124,12 +125,14 @@ static StructRNA* rna_Space_refine(struct PointerRNA *ptr)
return &RNA_SpaceScriptsWindow;*/
case SPACE_TIME:
return &RNA_SpaceTimeline;
/*case SPACE_NODE:
case SPACE_NODE:
return &RNA_SpaceNodeEditor;
case SPACE_LOGIC:
return &RNA_SpaceLogicEditor;*/
return &RNA_SpaceLogicEditor;
case SPACE_CONSOLE:
return &RNA_SpaceConsole;
case SPACE_USERPREF:
return &RNA_SpaceUserPreferences;
default:
return &RNA_Space;
}
@@ -230,9 +233,9 @@ void rna_SpaceFileBrowser_params_set(PointerRNA *ptr, PointerRNA value)
sfile->params= value.data;
}
/* Space Buttons */
/* Space Properties */
StructRNA *rna_SpaceButtonsWindow_pin_id_typef(PointerRNA *ptr)
StructRNA *rna_SpaceProperties_pin_id_typef(PointerRNA *ptr)
{
SpaceButs *sbuts= (SpaceButs*)(ptr->data);
@@ -242,7 +245,7 @@ StructRNA *rna_SpaceButtonsWindow_pin_id_typef(PointerRNA *ptr)
return &RNA_ID;
}
void rna_SpaceButtonsWindow_align_set(PointerRNA *ptr, int value)
void rna_SpaceProperties_align_set(PointerRNA *ptr, int value)
{
SpaceButs *sbuts= (SpaceButs*)(ptr->data);
@@ -718,9 +721,9 @@ static void rna_def_space_buttons(BlenderRNA *brna)
{BUT_VERTICAL, "VERTICAL", 0, "Vertical", ""},
{0, NULL, 0, NULL, NULL}};
srna= RNA_def_struct(brna, "SpaceButtonsWindow", "Space");
srna= RNA_def_struct(brna, "SpaceProperties", "Space");
RNA_def_struct_sdna(srna, "SpaceButs");
RNA_def_struct_ui_text(srna, "Buttons Space", "Buttons Window space data");
RNA_def_struct_ui_text(srna, "Properties Space", "Properties space data");
prop= RNA_def_property(srna, "context", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_sdna(prop, NULL, "mainb");
@@ -731,7 +734,7 @@ static void rna_def_space_buttons(BlenderRNA *brna)
prop= RNA_def_property(srna, "align", PROP_ENUM, PROP_NONE);
RNA_def_property_enum_sdna(prop, NULL, "align");
RNA_def_property_enum_items(prop, align_items);
RNA_def_property_enum_funcs(prop, NULL, "rna_SpaceButtonsWindow_align_set", NULL);
RNA_def_property_enum_funcs(prop, NULL, "rna_SpaceProperties_align_set", NULL);
RNA_def_property_ui_text(prop, "Align", "Arrangement of the panels.");
RNA_def_property_update(prop, NC_WINDOW, NULL);
@@ -744,7 +747,7 @@ static void rna_def_space_buttons(BlenderRNA *brna)
prop= RNA_def_property(srna, "pin_id", PROP_POINTER, PROP_NONE);
RNA_def_property_pointer_sdna(prop, NULL, "pinid");
RNA_def_property_struct_type(prop, "ID");
RNA_def_property_pointer_funcs(prop, NULL, NULL, "rna_SpaceButtonsWindow_pin_id_typef");
RNA_def_property_pointer_funcs(prop, NULL, NULL, "rna_SpaceProperties_pin_id_typef");
RNA_def_property_flag(prop, PROP_EDITABLE);
}
@@ -1377,7 +1380,42 @@ static void rna_def_space_filebrowser(BlenderRNA *brna)
RNA_def_property_pointer_sdna(prop, NULL, "params");
RNA_def_property_pointer_funcs(prop, NULL, "rna_SpaceFileBrowser_params_set", NULL);
RNA_def_property_ui_text(prop, "Filebrowser Parameter", "Parameters and Settings for the Filebrowser.");
}
static void rna_def_space_info(BlenderRNA *brna)
{
StructRNA *srna;
srna= RNA_def_struct(brna, "SpaceInfo", "Space");
RNA_def_struct_sdna(srna, "SpaceInfo");
RNA_def_struct_ui_text(srna, "Space Info", "Info space data.");
}
static void rna_def_space_userpref(BlenderRNA *brna)
{
StructRNA *srna;
srna= RNA_def_struct(brna, "SpaceUserPreferences", "Space");
RNA_def_struct_sdna(srna, "SpaceUserPref");
RNA_def_struct_ui_text(srna, "Space User Preferences", "User preferences space data.");
}
static void rna_def_space_node(BlenderRNA *brna)
{
StructRNA *srna;
srna= RNA_def_struct(brna, "SpaceNodeEditor", "Space");
RNA_def_struct_sdna(srna, "SpaceNode");
RNA_def_struct_ui_text(srna, "Space Node Editor", "Node editor space data.");
}
static void rna_def_space_logic(BlenderRNA *brna)
{
StructRNA *srna;
srna= RNA_def_struct(brna, "SpaceLogicEditor", "Space");
RNA_def_struct_sdna(srna, "SpaceLogic");
RNA_def_struct_ui_text(srna, "Space Logic Editor", "Logic editor space data.");
}
void RNA_def_space(BlenderRNA *brna)
@@ -1398,6 +1436,10 @@ void RNA_def_space(BlenderRNA *brna)
rna_def_space_time(brna);
rna_def_space_console(brna);
rna_def_console_line(brna);
rna_def_space_info(brna);
rna_def_space_userpref(brna);
rna_def_space_node(brna);
rna_def_space_logic(brna);
}
#endif

View File

@@ -690,7 +690,7 @@ static void rna_def_userdef_theme_space_graph(BlenderRNA *brna)
srna= RNA_def_struct(brna, "ThemeGraphEditor", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme Graph Editor", "Theme settings for the Ipo Editor.");
RNA_def_struct_ui_text(srna, "Theme Graph Editor", "Theme settings for the graph editor.");
rna_def_userdef_theme_spaces_main(srna, SPACE_IPO);
@@ -827,19 +827,33 @@ static void rna_def_userdef_theme_space_outliner(BlenderRNA *brna)
rna_def_userdef_theme_spaces_main(srna, SPACE_OUTLINER);
}
static void rna_def_userdef_theme_space_userpref(BlenderRNA *brna)
{
StructRNA *srna;
/* space_userpref */
srna= RNA_def_struct(brna, "ThemeUserPreferences", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme User Preferences", "Theme settings for the User Preferences.");
rna_def_userdef_theme_spaces_main(srna, SPACE_USERPREF);
}
static void rna_def_userdef_theme_space_info(BlenderRNA *brna)
{
StructRNA *srna;
/* space_info */
srna= RNA_def_struct(brna, "ThemeUserPreferences", NULL);
srna= RNA_def_struct(brna, "ThemeInfo", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme User Preferences", "Theme settings for the User Preferences.");
RNA_def_struct_ui_text(srna, "Theme Info", "Theme settings for Info.");
rna_def_userdef_theme_spaces_main(srna, SPACE_INFO);
}
static void rna_def_userdef_theme_space_text(BlenderRNA *brna)
{
StructRNA *srna;
@@ -997,7 +1011,7 @@ static void rna_def_userdef_theme_space_buts(BlenderRNA *brna)
/* space_buts */
srna= RNA_def_struct(brna, "ThemeButtonsWindow", NULL);
srna= RNA_def_struct(brna, "ThemeProperties", NULL);
RNA_def_struct_sdna(srna, "ThemeSpace");
RNA_def_struct_ui_text(srna, "Theme Properties", "Theme settings for the Properties.");
@@ -1402,7 +1416,7 @@ static void rna_def_userdef_themes(BlenderRNA *brna)
prop= RNA_def_property(srna, "properties", PROP_POINTER, PROP_NEVER_NULL);
RNA_def_property_pointer_sdna(prop, NULL, "tbuts");
RNA_def_property_struct_type(prop, "ThemeButtonsWindow");
RNA_def_property_struct_type(prop, "ThemeProperties");
RNA_def_property_ui_text(prop, "Properties", "");
prop= RNA_def_property(srna, "text_editor", PROP_POINTER, PROP_NEVER_NULL);
@@ -1430,8 +1444,13 @@ static void rna_def_userdef_themes(BlenderRNA *brna)
RNA_def_property_struct_type(prop, "ThemeOutliner");
RNA_def_property_ui_text(prop, "Outliner", "");
prop= RNA_def_property(srna, "user_preferences", PROP_POINTER, PROP_NEVER_NULL);
prop= RNA_def_property(srna, "info", PROP_POINTER, PROP_NEVER_NULL);
RNA_def_property_pointer_sdna(prop, NULL, "tinfo");
RNA_def_property_struct_type(prop, "ThemeInfo");
RNA_def_property_ui_text(prop, "Info", "");
prop= RNA_def_property(srna, "user_preferences", PROP_POINTER, PROP_NEVER_NULL);
RNA_def_property_pointer_sdna(prop, NULL, "tuserpref");
RNA_def_property_struct_type(prop, "ThemeUserPreferences");
RNA_def_property_ui_text(prop, "User Preferences", "");
@@ -1460,6 +1479,7 @@ static void rna_def_userdef_dothemes(BlenderRNA *brna)
rna_def_userdef_theme_space_node(brna);
rna_def_userdef_theme_space_outliner(brna);
rna_def_userdef_theme_space_info(brna);
rna_def_userdef_theme_space_userpref(brna);
rna_def_userdef_theme_space_sound(brna);
rna_def_userdef_theme_space_logic(brna);
rna_def_userdef_theme_colorset(brna);

View File

@@ -446,14 +446,14 @@ void WM_window_open_temp(bContext *C, rcti *position, int type)
ED_area_newspace(C, sa, SPACE_IMAGE);
}
else {
ED_area_newspace(C, sa, SPACE_INFO);
ED_area_newspace(C, sa, SPACE_USERPREF);
}
ED_screen_set(C, win->screen);
if(sa->spacetype==SPACE_IMAGE)
GHOST_SetTitle(win->ghostwin, "Blender Render");
else if(ELEM(sa->spacetype, SPACE_OUTLINER, SPACE_INFO))
else if(ELEM(sa->spacetype, SPACE_OUTLINER, SPACE_USERPREF))
GHOST_SetTitle(win->ghostwin, "Blender User Preferences");
else if(sa->spacetype==SPACE_FILE)
GHOST_SetTitle(win->ghostwin, "Blender File View");