Description
The HighlightColor
property of the FloatControlWidget
class in the Editor
namespace is used to define the color that highlights the widget when it is active or selected. This property is of type Color
and is publicly accessible, allowing developers to customize the appearance of the widget in the editor environment.
Usage
To use the HighlightColor
property, you can directly set it to a Color
value. This will change the highlight color of the FloatControlWidget
when it is in focus or selected. This can be particularly useful for distinguishing different widgets or providing visual feedback to users.
Example
// Example of setting the HighlightColor property
// Create an instance of FloatControlWidget
FloatControlWidget floatControlWidget = new FloatControlWidget();
// Set the highlight color to a bright red
floatControlWidget.HighlightColor = new Color(1.0f, 0.0f, 0.0f, 1.0f); // RGBA for red
// Alternatively, use predefined colors
floatControlWidget.HighlightColor = Color.Green; // Set to green using predefined color