Navigation
Unreal Engine C++ API Reference > Runtime > SlateCore > Styling
References
Module | SlateCore |
Header | /Engine/Source/Runtime/SlateCore/Public/Styling/SlateColor.h |
Include | #include "Styling/SlateColor.h" |
Syntax
struct FSlateColor
Remarks
A Slate color can be a directly specified value, or the color can be pulled from a WidgetStyle.
Variables
Type | Name | Description | |
---|---|---|---|
![]() |
ESlateColorStylingMode | ColorUseRule | The rule for which color to pick. |
![]() |
FLinearColor | SpecifiedColor | The current specified color; only meaningful when ColorToUse == UseColor_Specified. |
Constructors
Type | Name | Description | |
---|---|---|---|
![]() |
FSlateColor () |
Default constructor.Uninitialized Slate colors are Fuchsia by default. | |
![]() |
FSlateColor
(
const FLinearColor& InColor |
Creates a new Slate color with the specified values. | |
![]() |
FSlateColor
(
const FColor InColor |
Creates a new Slate color with the specified values. | |
![]() |
FSlateColor
(
const TSharedRef< FLinearColor >& InColor |
Creates a new Slate color that is linked to the given values. | |
![]() |
FSlateColor
(
EStyleColor InColorTableId |
||
![]() |
FSlateColor
(
ESlateColorStylingMode InColorUseRule |
Private constructor to prevent construction of invalid FSlateColors. |
Destructors
Type | Name | Description | |
---|---|---|---|
![]() |
~FSlateColor () |
Functions
Type | Name | Description | |
---|---|---|---|
![]() ![]() |
const FLinearColor & | GetColor
(
const FWidgetStyle& InWidgetStyle |
Gets the color value represented by this Slate color. |
![]() ![]() |
const FLinearColor & | ||
![]() ![]() |
FLinearColor | Gets the specified color value. | |
![]() ![]() |
bool | Checks whether the values for this color have been specified. | |
![]() |
bool | SerializeFromMismatchedTag
(
const FPropertyTag& Tag, |
Used to upgrade an FColor or FLinearColor property to an FSlateColor property |
![]() |
void | Unlink () |
If the color rule is set to UseColor_Specified_Link, this will copy the linked color internally, unlink it and set the color rule to UseColor_Specified. |
![]() ![]() |
FSlateColor | ||
![]() ![]() |
FSlateColor | UseStyle () |
|
![]() ![]() |
FSlateColor |
Operators
Type | Name | Description | |
---|---|---|---|
![]() ![]() |
bool | operator!=
(
const FSlateColor& Other |
Compares this color with another for inequality. |
![]() ![]() |
bool | operator==
(
const FSlateColor& Other |
Compares this color with another for equality. |