Ocular Engine
ColorPreview.hpp
1 
17 #pragma once
18 #ifndef __H__OCULAR_EDITOR_COLOR_PREVIEW__H__
19 #define __H__OCULAR_EDITOR_COLOR_PREVIEW__H__
20 
21 #include <QtWidgets/qframe.h>
22 #include "Math/Color.hpp"
23 
24 //------------------------------------------------------------------------------------------
25 
30 namespace Ocular
31 {
36  namespace Editor
37  {
43  class ColorPreview : public QFrame
44  {
45  Q_OBJECT
46 
47  public:
48 
49  ColorPreview(QWidget* parent = nullptr);
50  virtual ~ColorPreview();
51 
52  virtual QSize sizeHint() const override;
53 
54  void setColor(Core::Color const& color);
55  Core::Color const& getColor() const;
56 
57  protected:
58 
59  Core::Color m_Color;
60 
61  private:
62 
63  };
64  }
68 }
73 //------------------------------------------------------------------------------------------
74 
75 #endif
Note: Once this library is made dynamic, this will no longer be needed.
Definition: Common.hpp:70
Definition: Color.hpp:40
Definition: ColorPreview.hpp:43