string Rgb { get; set; }

book_4_sparkGenerated
code_blocksInput

Description

The Rgb property of the Color32 struct provides a string representation of the color in the CSS rgb function notation. This format is commonly used in web development to specify colors using their red, green, and blue components.

Usage

Use the Rgb property to obtain a string that represents the color in the format rgb(r, g, b), where r, g, and b are the red, green, and blue components of the color, respectively. This can be useful for displaying color values in a human-readable format or for use in CSS styling.

Example

// Example of using the Rgb property
Color32 color = new Color32(255, 100, 50, 255);
string rgbString = color.Rgb;
// rgbString will be "rgb(255, 100, 50)"