C# Class SidebarLibrary.General.ColorUtil

Summary description for ColorConvert.
Datei anzeigen Open project: sillsdev/FieldWorks

Public Properties

Property Type Description
KnownColorNames string[]
SystemColorNames string[]

Public Methods

Method Description
ColorFromPoint ( Graphics g, int x, int y ) : Color
ColorFromRGBString ( string text ) : Color
GetBValue ( uint color ) : byte
GetCOLORREF ( Color color ) : uint
GetGValue ( uint color ) : byte
GetRValue ( uint color ) : byte
HSLToRGB ( float h, float s, float l, float &r, float &g, float &b ) : void
IsKnownColor ( Color color, Color &knownColor, bool useTransparent ) : bool
IsSystemColor ( Color color, Color &knownColor ) : bool
RGB ( int r, int g, int b ) : uint
RGBToHSL ( int r, int g, int b, float &h, float &s, float &l ) : void

Private Methods

Method Description
CalculateColor ( Color front, Color back, int alpha ) : Color
ColorUtil ( ) : System
getRGBValue ( float n1, float n2, float hue ) : float

Method Details

ColorFromPoint() static public method

static public ColorFromPoint ( Graphics g, int x, int y ) : Color
g System.Drawing.Graphics
x int
y int
return Color

ColorFromRGBString() static public method

static public ColorFromRGBString ( string text ) : Color
text string
return Color

GetBValue() static public method

static public GetBValue ( uint color ) : byte
color uint
return byte

GetCOLORREF() static public method

static public GetCOLORREF ( Color color ) : uint
color Color
return uint

GetGValue() static public method

static public GetGValue ( uint color ) : byte
color uint
return byte

GetRValue() static public method

static public GetRValue ( uint color ) : byte
color uint
return byte

HSLToRGB() static public method

static public HSLToRGB ( float h, float s, float l, float &r, float &g, float &b ) : void
h float
s float
l float
r float
g float
b float
return void

IsKnownColor() static public method

static public IsKnownColor ( Color color, Color &knownColor, bool useTransparent ) : bool
color Color
knownColor Color
useTransparent bool
return bool

IsSystemColor() static public method

static public IsSystemColor ( Color color, Color &knownColor ) : bool
color Color
knownColor Color
return bool

RGB() static public method

static public RGB ( int r, int g, int b ) : uint
r int
g int
b int
return uint

RGBToHSL() static public method

static public RGBToHSL ( int r, int g, int b, float &h, float &s, float &l ) : void
r int
g int
b int
h float
s float
l float
return void

Property Details

KnownColorNames static_oe public_oe property

static public string[] KnownColorNames
return string[]

SystemColorNames static_oe public_oe property

static public string[] SystemColorNames
return string[]