groupbox object class Provides a groupbox bar. |
||||||||||||||||||||||||||||
Inherits |
||||||||||||||||||||||||||||
object widget | ||||||||||||||||||||||||||||
Description |
||||||||||||||||||||||||||||
This widget can be used to display a groupbox. It will be usually a parent for other child controls. You can either use a child layout to manage the child geometries or use $setColumnLayout to manage the layout automatically. | ||||||||||||||||||||||||||||
Functions |
||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||
Examples |
||||||||||||||||||||||||||||
# First we'll create the main widget. as a dialog %widget=$new(dialog) %layout=$new(layout,%widget) # Then the groupbox %gb=$new(groupbox,%widget) %gb->$setTitle(Login) %gb->$setAlignment("Left") # Add the groupbox to the main layout %layout->$addWidget(%gb,0,0) # Now we create the user field # (labels + lineedit) in a horizontal box %hbox=$new(hbox,%gb) %labeluser=$new(label,%hbox) %labeluser->$settext(User: ) %inputuser=$new(lineedit,%hbox) # Now we create the password field # (labels + lineedit) in a horizontal box %hbox=$new(hbox,%gb) %labelpass=$new(label,%hbox) %labelpass->$settext(Pass: ) %inputpass=$new(lineedit,%hbox) %inputpass->$setechomode("password") # Now we create the OK/Cancel box buttons %hbox=$new(hbox,%gb) %btnok=$new(button,%hbox) %btnok->$settext("OK") %btncancel=$new(button,%hbox) %btncancel->$settext("Cancel") # Let's show our nice form %widget->$show() | ||||||||||||||||||||||||||||