From f4f3a9b08b04077e6e9272e4fdd4cd550b47be02 Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Tue, 28 Jul 2009 11:04:08 +0000 Subject: 2.5 Lamp Buttons: * Some layout tweaks and fixes by nudelZ. --- release/ui/buttons_data_lamp.py | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) (limited to 'release/ui/buttons_data_lamp.py') diff --git a/release/ui/buttons_data_lamp.py b/release/ui/buttons_data_lamp.py index abe78aca28f..4a61684c8e2 100644 --- a/release/ui/buttons_data_lamp.py +++ b/release/ui/buttons_data_lamp.py @@ -49,10 +49,13 @@ class DATA_PT_lamp(DataButtonsPanel): split = layout.split() col = split.column() - col.itemR(lamp, "color", text="") - col.itemR(lamp, "energy") + sub = col.column(align=True) + sub.itemR(lamp, "color", text="") + sub.itemR(lamp, "energy") col.itemR(lamp, "negative") - col.itemR(lamp, "distance") + + if lamp.type == "AREA": + col.itemR(lamp, "distance") col = split.column() col.itemR(lamp, "layer", text="This Layer Only") @@ -67,7 +70,7 @@ class DATA_PT_lamp(DataButtonsPanel): sub = col.column(align=True) sub.itemR(lamp, "falloff_type", text="") sub.itemR(lamp, "distance") - sub.itemR(lamp, "sphere") + col.itemR(lamp, "sphere") if lamp.falloff_type == 'LINEAR_QUADRATIC_WEIGHTED': col = split.column() @@ -201,20 +204,18 @@ class DATA_PT_shadow(DataButtonsPanel): elif lamp.type == 'AREA': split = layout.split() - col = split.column(align=True) + col = split.column() + sub = split.column(align=True) if lamp.shape == 'SQUARE': - col.itemR(lamp, "shadow_ray_samples_x", text="Samples") + sub.itemR(lamp, "shadow_ray_samples_x", text="Samples") elif lamp.shape == 'RECTANGLE': - col.itemR(lamp, "shadow_ray_samples_x", text="Samples X") - col.itemR(lamp, "shadow_ray_samples_y", text="Samples Y") + sub.itemR(lamp, "shadow_ray_samples_x", text="Samples X") + sub.itemR(lamp, "shadow_ray_samples_y", text="Samples Y") if lamp.shadow_ray_sampling_method == 'ADAPTIVE_QMC': - col.itemR(lamp, "shadow_adaptive_threshold", text="Threshold") - split.column() - elif lamp.shadow_ray_sampling_method == 'CONSTANT_QMC': - split.column() + sub.itemR(lamp, "shadow_adaptive_threshold", text="Threshold") + elif lamp.shadow_ray_sampling_method == 'CONSTANT_JITTERED': - col = split.column() col.itemR(lamp, "umbra") col.itemR(lamp, "dither") col.itemR(lamp, "jitter") -- cgit v1.2.3