RectTransform
Inherited: None
Description
The ProgressBar class is designed to provide a graphical representation of progress with customizable appearance and range. It supports features such as setting the minimum and maximum values, adjusting the progress value, and specifying visual elements for background and progress indicator.
Public Methods
border () const |
|
hoveredTransform (float x, float y) |
|
bool |
isHovered (float x, float y) const |
Layout * |
layout () const |
margin () const |
|
maxAnchors () const |
|
minAnchors () const |
|
bool |
mouseTracking () const |
padding () const |
|
pivot () const |
|
void |
setAnchors (const Vector2 minimum, const Vector2 maximum) |
void |
setBorder (const Vector4 border) |
void |
setEnabled (bool enabled) |
void |
setLayout (Layout * layout) |
void |
setMargin (const Vector4 margin) |
void |
setMaxAnchors (const Vector2 anchors) |
void |
setMinAnchors (const Vector2 anchors) |
void |
setMouseTracking (bool tracking) |
void |
setPadding (const Vector4 padding) |
void |
setPivot (const Vector2 pivot) |
void |
setSize (const Vector2 size) |
size () const |
|
void |
subscribe (Widget * widget) |
void |
unsubscribe (Widget * widget) |
Static Methods
None
Methods Description
Vector4 RectTransform::border () const
Returns the border width of the RectTransform. The Vector4 contains border widths in top, right, bottom and left order.
See also setBorder().
RectTransform * RectTransform::hoveredTransform (float x, float y)
Returns the most top RectTransform in hierarchy wich contains the point with coodinates x and y. Returns null if no bounds.
bool RectTransform::isHovered (float x, float y) const
Returns true if the point with coordinates x and y is within the bounds, otherwise false.
Layout * RectTransform::layout () const
Returns the layout assigned to the RectTransform.
See also setLayout().
Vector4 RectTransform::margin () const
Returns the margin offsets of the RectTransform. The Vector4 contains offsets in top, right, bottom and left order.
See also setMargin().
Vector2 RectTransform::maxAnchors () const
Returns the maximum anchors of the RectTransform.
See also setMaxAnchors().
Vector2 RectTransform::minAnchors () const
Returns the minimum anchors of the RectTransform.
See also setMinAnchors().
bool RectTransform::mouseTracking () const
Returns true if this area is interactable with mouse; otherwise returns false. Returns true by the default.
See also setMouseTracking().
Vector4 RectTransform::padding () const
Returns the padding offset of the RectTransform. The Vector4 contains padding offsets in top, right, bottom and left order.
See also setPadding().
Vector2 RectTransform::pivot () const
Returns the pivot point of the RectTransform.
See also setPivot().
Sets both the minimum and maximum anchors of the RectTransform.
void RectTransform::setBorder (Vector4 border)
Sets the top, right, bottom and left border width of the RectTransform.
See also *border*().
void RectTransform::setEnabled (bool enabled)
Reimplements: Component::setEnabled(bool enabled).
Sets current state of RectTransform to enabled or disabled.
void RectTransform::setLayout (Layout * layout)
Sets the layout for the RectTransform.
See also *layout*().
void RectTransform::setMargin (Vector4 margin)
Sets the top, right, bottom and left margin offsets of the RectTransform.
See also *margin*().
void RectTransform::setMaxAnchors (Vector2 anchors)
Sets the maximum anchors of the RectTransform.
See also maxAnchors().
void RectTransform::setMinAnchors (Vector2 anchors)
Sets the minimum anchors of the RectTransform.
See also minAnchors().
void RectTransform::setMouseTracking (bool tracking)
Sets mouse tracking enabled or disabled.
See also mouseTracking().
void RectTransform::setPadding (Vector4 padding)
Sets the top, right, bottom and left padding offsets of the RectTransform.
See also *padding*().
void RectTransform::setPivot (Vector2 pivot)
Sets the pivot point of the RectTransform.
See also *pivot*().
void RectTransform::setSize (Vector2 size)
Sets the size of the RectTransform.
See also *size*().
Vector2 RectTransform::size () const
Returns the size of the associated UI element.
See also setSize().
void RectTransform::subscribe (Widget * widget)
Subscribes a widget to changes in the RectTransform.
void RectTransform::unsubscribe (Widget * widget)
Unsubscribes a widget from changes in the RectTransform.