ULimenTextLabel
Overview
ULimenTextLabel is a custom widget that extends UWidget. It provides functionality to set and display a title and value with various customizable properties such as font, color, padding, and alignment. The widget uses Slate UI framework components (STextBlock) to render the title and value in a horizontal layout.
Properties
Type | Name | Access | Description |
|---|---|---|---|
| LabelTitle | EditAnywhere | The text displayed as the label title. |
| LabelTitleFont | EditAnywhere | The font information for the label title. |
| LabelTitlePadding | EditAnywhere | The padding around the label title. |
| LabelTitleTextColor | EditAnywhere | The color and opacity of the label title text. |
| LabelTitleVerticalAlignment | EditAnywhere | The vertical alignment of the label title. |
| LabelTitleHorizontalAlignment | EditAnywhere | The horizontal alignment of the label title. |
| LabelValue | EditAnywhere | The text displayed as the label value. |
| LabelValueFont | EditAnywhere | The font information for the label value. |
| LabelValuePadding | EditAnywhere | The padding around the label value. |
| LabelValueTextColor | EditAnywhere | The color and opacity of the label value text. |
| LabelValueVerticalAlignment | EditAnywhere | The vertical alignment of the label value. |
| LabelValueHorizontalAlignment | EditAnywhere | The horizontal alignment of the label value. |
Functions
Return Type | Signature | Description |
|---|---|---|
| SetLabelTitle(const FText& InTitle) | Sets the text displayed as the label title. |
| SetLabelTitleFont(const FSlateFontInfo& InTitleFont) | Sets the font information for the label title. |
| SetLabelTitlePadding(const FMargin& InPadding) | Sets the padding around the label title. |
| SetLabelTitleTextColor(const FSlateColor& InColor) | Sets the color and opacity of the label title text. |
| SetLabelValue(const FText& InValue) | Sets the text displayed as the label value. |
| SetLabelValueFont(const FSlateFontInfo& InValueFont) | Sets the font information for the label value. |
| SetLabelValuePadding(const FMargin& InPadding) | Sets the padding around the label value. |
| SetLabelValueTextColor(const FSlateColor& InColor) | Sets the color and opacity of the label value text. |
| ReleaseSlateResources(bool bReleaseChildren) | Releases Slate resources, optionally releasing children as well. |
| RebuildWidget() | Rebuilds the widget's Slate representation based on current properties. |
Usage & Implementation Notes
The widget uses
STextBlockto render text andSHorizontalBoxfor layout.Properties are exposed in the Unreal Editor for easy customization.
The
RebuildWidgetfunction dynamically creates and configures Slate widgets based on the current property values.The
ReleaseSlateResourcesfunction properly cleans up Slate resources when the widget is destroyed or reconfigured.