25 #ifndef YWidgetFactory_h
26 #define YWidgetFactory_h
31 #include "YItemCustomStatus.h"
86 YDialog * createMainDialog ( YDialogColorMode colorMode = YDialogNormalColor );
87 YDialog * createPopupDialog ( YDialogColorMode colorMode = YDialogNormalColor );
88 virtual YDialog * createDialog (
YDialogType dialogType, YDialogColorMode colorMode = YDialogNormalColor ) = 0;
96 virtual YLayoutBox * createLayoutBox (
YWidget * parent, YUIDimension dimension ) = 0;
103 virtual YPushButton * createPushButton (
YWidget * parent,
const std::string & label ) = 0;
104 virtual YLabel * createLabel (
YWidget * parent,
const std::string & text,
bool isHeading =
false,
bool isOutputField =
false ) = 0;
105 YLabel * createHeading (
YWidget * parent,
const std::string & label );
106 virtual YInputField * createInputField (
YWidget * parent,
const std::string & label,
bool passwordMode =
false ) = 0;
107 virtual YCheckBox * createCheckBox (
YWidget * parent,
const std::string & label,
bool isChecked =
false ) = 0;
108 virtual YRadioButton * createRadioButton (
YWidget * parent,
const std::string & label,
bool isChecked =
false ) = 0;
109 virtual YComboBox * createComboBox (
YWidget * parent,
const std::string & label,
bool editable =
false ) = 0;
111 virtual YTree * createTree (
YWidget * parent,
const std::string & label,
bool multiselection =
false,
bool recursiveselection =
false ) = 0;
113 virtual YProgressBar * createProgressBar (
YWidget * parent,
const std::string & label,
int maxValue = 100 ) = 0;
114 virtual YRichText * createRichText (
YWidget * parent,
const std::string & text = std::string(),
bool plainTextMode =
false ) = 0;
115 virtual YBusyIndicator * createBusyIndicator (
YWidget * parent,
const std::string & label,
int timeout = 1000 ) = 0;
121 YPushButton * createIconButton (
YWidget * parent,
const std::string & iconName,
const std::string & fallbackTextLabel );
122 YLabel * createOutputField (
YWidget * parent,
const std::string & label );
123 virtual YIntField * createIntField (
YWidget * parent,
const std::string & label,
int minVal,
int maxVal,
int initialVal ) = 0;
126 virtual YMenuButton * createMenuButton (
YWidget * parent,
const std::string & label ) = 0;
128 virtual YImage * createImage (
YWidget * parent,
const std::string & imageFileName,
bool animated =
false ) = 0;
129 virtual YLogView * createLogView (
YWidget * parent,
const std::string & label,
int visibleLines,
int storedLines = 0 ) = 0;
133 virtual YWidget * createPkgSpecial (
YWidget * parent,
const std::string & subwidgetName ) = 0;
141 YSpacing * createHSpacing (
YWidget * parent, YLayoutSize_t size = 1.0 );
142 YSpacing * createVSpacing (
YWidget * parent, YLayoutSize_t size = 1.0 );
143 virtual YSpacing * createSpacing (
YWidget * parent, YUIDimension dim,
bool stretchable =
false, YLayoutSize_t size = 0.0 ) = 0;
154 YAlignment * createMarginBox (
YWidget * parent, YLayoutSize_t horMargin, YLayoutSize_t vertMargin );
156 YLayoutSize_t leftMargin, YLayoutSize_t rightMargin,
157 YLayoutSize_t topMargin, YLayoutSize_t bottomMargin );
161 YAlignment * createMinSize (
YWidget * parent, YLayoutSize_t minWidth, YLayoutSize_t minHeight );
163 virtual YAlignment * createAlignment (
YWidget * parent, YAlignmentType horAlignment, YAlignmentType vertAlignment ) = 0;
168 virtual YSquash * createSquash (
YWidget * parent,
bool horSquash,
bool vertSquash ) = 0;
174 virtual YFrame * createFrame (
YWidget * parent,
const std::string & label ) = 0;
175 virtual YCheckBoxFrame * createCheckBoxFrame (
YWidget * parent,
const std::string & label,
bool checked ) = 0;
188 virtual YItemSelector * createItemSelector (
YWidget * parent,
bool enforceSingleSelection =
true );
191 virtual YItemSelector * createCustomStatusItemSelector (
YWidget * parent,
const YItemCustomStatusVector & customStates );
Author: Stefan Hundhammer sh@suse.de
YDialogType
Type of dialog: Main / Popup / Wizard.
Implementation of all the alignment widgets:
Indicates that something is in progress and has not frozen yet.
A frame with a check-box, may auto-disable frame contents based on the check.
ComboBox (or "drop down box", "drop down selection"); may be editable.
A window in the desktop environment.
A widget with zero size, useful as a placeholder.
A labeled framed container.
A picture, possibly animated, loaded from a file.
IntField: Input field for integer values.
Scrollable item selector widget with not only a label for each item, but also a (possible multi-line)...
Implementation of the Label, Heading and OutputField widgets.
A vertical or horizontal stacking of widgets, implementing HBox and VBox.
LogView: A scrollable (output-only) text to display a growing log, very much like the "tail -f" shell...
A multi-line plain-text area.
A variant of YSelectionBox where more than one item can be selected.
A simple wrapper for an insanely complex UI for installing software.
A progress bar, showing completion of value() out of maxValue() parts.
A placeholder that can have its contents exchanged, using ReplaceWidget.
Text formatted with simple HTML-like tags, with "links" generating events.
Selection box: List box that displays a (scrollable) list of items from which the user can select exa...
HSpacing, VSpacing, HStretch, VStretch.
HSquash, VSquash HVSquash: reduce child to its preferred size.
Table: Selection list with multiple columns.
Input field for entering a time in "hh:mm:ss" format.
Tree: List box that displays a (scrollable) list of hierarchical items from which the user can select...