Boost.UI
User Interface Boost library
|
Go to the documentation of this file.
8 #ifndef BOOST_UI_COLOR_HPP
9 #define BOOST_UI_COLOR_HPP
13 #ifdef BOOST_HAS_PRAGMA_ONCE
17 #include <boost/cstdint.hpp>
35 color() BOOST_NOEXCEPT : m_red(0), m_green(0), m_blue(0), m_alpha(0) {}
47 {
return rgba255(red, green, blue, 255); }
66 {
return rgba1(red, green, blue, 1); }
236 return lhs.red255() == rhs.red255() && lhs.green255() == rhs.green255() &&
237 lhs.blue255() == rhs.blue255() && lhs.alpha255() == rhs.alpha255();
246 #endif // BOOST_UI_COLOR_HPP
static const color gainsboro
Predefined color.
Definition: color.hpp:125
static const color orange
Predefined color.
Definition: color.hpp:181
static const color sienna
Predefined color.
Definition: color.hpp:203
static color rgb255(channel255_type red, channel255_type green, channel255_type blue)
Creates opaque color from channels in [0, 255] ragne.
Definition: color.hpp:46
static const color blue_violet
Predefined color.
Definition: color.hpp:86
static const color lavender
Predefined color.
Definition: color.hpp:139
static const color medium_orchid
Predefined color.
Definition: color.hpp:165
static const color salmon
Predefined color.
Definition: color.hpp:199
static const color mint_cream
Predefined color.
Definition: color.hpp:173
static const color light_slate_grey
Predefined color.
Definition: color.hpp:155
static const color lavender_blush
Predefined color.
Definition: color.hpp:140
static const color light_sky_blue
Predefined color.
Definition: color.hpp:153
static const color royal_blue
Predefined color.
Definition: color.hpp:197
static const color old_lace
Predefined color.
Definition: color.hpp:178
static const color orange_red
Predefined color.
Definition: color.hpp:182
channel255_type alpha255() const noexcept
Returns color value in [0, 255] range.
Definition: color.hpp:53
static const color medium_aquamarine
Predefined color.
Definition: color.hpp:163
static const color powder_blue
Predefined color.
Definition: color.hpp:193
static const color light_green
Predefined color.
Definition: color.hpp:148
static const color navajo_white
Predefined color.
Definition: color.hpp:176
double channel1_type
Channel type with values in [0, 1] range.
Definition: color.hpp:57
static const color pale_turquoise
Predefined color.
Definition: color.hpp:186
static const color plum
Predefined color.
Definition: color.hpp:192
static const color grey
Predefined color.
Definition: color.hpp:132
static const color dark_green
Predefined color.
Definition: color.hpp:101
static const color azure
Predefined color.
Definition: color.hpp:80
color() noexcept
Create transparent black color.
Definition: color.hpp:35
static const color black
Predefined color.
Definition: color.hpp:83
static const color chartreuse
Predefined color.
Definition: color.hpp:90
static const color misty_rose
Predefined color.
Definition: color.hpp:174
static const color medium_blue
Predefined color.
Definition: color.hpp:164
static const color khaki
Predefined color.
Definition: color.hpp:138
bool operator==(const color &lhs, const color &rhs) noexcept
Compares two colors.
Definition: color.hpp:234
static const color coral
Predefined color.
Definition: color.hpp:92
channel1_type red1() const noexcept
Returns color value in [0, 1] range.
Definition: color.hpp:69
static const color midnight_blue
Predefined color.
Definition: color.hpp:172
static const color dark_magenta
Predefined color.
Definition: color.hpp:104
channel1_type green1() const noexcept
Returns color value in [0, 1] range.
Definition: color.hpp:70
boost::uint_least8_t channel255_type
Channel type with values in [0, 255] range.
Definition: color.hpp:38
static const color dark_olive_green
Predefined color.
Definition: color.hpp:105
static const color linen
Predefined color.
Definition: color.hpp:160
static const color sandy_brown
Predefined color.
Definition: color.hpp:200
channel255_type green255() const noexcept
Returns color value in [0, 255] range.
Definition: color.hpp:51
static const color deep_pink
Predefined color.
Definition: color.hpp:116
static const color tomato
Predefined color.
Definition: color.hpp:215
static const color light_blue
Predefined color.
Definition: color.hpp:143
static const color magenta
Predefined color.
Definition: color.hpp:161
static const color sea_shell
Predefined color.
Definition: color.hpp:202
static const color violet
Predefined color.
Definition: color.hpp:217
static const color cornsilk
Predefined color.
Definition: color.hpp:94
static const color slate_grey
Predefined color.
Definition: color.hpp:208
static const color pale_goldenrod
Predefined color.
Definition: color.hpp:184
static const color indian_red
Predefined color.
Definition: color.hpp:135
static const color light_cyan
Predefined color.
Definition: color.hpp:145
static const color light_grey
Predefined color.
Definition: color.hpp:149
static const color light_salmon
Predefined color.
Definition: color.hpp:151
Boost C++ libraries namespace.
Definition: window.hpp:19
channel1_type alpha1() const noexcept
Returns color value in [0, 1] range.
Definition: color.hpp:72
static const color bisque
Predefined color.
Definition: color.hpp:82
static const color red
Predefined color.
Definition: color.hpp:195
static const color pale_green
Predefined color.
Definition: color.hpp:185
static const color dark_gray
Predefined color.
Definition: color.hpp:100
static const color maroon
Predefined color.
Definition: color.hpp:162
static const color light_slate_gray
Predefined color.
Definition: color.hpp:154
static const color rosy_brown
Predefined color.
Definition: color.hpp:196
static const color yellow
Predefined color.
Definition: color.hpp:221
static const color dim_grey
Predefined color.
Definition: color.hpp:119
static const color antique_white
Predefined color.
Definition: color.hpp:77
static const color light_sea_green
Predefined color.
Definition: color.hpp:152
static const color dark_blue
Predefined color.
Definition: color.hpp:97
channel255_type red255() const noexcept
Returns color value in [0, 255] range.
Definition: color.hpp:50
static const color blue
Predefined color.
Definition: color.hpp:85
static const color blanched_almond
Predefined color.
Definition: color.hpp:84
static const color goldenrod
Predefined color.
Definition: color.hpp:128
static const color lemon_chiffon
Predefined color.
Definition: color.hpp:142
static const color light_pink
Predefined color.
Definition: color.hpp:150
static const color aquamarine
Predefined color.
Definition: color.hpp:79
static const color dark_orange
Predefined color.
Definition: color.hpp:106
static const color spring_green
Predefined color.
Definition: color.hpp:210
static const color aqua
Predefined color.
Definition: color.hpp:78
static const color dark_grey
Predefined color.
Definition: color.hpp:102
static const color turquoise
Predefined color.
Definition: color.hpp:216
bool operator!=(const color &lhs, const color &rhs) noexcept
Compares two colors.
Definition: color.hpp:239
static const color light_gray
Predefined color.
Definition: color.hpp:147
static const color brown
Predefined color.
Definition: color.hpp:87
static const color steel_blue
Predefined color.
Definition: color.hpp:211
static const color forest_green
Predefined color.
Definition: color.hpp:123
static const color orchid
Predefined color.
Definition: color.hpp:183
static const color dark_khaki
Predefined color.
Definition: color.hpp:103
static const color dark_turquoise
Predefined color.
Definition: color.hpp:114
static const color olive_drab
Predefined color.
Definition: color.hpp:180
static const color papaya_whip
Predefined color.
Definition: color.hpp:188
static const color honeydew
Predefined color.
Definition: color.hpp:133
static const color medium_sea_green
Predefined color.
Definition: color.hpp:167
static const color green
Predefined color.
Definition: color.hpp:130
static const color ivory
Predefined color.
Definition: color.hpp:137
static const color dim_gray
Predefined color.
Definition: color.hpp:118
static const color medium_turquoise
Predefined color.
Definition: color.hpp:170
static const color fuchsia
Predefined color.
Definition: color.hpp:124
static const color navy
Predefined color.
Definition: color.hpp:177
static const color green_yellow
Predefined color.
Definition: color.hpp:131
static const color lime_green
Predefined color.
Definition: color.hpp:159
static const color saddle_brown
Predefined color.
Definition: color.hpp:198
static const color deep_sky_blue
Predefined color.
Definition: color.hpp:117
static const color yellow_green
Predefined color.
Definition: color.hpp:222
static const color light_yellow
Predefined color.
Definition: color.hpp:157
static const color dark_salmon
Predefined color.
Definition: color.hpp:109
static const color medium_violet_red
Predefined color.
Definition: color.hpp:171
static const color hot_pink
Predefined color.
Definition: color.hpp:134
static const color purple
Predefined color.
Definition: color.hpp:194
static const color dark_slate_blue
Predefined color.
Definition: color.hpp:111
static const color dodger_blue
Predefined color.
Definition: color.hpp:120
static const color thistle
Predefined color.
Definition: color.hpp:214
static const color dark_goldenrod
Predefined color.
Definition: color.hpp:99
static const color dark_sea_green
Predefined color.
Definition: color.hpp:110
static color rgb1(channel1_type red, channel1_type green, channel1_type blue)
Creates opaque color from channels in [0, 1] ragne.
Definition: color.hpp:65
static const color dark_slate_grey
Predefined color.
Definition: color.hpp:113
static const color peru
Predefined color.
Definition: color.hpp:190
static const color moccasin
Predefined color.
Definition: color.hpp:175
static const color snow
Predefined color.
Definition: color.hpp:209
static const color floral_white
Predefined color.
Definition: color.hpp:122
static const color crimson
Predefined color.
Definition: color.hpp:95
static const color light_goldenrod_yellow
Predefined color.
Definition: color.hpp:146
static const color indigo
Predefined color.
Definition: color.hpp:136
static const color pink
Predefined color.
Definition: color.hpp:191
channel1_type blue1() const noexcept
Returns color value in [0, 1] range.
Definition: color.hpp:71
static const color pale_violet_red
Predefined color.
Definition: color.hpp:187
static const color lawn_green
Predefined color.
Definition: color.hpp:141
static const color light_coral
Predefined color.
Definition: color.hpp:144
static const color slate_gray
Predefined color.
Definition: color.hpp:207
static const color tan
Predefined color.
Definition: color.hpp:212
static const color ghost_white
Predefined color.
Definition: color.hpp:126
static const color medium_spring_green
Predefined color.
Definition: color.hpp:169
static const color wheat
Predefined color.
Definition: color.hpp:218
static const color dark_violet
Predefined color.
Definition: color.hpp:115
static const color firebrick
Predefined color.
Definition: color.hpp:121
static const color cadet_blue
Predefined color.
Definition: color.hpp:89
static const color dark_slate_gray
Predefined color.
Definition: color.hpp:112
Color class.
Definition: color.hpp:31
static const color dark_orchid
Predefined color.
Definition: color.hpp:107
static const color dark_cyan
Predefined color.
Definition: color.hpp:98
static const color dark_red
Predefined color.
Definition: color.hpp:108
static const color peach_puff
Predefined color.
Definition: color.hpp:189
static const color cyan
Predefined color.
Definition: color.hpp:96
static const color medium_purple
Predefined color.
Definition: color.hpp:166
static const color chocolate
Predefined color.
Definition: color.hpp:91
static const color light_steel_blue
Predefined color.
Definition: color.hpp:156
static const color slate_blue
Predefined color.
Definition: color.hpp:206
static const color white_smoke
Predefined color.
Definition: color.hpp:220
static const color silver
Predefined color.
Definition: color.hpp:204
static const color gray
Predefined color.
Definition: color.hpp:129
static const color beige
Predefined color.
Definition: color.hpp:81
channel255_type blue255() const noexcept
Returns color value in [0, 255] range.
Definition: color.hpp:52
static const color olive
Predefined color.
Definition: color.hpp:179
static const color alice_blue
Predefined color.
Definition: color.hpp:76
static const color cornflower_blue
Predefined color.
Definition: color.hpp:93
static const color lime
Predefined color.
Definition: color.hpp:158
static const color white
Predefined color.
Definition: color.hpp:219
static const color teal
Predefined color.
Definition: color.hpp:213
static const color medium_slate_blue
Predefined color.
Definition: color.hpp:168
static const color gold
Predefined color.
Definition: color.hpp:127
static const color sea_green
Predefined color.
Definition: color.hpp:201
static const color burly_wood
Predefined color.
Definition: color.hpp:88
static const color sky_blue
Predefined color.
Definition: color.hpp:205