Images as Planes: Improve option panels #104936

Closed
Sun Kim wants to merge 9 commits from persun/blender-addons:iap_options_ui into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
Showing only changes of commit f80c9587c3 - Show all commits

View File

@ -812,7 +812,10 @@ class IMPORT_IMAGE_OT_to_plane(Operator, AddObjectHelper):
box = layout.box()
box.label(text="Compositing Nodes:", icon='RENDERLAYERS')
box.prop(self, "compositing_nodes")
row = box.row(align=True)
row.use_property_split = False
row.prop(self, "compositing_nodes")
layout = self.layout
box = layout.box()
box.label(text="Material Settings:", icon='MATERIAL')
@ -860,15 +863,7 @@ class IMPORT_IMAGE_OT_to_plane(Operator, AddObjectHelper):
box = layout.box()
box.label(text="Transform:", icon='SNAP_GRID')
box.prop(self, "offset")
col = box.column()
row = col.row()
row.prop(self, "offset_axis", expand=False)
row = col.row()
row.prop(self, "offset_amount")
col.enabled = self.offset
box.label(text="Plane dimensions:")
row = box.row()
row.prop(self, "size_mode", expand=False)
if self.size_mode == 'ABSOLUTE':
@ -879,14 +874,21 @@ class IMPORT_IMAGE_OT_to_plane(Operator, AddObjectHelper):
else:
box.prop(self, "factor")
box.label(text="Orientation:")
row = box.row()
row.enabled = 'CAM' not in self.size_mode
row.prop(self, "align_axis")
if 'CAM' in self.align_axis:
row = box.row()
row.prop(self, "align_track")
row = box.row()
row.enabled = 'CAM' in self.align_axis
row = box.row()
row.prop(self, "align_track")
row.prop(self, "offset")
col = box.column()
row = col.row()
row.prop(self, "offset_axis", expand=False)
row = col.row()
row.prop(self, "offset_amount")
col.enabled = self.offset
def draw(self, context):