UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
FColorTheme Class Reference

#include <SColorThemes.h>

Public Member Functions

 FColorTheme (const FString &InName=TEXT(""), const TArray< TSharedPtr< FColorInfo > > &InColors=TArray< TSharedPtr< FColorInfo > >())
 
const TArray< TSharedPtr< FColorInfo > > & GetColors () const
 
void InsertNewColor (TSharedPtr< FLinearColor > InColor, int32 InsertPosition)
 
void InsertNewColor (TSharedPtr< FColorInfo > InColor, int32 InsertPosition)
 
int32 FindApproxColor (const FLinearColor &InColor, float Tolerance=KINDA_SMALL_NUMBER) const
 
void RemoveAll ()
 
int32 RemoveColor (const TSharedPtr< FLinearColor > InColor)
 
 DECLARE_EVENT (FColorTheme, FRefreshEvent)
 
FRefreshEventOnRefresh ()
 

Public Attributes

FString Name
 

Detailed Description

A Color Theme is a name and an array of Colors. It also holds and array of refresh callbacks which it calls every time it changes at all.

Constructor & Destructor Documentation

◆ FColorTheme()

FColorTheme::FColorTheme ( const FString &  InName = TEXT(""),
const TArray< TSharedPtr< FColorInfo > > &  InColors = TArrayTSharedPtr<FColorInfo> >() 
)

Member Function Documentation

◆ DECLARE_EVENT()

FColorTheme::DECLARE_EVENT ( FColorTheme  ,
FRefreshEvent   
)

◆ FindApproxColor()

int32 FColorTheme::FindApproxColor ( const FLinearColor InColor,
float  Tolerance = KINDA_SMALL_NUMBER 
) const

Check to see if a color is already present in the list

◆ GetColors()

const TArray< TSharedPtr< FColorInfo > > & FColorTheme::GetColors ( ) const
inline

Get a list of all the colors in the theme

◆ InsertNewColor() [1/2]

void FColorTheme::InsertNewColor ( TSharedPtr< FColorInfo InColor,
int32  InsertPosition 
)

◆ InsertNewColor() [2/2]

void FColorTheme::InsertNewColor ( TSharedPtr< FLinearColor InColor,
int32  InsertPosition 
)

Insert a color at a specific point in the list and broadcast change

◆ OnRefresh()

FRefreshEvent & FColorTheme::OnRefresh ( )
inline

◆ RemoveAll()

void FColorTheme::RemoveAll ( )

Remove all colors from the list, broadcast change

◆ RemoveColor()

int32 FColorTheme::RemoveColor ( const TSharedPtr< FLinearColor InColor)

Remove specific color from the list, broadcast change

Member Data Documentation

◆ Name

FString FColorTheme::Name

The documentation for this class was generated from the following files: