|
void | setFrameRelief (Relief value) |
| setFrameRelief More...
|
|
virtual const char * | getType () const |
| getType is always implemented by derived to return the same static pointer per widget. More...
|
|
int | getSpacing () const |
| returns pixel spacing between items
|
|
void | setSpacing (int value) |
| sets pixel spacing between items
|
|
int | getPadding () const |
| getPadding get number of pixels to pad from Layout rect during layout More...
|
|
void | setPadding (int value) |
| setPadding set number of pixels to pad from Layout rect during layout More...
|
|
virtual void | addWidget (const std::shared_ptr< Widget > &widget) |
| adds the widget to this Layout after removing it from it's previous layout
|
|
virtual std::shared_ptr< Widget > | rmvWidget (const std::shared_ptr< Widget > &widget) |
| rmvWidget More...
|
|
void | rmvWidget (int i) |
| remove a widget at index 'i' (silently ignores 'i' too big)
|
|
template<typename T = Widget> |
T * | at (int index) |
| return a widget at index 'i' (or 0 if type is wrong ot 'i' is too big)
|
|
size_t | size () const |
| returns the number of widgets in the layout
|
|
bool | getWrap () const |
| get if the layout will wrap widgets past forcedWidth / forcedHeight
|
|
void | setWrap (bool value) |
| set if the layout will wrap widgets past forcedWidth / forcedHeight
|
|
int | getMaxWidgetWidth () |
| get the maximum width from all contained widgets
|
|
int | getMaxWidgetHeight () |
| get the maximum height from all contained widgets
|
|
virtual void | setOutlineColor (const cv::Scalar &value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual void | setFillColor (const cv::Scalar &value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual void | setSelectColor (const cv::Scalar &value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual void | setThickness (int value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual void | setLineType (int value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual void | setVisible (bool value) |
| delegate to internal Widget parts added by derived classes
|
|
virtual const std::string & | getStatusMsg () const |
| delegate to active widget or to our derived class if none active
|
|
virtual void | translate (const cv::Point &translation) |
| delegate to internal Widget parts added by derived classes
|
|
void | doForAll (CBWidget cb, int recurseLevel, bool doOnSelf) |
| doForAll More...
|
|
virtual const cv::Rect & | getRect () |
| Actual size the widget is occupying due to Layout manager.
|
|
| Widget (const cv::Point &pos=cv::Point(0, 0)) |
| constructor
|
|
virtual | ~Widget () |
| virtual destructor
|
|
void | notifyOnChange (CBWidgetState cb) |
| used to register for notifications on a widget More...
|
|
cv::Scalar | getOutlineColor () const |
| get the outline color
|
|
cv::Scalar | getFillColor () const |
| get the bg color
|
|
bool | getVisible () const |
| is the widget visible
|
|
int | getThickness () const |
| get line thickness to use when drawing
|
|
int | getLineType () const |
| get the line type (LINE_4, LINE_8, LINE_AA)
|
|
uchar | getAlpha () const |
| get the alpha value used for the widge background [0,255] => [transparent,opaque]
|
|
void | setAlpha (uchar value) |
| set the alpha value used for the widge background [0,255] => [transparent,opaque]
|
|
Anchor | getLayoutAnchor () const |
| getLayoutAnchor returns the anchor for using in the Layout we're in More...
|
|
void | setLayoutAnchor (const Anchor &value) |
| setLayoutAnchor sets the anchor for using in the Layout we're in More...
|
|
Anchor | getFlowAnchor () const |
| getFlowAnchor get internal widget alignment and direction of growth More...
|
|
void | setFlowAnchor (const Anchor &value) |
| setFlowAnchor set internal widget alignment and direction of growth More...
|
|
int | getId () |
| Widgets have a unique id per instance.
|
|
void | setStatusMsg (const std::string &value) |
| setStatusMsg More...
|
|
const cv::Point & | getLocation () const |
| get widget position in Canvas
|
|
virtual void | setLocation (const cv::Point &value) |
| set widget position in Canvas
|
|
bool | getStretchX () const |
| get if the Layout we're in should stretch us in the X direction
|
|
void | setStretchX (bool value) |
| set if the Layout we're in should stretch us in the X direction (and calls setStretchXToParent(false))
|
|
bool | getStretchY () const |
| get if the Layout we're in should stretch us in the Y direction
|
|
void | setStretchY (bool value) |
| set if the Layout we're in should stretch us in the Y direction (and calls setStretchYToParent(false))
|
|
cv::Scalar | getSelectColor () const |
| get the color to use when a widget is selected
|
|
std::shared_ptr< Widget > | rmvFromLayout () |
| get rid of the widget
|
|
bool | getIsSelectable () const |
| get if the widget should appear as selected when the mouse is over it
|
|
void | setIsSelectable (bool value) |
| set if the widget should appear as selected when the mouse is over it
|
|
int | getForcedWidth () const |
| get the forced width for this widget
|
|
void | setForcedWidth (int value) |
| set the forced width for this widget (and calls setStretchX/setStretchXToParent(false))
|
|
int | getForcedHeight () const |
| get the forced height for this widget
|
|
void | setForcedHeight (int value) |
| set the forced height for this widget (and calls setStretchY/setStretchYToParent(false))
|
|
void | update () |
| removes 'dirty' state and invokes the derived 'recalc/recalcCompound'
|
|
bool | isRemoved () const |
| returns true if the widget has no layout and false if it does
|
|
bool | getStretchXToParent () const |
| get if this widget streches to parent layout width
|
|
void | setStretchXToParent (bool value) |
| set if this widget streches to parent layout width (and calls setStretchX(false))
|
|
bool | getStretchYToParent () const |
| get if this widget streches to parent layout height
|
|
void | setStretchYToParent (bool value) |
| set if this widget streches to parent layout height (and calls setStretchY(false))
|
|
A frame with a background of a selected relief type. This is also a Layout for other Widgets and it lays them vertically.
- See also
- VerticalLayout
- Examples:
- example_add_widget.cpp.