1
$\begingroup$

I have a custom operator. Now I'm adjusting the operator's REDO panel:


Here is the default REDO's look - when draw() function is not manually declared

  • all values aligned to the right :

img1


But after I declare custom draw() - this happens

  • values are stretched to the full width :

enter image description here

___

My draw() looks this way:

def draw(self,context):
    layout = self.layout
    layout.prop(self, 'size')
    layout.prop(self, 'align')

The Question:

I want to achieve default REDO's look (values alligned to the right) while using custom draw()

How can I do that ?


$\endgroup$

1 Answer 1

1
$\begingroup$

Use Property Split

def draw(self,context):
    layout = self.layout
    layout.use_property_split = True
    layout.prop(self, 'size')
    layout.prop(self, 'align')

$\endgroup$
1
  • $\begingroup$ It works perfectly. HUGE thanks for the help ❤️ $\endgroup$
    – Yaroslav
    Commented Nov 1 at 19:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .