Search
Preparing search index...
The search index is not available
Swim Toolkit
Options
All
Public
Public/Protected
All
Inherited
Externals
Menu
Swim Toolkit
@swim/style
RgbColor
Class RgbColor
Hierarchy
Color
RgbColor
Index
Constructors
constructor
Properties
a
b
g
r
string
Value
Brighter
Darker
Accessors
lightness
Methods
alpha
combine
contrast
darker
debug
equals
equivalent
To
hash
Code
hsl
interpolate
To
is
Defined
lighter
plus
rgb
times
to
Hex
String
to
String
black
for
Name
form
from
Any
from
Init
from
Value
hsl
is
Any
is
Init
parse
rgb
transparent
white
Constructors
constructor
new
Rgb
Color
(
r
:
number
, g
:
number
, b
:
number
, a
?:
number
)
:
RgbColor
Parameters
r:
number
g:
number
b:
number
Optional
a:
number
Returns
RgbColor
Properties
Readonly
a
a
:
number
Readonly
b
b
:
number
Readonly
g
g
:
number
Readonly
r
r
:
number
Readonly
string
Value
string
Value
:
undefined
|
string
Static
Brighter
Brighter
:
number
Static
Darker
Darker
:
number
Accessors
lightness
get
lightness
(
)
:
number
Returns
number
Methods
alpha
alpha
(
)
:
number
alpha
(
a
:
number
)
:
RgbColor
Returns
number
Parameters
a:
number
Returns
RgbColor
combine
combine
(
that
:
AnyColor
, scalar
?:
number
)
:
Color
Parameters
that:
AnyColor
Optional
scalar:
number
Returns
Color
contrast
contrast
(
k
?:
number
)
:
Color
Parameters
Optional
k:
number
Returns
Color
darker
darker
(
k
?:
number
)
:
RgbColor
Parameters
Optional
k:
number
Returns
RgbColor
debug
debug
(
output
:
Output
<
unknown
>
)
:
void
Parameters
output:
Output
<
unknown
>
Returns
void
equals
equals
(
that
:
unknown
)
:
boolean
Parameters
that:
unknown
Returns
boolean
equivalent
To
equivalent
To
(
that
:
unknown
, epsilon
?:
number
)
:
boolean
Parameters
that:
unknown
Optional
epsilon:
number
Returns
boolean
hash
Code
hash
Code
(
)
:
number
Returns
number
hsl
hsl
(
)
:
HslColor
Returns
HslColor
interpolate
To
interpolate
To
(
that
:
RgbColor
)
:
Interpolator
<
RgbColor
>
interpolate
To
(
that
:
Color
)
:
Interpolator
<
Color
>
interpolate
To
(
that
:
unknown
)
:
null
|
Interpolator
<
Color
>
Parameters
that:
RgbColor
Returns
Interpolator
<
RgbColor
>
Parameters
that:
Color
Returns
Interpolator
<
Color
>
Parameters
that:
unknown
Returns
null
|
Interpolator
<
Color
>
is
Defined
is
Defined
(
)
:
boolean
Returns
boolean
lighter
lighter
(
k
?:
number
)
:
RgbColor
Parameters
Optional
k:
number
Returns
RgbColor
plus
plus
(
that
:
AnyColor
)
:
RgbColor
Parameters
that:
AnyColor
Returns
RgbColor
rgb
rgb
(
)
:
RgbColor
Returns
RgbColor
times
times
(
scalar
:
number
)
:
RgbColor
Parameters
scalar:
number
Returns
RgbColor
to
Hex
String
to
Hex
String
(
)
:
string
Returns
string
to
String
to
String
(
)
:
string
Returns
string
Static
black
black
(
alpha
?:
number
)
:
RgbColor
Parameters
Optional
alpha:
number
Returns
RgbColor
Static
for
Name
for
Name
(
name
:
string
)
:
null
|
Color
Parameters
name:
string
Returns
null
|
Color
Static
form
form
(
)
:
Form
<
Color
,
AnyColor
>
Returns
Form
<
Color
,
AnyColor
>
Static
from
Any
from
Any
(
value
:
AnyRgbColor
)
:
RgbColor
Parameters
value:
AnyRgbColor
Returns
RgbColor
Static
from
Init
from
Init
(
value
:
RgbColorInit
)
:
RgbColor
Parameters
value:
RgbColorInit
Returns
RgbColor
Static
from
Value
from
Value
(
value
:
Value
)
:
null
|
RgbColor
Parameters
value:
Value
Returns
null
|
RgbColor
Static
hsl
hsl
(
h
:
AnyAngle
, s
:
number
, l
:
number
, a
?:
number
)
:
HslColor
Parameters
h:
AnyAngle
s:
number
l:
number
Optional
a:
number
Returns
HslColor
Static
is
Any
is
Any
(
value
:
unknown
)
:
value
is
AnyRgbColor
Parameters
value:
unknown
Returns
value
is
AnyRgbColor
Static
is
Init
is
Init
(
value
:
unknown
)
:
value
is
RgbColorInit
Parameters
value:
unknown
Returns
value
is
RgbColorInit
Static
parse
parse
(
str
:
string
)
:
RgbColor
Parameters
str:
string
Returns
RgbColor
Static
rgb
rgb
(
r
:
number
, g
:
number
, b
:
number
, a
?:
number
)
:
RgbColor
Parameters
r:
number
g:
number
b:
number
Optional
a:
number
Returns
RgbColor
Static
transparent
transparent
(
)
:
RgbColor
Returns
RgbColor
Static
white
white
(
alpha
?:
number
)
:
RgbColor
Parameters
Optional
alpha:
number
Returns
RgbColor
Modules
@swim/system
@swim/toolkit
@swim/ui
@swim/model
@swim/style
@swim/theme
@swim/view
@swim/dom
@swim/graphics
@swim/component
@swim/ux
@swim/vis
@swim/maps
Rgb
Color
constructor
a
b
g
r
string
Value
Brighter
Darker
lightness
alpha
combine
contrast
darker
debug
equals
equivalent
To
hash
Code
hsl
interpolate
To
is
Defined
lighter
plus
rgb
times
to
Hex
String
to
String
black
for
Name
form
from
Any
from
Init
from
Value
hsl
is
Any
is
Init
parse
rgb
transparent
white
Generated using
TypeDoc