|
These two UI’s are the same, except the second has an additional “attachOppositeControl” to make the button’s left side line up with the scroll list. Why does this result in the window’s left side bloating out? What am I missing?
Thanks!

Here’s the code:
from pymel.all import * def windowTestA():
if Window.exists('explainMeA'):
deleteUI('explainMeA')
windowA = window('explainMeA', title = 'Explain Me A')
formA = formLayout(parent = windowA)
items = iconTextScrollList(parent = formA)
button_pressMe = button(label = 'Press Me')
formLayout(formA, edit = True, attachForm = [(items, 'top', 10), (items, 'right', 10), (items, 'bottom', 50)])
formLayout(formA, edit = True, attachControl = [(button_pressMe, 'top', 10, items)], attachOppositeControl = [(button_pressMe, 'right', 0, items)])
windowA.show() windowTestA()
from pymel.all import * def windowTestB():
if Window.exists('explainMeB'):
deleteUI('explainMeB')
windowA = window('explainMeB', title = 'Explain Me B')
formA = formLayout(parent = windowA)
items = iconTextScrollList(parent = formA)
button_pressMe = button(label = 'Press Me')
formLayout(formA, edit = True, attachForm = [(items, 'top', 10), (items, 'right', 10), (items, 'bottom', 50)])
formLayout(formA, edit = True, attachControl = [(button_pressMe, 'top', 10, items)], attachOppositeControl = [(button_pressMe, 'right', 0, items), (button_pressMe, 'left', 0, items)])
windowA.show() windowTestB()
|