Hot Door CORE 0.8.4
Adobe® Illustrator® Plug-in Library
Loading...
Searching...
No Matches
hdicoreColorWell.h
Go to the documentation of this file.
1
6
7#ifndef __HDI_CORE_COLOR_WELL__
8#define __HDI_CORE_COLOR_WELL__
9
10#if defined(HDI_CORE_AIP_MODE)
11 #include "hdicoreArtColor.h"
12#elif defined(HDI_CORE_PSP_MODE)
13 #include "hdicoreColor.h"
14#endif
15
16#include "hdicoreWidget.h"
17
18namespace hdi
19{
20 namespace core
21 {
22 #if defined(HDI_CORE_AIP_MODE)
23 typedef ArtColor PluginColor;
24 #elif defined(HDI_CORE_PSP_MODE)
25 typedef Color PluginColor;
26 #endif
27
28 class Callback;
29
33 class ColorWell : public Widget
34 {
35 public:
48
56 ColorWell(const ColorWell& colorwell_);
57
71 ColorWell(const Rect& frame_, const PluginColor& color_);
72
78 virtual ~ColorWell();
79
88 virtual ColorWell& operator=(const ColorWell& rhs_);
89
103 virtual ColorWell* clone() const;
104
115 virtual ColorWell* duplicate() const;
116
127 static bool showColorPicker(const PluginColor& inColor_, PluginColor& outColor__);
128
137 static bool colorPickerShowing();
138
146 virtual PluginColor currentColor() const;
147
160 virtual void setCurrentColor(const PluginColor& color_);
161
167 virtual void valueChanged();
168
176 virtual Callback* const valueChangedCallback() const;
177
185 virtual void setValueChangedCallback(const Callback& callback_);
186 };
187
188 typedef std::unique_ptr<ColorWell> ColorWellUP;
189 typedef std::shared_ptr<ColorWell> ColorWellSP;
190 typedef std::weak_ptr<ColorWell> ColorWellWP;
191 }
192}
193
194#endif
195// __HDI_CORE_COLORWELL__
Describes the color of art on the artboard.
Definition hdicoreArtColor.h:42
Base class for templated __Callback class.
Definition hdicoreCallback.h:68
Describes an RGB color, with opacity, typically for UI purposes.
Definition hdicoreColor.h:34
static bool colorPickerShowing()
Gets whether any color picker dialog is currently showing due to a color well being clicked or the sh...
virtual ColorWell * duplicate() const
Convenience method to duplicate a ColorWell object, creating a new and identical UI element to the ta...
virtual ColorWell & operator=(const ColorWell &rhs_)
Allows one ColorWell object to be assigned from another.
virtual Callback *const valueChangedCallback() const
Gets the value changed callback for the color well.
static bool showColorPicker(const PluginColor &inColor_, PluginColor &outColor__)
Shows a color picker and provides the chosen color, unless the user canceled.
virtual PluginColor currentColor() const
Gets the current value of the color well.
ColorWell(const ColorWell &colorwell_)
Constructs a new ColorWell object from an existing ColorWell object (copy constructor).
virtual void valueChanged()
Simulates the color well having its value changed.
virtual void setCurrentColor(const PluginColor &color_)
Sets the current value of the color well.
ColorWell()
Constructs an empty ColorWell object.
virtual ~ColorWell()
ColorWell destructor.
virtual ColorWell * clone() const
Convenience method to clone a ColorWell object on the heap.
virtual void setValueChangedCallback(const Callback &callback_)
Sets the value changed callback.
ColorWell(const Rect &frame_, const PluginColor &color_)
Constructs a color well.
Contains Point and Size objects to describe a rectangle that exists at a specific point of given dime...
Definition hdicoreRect.h:34
Widget()
Constructs an empty Widget object.
Header file for art color manipulation.
Header file for describing plugin UI colors.
Header file for plugin user interface widgets.