remove narrow ui feature
- re-arranged UI in a way that gave far too much vert scrolling. - was added all over for simple things like making text="", layout engine should handle this. - Ton and Brecht are ok with removing this now. Ton would like to work on the layout engine to make it better support these cases.
This commit is contained in:
@@ -19,8 +19,6 @@
|
||||
# <pep8 compliant>
|
||||
import bpy
|
||||
|
||||
narrowui = bpy.context.user_preferences.view.properties_width_check
|
||||
|
||||
|
||||
class RENDER_MT_presets(bpy.types.Menu):
|
||||
bl_label = "Render Presets"
|
||||
@@ -56,15 +54,13 @@ class RENDER_PT_render(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
split = layout.split()
|
||||
|
||||
col = split.column()
|
||||
col.operator("render.render", text="Image", icon='RENDER_STILL')
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.operator("render.render", text="Animation", icon='RENDER_ANIMATION').animation = True
|
||||
|
||||
layout.prop(rd, "display_mode", text="Display")
|
||||
@@ -85,7 +81,6 @@ class RENDER_PT_layers(RenderButtonsPanel, bpy.types.Panel):
|
||||
|
||||
scene = context.scene
|
||||
rd = scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
row = layout.row()
|
||||
row.template_list(rd, "layers", rd, "active_layer_index", rows=2)
|
||||
@@ -106,8 +101,8 @@ class RENDER_PT_layers(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.label(text="")
|
||||
col.prop(rl, "light_override", text="Light")
|
||||
col.prop(rl, "material_override", text="Material")
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
|
||||
col = split.column()
|
||||
col.prop(rl, "visible_layers", text="Layer")
|
||||
col.label(text="Mask Layers:")
|
||||
col.prop(rl, "zmask_layers", text="")
|
||||
@@ -150,8 +145,7 @@ class RENDER_PT_layers(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rl, "pass_object_index")
|
||||
col.prop(rl, "pass_color")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.label()
|
||||
col.prop(rl, "pass_diffuse")
|
||||
row = col.row()
|
||||
@@ -193,7 +187,6 @@ class RENDER_PT_shading(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
split = layout.split()
|
||||
|
||||
@@ -203,8 +196,7 @@ class RENDER_PT_shading(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "use_sss", text="Subsurface Scattering")
|
||||
col.prop(rd, "use_envmaps", text="Environment Map")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "use_raytracing", text="Ray Tracing")
|
||||
col.prop(rd, "color_management")
|
||||
col.prop(rd, "alpha_mode", text="Alpha")
|
||||
@@ -224,7 +216,6 @@ class RENDER_PT_performance(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
split = layout.split()
|
||||
|
||||
@@ -239,8 +230,7 @@ class RENDER_PT_performance(RenderButtonsPanel, bpy.types.Panel):
|
||||
sub.prop(rd, "parts_x", text="X")
|
||||
sub.prop(rd, "parts_y", text="Y")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.label(text="Memory:")
|
||||
sub = col.column()
|
||||
sub.enabled = not (rd.use_border or rd.full_sample)
|
||||
@@ -273,7 +263,6 @@ class RENDER_PT_post_processing(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
split = layout.split()
|
||||
|
||||
@@ -281,8 +270,7 @@ class RENDER_PT_post_processing(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "use_compositing")
|
||||
col.prop(rd, "use_sequencer")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "dither_intensity", text="Dither", slider=True)
|
||||
|
||||
layout.separator()
|
||||
@@ -297,10 +285,7 @@ class RENDER_PT_post_processing(RenderButtonsPanel, bpy.types.Panel):
|
||||
sub.prop(rd, "fields_still", text="Still")
|
||||
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
else:
|
||||
col.separator()
|
||||
col = split.column()
|
||||
col.prop(rd, "edge")
|
||||
sub = col.column()
|
||||
sub.active = rd.edge
|
||||
@@ -322,7 +307,6 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
|
||||
rd = context.scene.render
|
||||
file_format = rd.file_format
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
layout.prop(rd, "output_path", text="")
|
||||
|
||||
@@ -331,8 +315,7 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "file_format", text="")
|
||||
col.row().prop(rd, "color_mode", text="Color", expand=True)
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "use_file_extension")
|
||||
col.prop(rd, "use_overwrite")
|
||||
col.prop(rd, "use_placeholder")
|
||||
@@ -351,8 +334,7 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col = split.column()
|
||||
col.label(text="Codec:")
|
||||
col.prop(rd, "exr_codec", text="")
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
|
||||
elif file_format == 'OPEN_EXR':
|
||||
split = layout.split()
|
||||
@@ -361,14 +343,12 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.label(text="Codec:")
|
||||
col.prop(rd, "exr_codec", text="")
|
||||
|
||||
if wide_ui:
|
||||
subsplit = split.split()
|
||||
col = subsplit.column()
|
||||
subsplit = split.split()
|
||||
col = subsplit.column()
|
||||
col.prop(rd, "exr_half")
|
||||
col.prop(rd, "exr_zbuf")
|
||||
|
||||
if wide_ui:
|
||||
col = subsplit.column()
|
||||
col = subsplit.column()
|
||||
col.prop(rd, "exr_preview")
|
||||
|
||||
elif file_format == 'JPEG2000':
|
||||
@@ -377,8 +357,7 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.label(text="Depth:")
|
||||
col.row().prop(rd, "jpeg2k_depth", expand=True)
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "jpeg2k_preset", text="")
|
||||
col.prop(rd, "jpeg2k_ycc")
|
||||
|
||||
@@ -387,8 +366,7 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col = split.column()
|
||||
col.prop(rd, "cineon_log", text="Convert to Log")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column(align=True)
|
||||
col = split.column(align=True)
|
||||
col.active = rd.cineon_log
|
||||
col.prop(rd, "cineon_black", text="Black")
|
||||
col.prop(rd, "cineon_white", text="White")
|
||||
@@ -415,21 +393,22 @@ class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
|
||||
col = split.column()
|
||||
if rd.quicktime_audiocodec_type == 'LPCM':
|
||||
col.prop(rd, "quicktime_audio_bitdepth", text="")
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
|
||||
col = split.column()
|
||||
col.prop(rd, "quicktime_audio_samplerate", text="")
|
||||
|
||||
split = layout.split()
|
||||
col = split.column()
|
||||
if rd.quicktime_audiocodec_type == 'AAC':
|
||||
col.prop(rd, "quicktime_audio_bitrate")
|
||||
if wide_ui:
|
||||
subsplit = split.split()
|
||||
col = subsplit.column()
|
||||
|
||||
subsplit = split.split()
|
||||
col = subsplit.column()
|
||||
|
||||
if rd.quicktime_audiocodec_type == 'AAC':
|
||||
col.prop(rd, "quicktime_audio_codec_isvbr")
|
||||
if wide_ui:
|
||||
col = subsplit.column()
|
||||
|
||||
col = subsplit.column()
|
||||
col.prop(rd, "quicktime_audio_resampling_hq")
|
||||
|
||||
|
||||
@@ -447,7 +426,6 @@ class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
layout.menu("RENDER_MT_ffmpeg_presets", text="Presets")
|
||||
|
||||
@@ -456,19 +434,17 @@ class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
|
||||
col = split.column()
|
||||
col.prop(rd, "ffmpeg_format")
|
||||
if rd.ffmpeg_format in ('AVI', 'QUICKTIME', 'MKV', 'OGG'):
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "ffmpeg_codec")
|
||||
else:
|
||||
if wide_ui:
|
||||
split.label()
|
||||
split.label()
|
||||
|
||||
split = layout.split()
|
||||
|
||||
col = split.column()
|
||||
col.prop(rd, "ffmpeg_video_bitrate")
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
|
||||
col = split.column()
|
||||
col.prop(rd, "ffmpeg_gopsize")
|
||||
|
||||
split = layout.split()
|
||||
@@ -479,8 +455,7 @@ class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "ffmpeg_maxrate", text="Maximum")
|
||||
col.prop(rd, "ffmpeg_buffersize", text="Buffer")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
|
||||
col.prop(rd, "ffmpeg_autosplit")
|
||||
col.label(text="Mux:")
|
||||
@@ -501,8 +476,7 @@ class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "ffmpeg_audio_bitrate")
|
||||
col.prop(rd, "ffmpeg_audio_mixrate")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "ffmpeg_audio_volume", slider=True)
|
||||
|
||||
|
||||
@@ -524,7 +498,6 @@ class RENDER_PT_antialiasing(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
layout.active = rd.render_antialiasing
|
||||
|
||||
split = layout.split()
|
||||
@@ -535,8 +508,7 @@ class RENDER_PT_antialiasing(RenderButtonsPanel, bpy.types.Panel):
|
||||
sub.enabled = not rd.use_border
|
||||
sub.prop(rd, "full_sample")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "pixel_filter", text="")
|
||||
col.prop(rd, "filter_size", text="Size")
|
||||
|
||||
@@ -580,7 +552,6 @@ class RENDER_PT_dimensions(RenderButtonsPanel, bpy.types.Panel):
|
||||
|
||||
scene = context.scene
|
||||
rd = scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
row = layout.row(align=True)
|
||||
row.menu("RENDER_MT_presets", text=bpy.types.RENDER_MT_presets.bl_label)
|
||||
@@ -605,8 +576,7 @@ class RENDER_PT_dimensions(RenderButtonsPanel, bpy.types.Panel):
|
||||
sub.active = rd.use_border
|
||||
sub.prop(rd, "crop_to_border", text="Crop")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
sub = col.column(align=True)
|
||||
sub.label(text="Frame Range:")
|
||||
sub.prop(scene, "frame_start", text="Start")
|
||||
@@ -637,7 +607,6 @@ class RENDER_PT_stamp(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
layout.active = rd.render_stamp
|
||||
|
||||
@@ -654,8 +623,7 @@ class RENDER_PT_stamp(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "stamp_marker", text="Marker")
|
||||
col.prop(rd, "stamp_sequencer_strip", text="Seq. Strip")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.active = rd.render_stamp
|
||||
col.prop(rd, "stamp_foreground", slider=True)
|
||||
col.prop(rd, "stamp_background", slider=True)
|
||||
@@ -683,20 +651,13 @@ class RENDER_PT_bake(RenderButtonsPanel, bpy.types.Panel):
|
||||
layout = self.layout
|
||||
|
||||
rd = context.scene.render
|
||||
wide_ui = context.region.width > narrowui
|
||||
|
||||
layout.operator("object.bake_image", icon='RENDER_STILL')
|
||||
|
||||
if wide_ui:
|
||||
layout.prop(rd, "bake_type")
|
||||
else:
|
||||
layout.prop(rd, "bake_type", text="")
|
||||
layout.prop(rd, "bake_type")
|
||||
|
||||
if rd.bake_type == 'NORMALS':
|
||||
if wide_ui:
|
||||
layout.prop(rd, "bake_normal_space")
|
||||
else:
|
||||
layout.prop(rd, "bake_normal_space", text="")
|
||||
layout.prop(rd, "bake_normal_space")
|
||||
elif rd.bake_type in ('DISPLACEMENT', 'AO'):
|
||||
layout.prop(rd, "bake_normalized")
|
||||
|
||||
@@ -712,8 +673,7 @@ class RENDER_PT_bake(RenderButtonsPanel, bpy.types.Panel):
|
||||
col.prop(rd, "bake_margin")
|
||||
col.prop(rd, "bake_quad_split", text="Split")
|
||||
|
||||
if wide_ui:
|
||||
col = split.column()
|
||||
col = split.column()
|
||||
col.prop(rd, "bake_active")
|
||||
sub = col.column()
|
||||
sub.active = rd.bake_active
|
||||
|
||||
Reference in New Issue
Block a user