xtd - Reference Guide  0.2.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
color_picker.cpp

The following code example demonstrate the use of color_picker picker.

Windows
color_picker_w.png

color_picker_wd.png
macOS
color_picker_m.png

color_picker_md.png
Gnome
color_picker_g.png

color_picker_gd.png
#include <xtd/xtd>
using namespace xtd;
using namespace xtd::drawing;
using namespace xtd::forms;
namespace examples {
class form1 : public form {
public:
form1() {
text("Color picker example");
test_zone.parent(*this);
test_zone.location({10, 50});
test_zone.back_color(color::red);
test_zone.border_style(border_style::fixed_3d);
color_picker.color(test_zone.back_color());
test_zone.back_color(color_picker.color());
};
}
private:
panel test_zone;
};
}
int main() {
application::run(examples::form1());
}