Class ImagePanel¶
- Defined in File imagepanel.h
Page Contents
Inheritance Relationships¶
Base Type¶
public nanogui::Widget
(Class Widget)
Class Documentation¶
-
class
nanogui::
ImagePanel
¶ Image panel widget which shows a number of square-shaped icons.
Inherits from nanogui::Widget
Public Types
-
typedef std::vector<std::pair<int, std::string>>
Images
¶
Public Functions
-
std::function<void(int)>
callback
() const¶
-
void
setCallback
(const std::function<void(int)> &callback)¶
-
virtual bool
mouseMotionEvent
(const Vector2i &p, const Vector2i &rel, int button, int modifiers)¶ Handle a mouse motion event (default implementation: propagate to children)
-
virtual bool
mouseButtonEvent
(const Vector2i &p, int button, bool down, int modifiers)¶ Handle a mouse button event (default implementation: propagate to children)
-
virtual Vector2i
preferredSize
(NVGcontext *ctx) const¶ Compute the preferred size of the widget.
-
virtual void
draw
(NVGcontext *ctx)¶ Draw the widget (and all child widgets)
-
typedef std::vector<std::pair<int, std::string>>