Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
so it seems rowLayout is slightly broken in Maya 2024. "Adjustable" columns no longer auto-adjust when paired with the raw cw= flag (as opposed to the more "convenient" cw3= alternative).
Here's some example code. it should display a window with TWO "identical" rowLayouts. This works fine in all versions of Maya from 2017-2023, but not in 2024, as the second row doesn't auto-scale the field like it's supposed to.
window = cmds.window()
cmds.columnLayout(adj=True)
cmds.rowLayout(nc=3, cw3=(50, 1, 50), adj=2)
cmds.text(l='Filter')
cmds.textField() # this should auto-adjust (column:2)
cmds.button(l='OK')
cmds.setParent('..')
cmds.rowLayout(nc=3, cw=((1, 50), (2, 1), (3, 50)), adj=2)
cmds.text(l='Filter')
cmds.textField() # this should auto-adjust (column:2)
cmds.button(l='OK')
cmds.setParent('..')
cmds.setParent('..')
cmds.showWindow(window)
it's still working fine using "cw3", but this is not a viable workaround for me as one of my UIs has 7 or 8 elelments in the rowLayout.
Solved! Go to Solution.