[PyQt] how to move spliter/horiz layout up/down in a vert layout?

Is there an easy way to move splitters/ horizontal layouts up and down within a vertical widget? The only examples I’ve found use a tablelayout.

Here I have:
[ul]
[li]a top level gridlayout [/li][li]a scroll layout[/li][li]a tab layout[/li][li]a vert layout within the tab[/li][li]three dynamically created horizontal splitters[/li][/ul]

I want to give the user the ability to change the order of the splitters. I build the light list dynamically if there is lights in the scene. This will add them in order. I thought I could substitute lightTransforms for another list that moved the items but Im hoping there is a better way.


	[B]def buildLightList(self):[/B]
		lightShapes = cmds.ls(lights=True)
		
		if lightShapes:
			lightTransforms = cmds.listRelatives(lightShapes, p=True)

			for i in lightTransforms:
			

you should be able to wrap the rows in a QWidget and then add those widgets to a vertical splitter within the tab layout. I just tried a simple test int eh designer and did as expected.

If you could elaborate on your results some more, please. What I have is

[ul]
[li]light 1[/li][li]light 2[/li][li]light 3[/li][li]light 4[/li][li]light 5[/li][/ul]

and I want to make it be something like this…I tried what I think your getting at and the only movement i get is with collapsable rows (which i turn off)

[ul]
[li]light 5[/li][li]light 1[/li][li]light 4[/li][li]light 3[/li][li]light 2[/li][/ul]

oh i see what you mean, you want to be able to sort the rows by light name (for example)? Did you want to have them drag them about? If thats the case then a vertical layout would work, you’d just have to reimplement the drag/drop events. You could probably do something with a QTreeView or like you mentioned before a QListView. Also, I would wrap the model in a QSortFilterProxyModel and then they could sort and filter light rows as they needed or the scene changed.

http://srinikom.github.com/pyside-docs/PySide/QtGui/QTreeView.html
http://srinikom.github.com/pyside-docs/PySide/QtGui/QListView.html
http://srinikom.github.com/pyside-docs/PySide/QtGui/QSortFilterProxyModel.html

If you havent worked with qt qt model/view stuff, yasin did a good video set explaining them: [PyQT] Model View Video Tutorial Series (Part 01) - Coding - Tech-Artists.Org