|
YCP UI Widget Reference
Back to the widget index
Description
This widget draws a frame around its child and displays a title label within
the top left edge of that frame. It is used to visually group widgets
together. It is very common to use a frame like this around radio button
groups.
See the Layout HOWTO for details.
Arguments
string
|
label
|
title to be displayed on the top left edge
|
term
|
child
|
the contained child widget
|
Special Properties
string
|
Value
|
the label text
|
Sample Usage
`Frame( `RadioButtonGroup( `id( rb ), `VBox( ... ) ) );
Examples
{
UI::OpenDialog(
`VBox(
`Frame ( "Important",
`Label("Hello, World!")
),
`PushButton("&OK")
)
);
UI::UserInput();
UI::CloseDialog();
}
|
{
UI::OpenDialog( `VBox(
`Frame ( "CPU &Speed",
`RadioButtonGroup(
`VBox(
`Left(`RadioButton("Normal" )),
`Left(`RadioButton("Overclocked" )),
`Left(`RadioButton("Red Hot" )),
`Left(`RadioButton("Melting", true ))
)
)
),
`PushButton("&OK")
)
);
UI::UserInput();
UI::CloseDialog();
}
|
{
UI::OpenDialog(
`VBox(
`Frame("Shrinkable Textentries",
`HBox(
`TextEntry(`opt(`shrinkable), "1"),
`TextEntry(`opt(`shrinkable), "2"),
`TextEntry(`opt(`shrinkable), "3"),
`TextEntry(`opt(`shrinkable), "4")
)
),
`PushButton(`opt(`default), "&OK" )
)
);
UI::UserInput();
UI::CloseDialog();
}
|
Back to the widget index
|