xtd 1.0.0
Loading...
Searching...
No Matches
color_box.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "../forms_export.hpp"
7#include "dialog_result.hpp"
8#include "iwin32_window.hpp"
9#include <xtd/drawing/color>
10#include <xtd/static>
11#include <xtd/string>
12
14namespace xtd {
16 namespace forms {
36 public:
38
45 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::forms::iwin32_window& owner) -> xtd::forms::dialog_result;
52 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::forms::iwin32_window& owner, const xtd::string& title) -> xtd::forms::dialog_result;
60 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::forms::iwin32_window& owner, const xtd::string& title, color_box_styles styles) -> xtd::forms::dialog_result;
69 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::forms::iwin32_window& owner, const xtd::string& title, color_box_styles styles, const xtd::array<xtd::drawing::color>& custom_colors) -> xtd::forms::dialog_result;
70
75 [[nodiscard]] static auto show(xtd::drawing::color& color) -> xtd::forms::dialog_result;
81 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::string& title) -> xtd::forms::dialog_result;
88 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::string& title, color_box_styles styles) -> xtd::forms::dialog_result;
96 [[nodiscard]] static auto show(xtd::drawing::color& color, const xtd::string& title, color_box_styles styles, const xtd::array<xtd::drawing::color>& custom_colors) -> xtd::forms::dialog_result;
98
99 private:
100 [[nodiscard]] static auto show_color_box(xtd::drawing::color& color, const xtd::forms::iwin32_window* owner = nullptr, const xtd::string& title = xtd::string::empty_string, color_box_styles styles = color_box_styles::alpha_color | color_box_styles::allow_full_open, const std::optional<xtd::array<xtd::drawing::color>>& custom_colors = std::optional<xtd::array<xtd::drawing::color >> {}) -> xtd::forms::dialog_result;
101 };
102 }
103}
Provides methods for creating, manipulating, searching, and sorting arrays, thereby serving as the ba...
Definition array.hpp:64
static const basic_string empty_string
Definition basic_string.hpp:111
Represents an ARGB (alpha, red, green, blue) color.
Definition color.hpp:52
Represents a common dialog box that displays available colors along with controls that enable the use...
Definition color_box.hpp:35
static auto show(xtd::drawing::color &color, const xtd::string &title) -> xtd::forms::dialog_result
Displays a color box. The color box displays a color.
static auto show(xtd::drawing::color &color, const xtd::forms::iwin32_window &owner, const xtd::string &title) -> xtd::forms::dialog_result
Displays a color box in front of the specified window. The color box displays a color.
static auto show(xtd::drawing::color &color, const xtd::string &title, color_box_styles styles) -> xtd::forms::dialog_result
Displays a color box. The color box displays a color with styles.
static auto show(xtd::drawing::color &color, const xtd::forms::iwin32_window &owner, const xtd::string &title, color_box_styles styles) -> xtd::forms::dialog_result
Displays a color box in front of the specified window. The color box displays a color with styles.
static auto show(xtd::drawing::color &color, const xtd::string &title, color_box_styles styles, const xtd::array< xtd::drawing::color > &custom_colors) -> xtd::forms::dialog_result
Displays a color box. The color box displays a color with styles, and custom colors.
static auto show(xtd::drawing::color &color) -> xtd::forms::dialog_result
Displays a color box. The color box displays a color.
static auto show(xtd::drawing::color &color, const xtd::forms::iwin32_window &owner, const xtd::string &title, color_box_styles styles, const xtd::array< xtd::drawing::color > &custom_colors) -> xtd::forms::dialog_result
Displays a color box in front of the specified window. The color box displays a color with styles,...
static auto show(xtd::drawing::color &color, const xtd::forms::iwin32_window &owner) -> xtd::forms::dialog_result
Displays a color box in front of the specified window. The color box displays a color.
Provides an interface to expose Win32 HWND handles.
Definition iwin32_window.hpp:23
Contains xtd::forms::color_box_styles enum class.
Contains xtd::forms::dialog_result enum class.
Contains forms_export_ keyword.
#define static_
This keyword is use to represent a static object. A static object can't be instantiated (constructors...
Definition static.hpp:38
#define forms_export_
Define shared library export.
Definition forms_export.hpp:13
xtd::basic_string< char > string
Represents text as a sequence of UTF-8 code units.
Definition __string_definitions.hpp:43
color_box_styles
Specifies constants defining which color_box styles is used.
Definition color_box_styles.hpp:22
dialog_result
Specifies identifiers to indicate the return value of a dialog box.
Definition dialog_result.hpp:43
@ alpha_color
The color box shows alpha values and an opacity selector (slider).
Definition color_box_styles.hpp:26
@ allow_full_open
The user can use the dialog box to define custom colors.
Definition color_box_styles.hpp:28
Contains xtd::forms::iwin32_window interface.
The xtd::forms namespace contains classes for creating Windows-based applications that take full adva...
Definition texts.hpp:219
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8