dialog AddGroupBox

I’m building a dialog, and would love to have wee groups around each iteration of this.

This is inside a loop, it’s so each iteration of the loop are layed out like tiles.

So I basically want to create a row, then 5 groups of controls, then add a new row etc.
This is working fine at adding rows, but not with the groups (you can see below where I think they should be placed) but they are outside of the rows and ignored?
So it displays like
group
group
group
row with looped stuff (not in a group)

so whats the proper usage? Groups cannot be on rows? Rows should be inside groups instead? If so how do I group stuff on a row to break it up…

[code] if oColumn == 0:
scriptDialog.AddRow()
scriptDialog.AddControl( “DummyLabel1”, “LabelControl”, “”, 200, 5 )
scriptDialog.EndRow()
scriptDialog.AddRow()

	#scriptDialog.AddGroupBox(oShot+"Group", oShot, False)
	scriptDialog.AddSelectionControl( oShot+"CHK", "CheckBoxControl", 0, oShot , 100, 10 )
	scriptDialog.AddComboControl( oShot+"EXT", "ComboControl", "jpg", ("jpg","dpx"), 45, 20 )
	scriptDialog.AddControl( "Label", "LabelControl", "   Handles", 50, -1 )
	scriptDialog.AddControl( oShot+"HandleStart", "TextControl", "10", 20, -1 )
	scriptDialog.AddControl( oShot+"HandleEnd", "TextControl", "10", 20, -1 )
	#scriptDialog.EndGroupBox(False)
	

	if oColumn == oRowMax-1:
		scriptDialog.EndRow()[/code]

Rows should be placed in groups, so that would explain why this isn’t working for you.

Maybe you could do a mockup in paint or something that shows how you’re trying to set things up in your UI?

Cheers,

  • Ryan

Well that is a good idea.

Attached, I have made a couple of boxes around each ‘shot’ so you get the idea, otherwise the thing is a bit hard to read!

Thanks for the screen shot. That definitely helps us know what you’re looking for. Unfortunately, this currently isn’t possible with the helper functions that are available for the script dialog.

However, the ScriptDialog class that you are working with is just a QDialog:
doc-snapshot.qt-project.org/4.8/qdialog.html

Instead of using our ScriptDialog class, you could just create your own QDialog and build it up any way you want.

Cheers,

  • Ryan

Ok thanks Ryan, I’ll look into it if, see if its worth the time :slight_smile: