Inviwo 0.9.12-pre
Inviwo documentation
Loading...
Searching...
No Matches
inviwo::MouseEvent Class Reference
Inheritance diagram for inviwo::MouseEvent:

Public Member Functions

MouseButton button () const
virtual MouseEvent * clone () const override
virtual uint64_t hash () const override
 MouseEvent (const MouseEvent &rhs)=default
 MouseEvent (MouseButton button=MouseButton::Left, MouseState state=MouseState::Press, MouseButtons buttonState=MouseButtons(flags::empty), KeyModifiers modifiers=KeyModifiers(flags::empty), dvec2 normalizedPosition=dvec2(0), uvec2 canvasSize=uvec2(0), double depth=1.0)
MouseEvent & operator= (const MouseEvent &that)=default
virtual void print (std::ostream &ss) const override
void setButton (MouseButton button)
void setState (MouseState state)
MouseState state () const
Public Member Functions inherited from inviwo::MouseInteractionEvent
std::string buttonName () const
MouseButtons buttonState () const
uvec2 canvasSize () const
double depth () const
const MouseCursorCallback & getMouseCursorCallback () const
 MouseInteractionEvent (const MouseInteractionEvent &rhs)=default
 MouseInteractionEvent (MouseButtons buttonState=MouseButtons(flags::empty), KeyModifiers modifiers=KeyModifiers(flags::empty), dvec2 normalizedPosition=dvec2(0), uvec2 canvasSize=uvec2(1), double depth=1.0)
dvec3 ndc () const
MouseInteractionEvent & operator= (const MouseInteractionEvent &that)=default
dvec2 pos () const
dvec2 posNormalized () const
void setButtonState (MouseButtons buttonState)
void setCanvasSize (uvec2 size)
void setDepth (double depth)
void setMouseCursor (MouseCursor cursor) const
void setMouseCursorCallback (MouseCursorCallback callback)
void setPos (dvec2 pos)
void setPosNormalized (dvec2 pos)
double x () const
double y () const
Public Member Functions inherited from inviwo::InteractionEvent
const ContextMenuCallback & getContexMenuCallback () const
const ToolTipCallback & getToolTipCallback () const
 InteractionEvent (const InteractionEvent &rhs)=default
 InteractionEvent (KeyModifiers modifiers=KeyModifiers(flags::empty))
std::string modifierNames () const
KeyModifiers modifiers () const
InteractionEvent & operator= (const InteractionEvent &that)=default
void setContextMenuCallback (ContextMenuCallback callback)
void setModifiers (KeyModifiers modifiers)
void setToolTip (std::string_view tooltip) const
void setToolTipCallback (ToolTipCallback callback)
void showContextMenu (std::span< ContextMenuEntry > entries, ContextMenuCategories categories=ContextMenuCategory::Callback)
Public Member Functions inherited from inviwo::Event
template<typename EventType>
EventType * getAs ()
template<typename EventType>
const EventType * getAs () const
const std::vector< Processor * > & getVisitedProcessors () const
bool hasBeenUsed () const
bool hasVisitedProcessor (Processor *) const
bool markAsUnused ()
bool markAsUsed ()
void markAsVisited (Event &)
bool markAsVisited (Processor *)
bool setUsed (bool isUsed)
virtual bool shouldPropagateTo (Inport *inport, Processor *processor, Outport *source)

Static Public Member Functions

static constexpr uint64_t chash ()

Additional Inherited Members

Public Types inherited from inviwo::MouseInteractionEvent
using MouseCursorCallback = std::function<void(MouseCursor)>
Public Types inherited from inviwo::InteractionEvent
using ContextMenuCallback
using ToolTipCallback = std::function<void(std::string_view)>
Protected Member Functions inherited from inviwo::Event
 Event (const Event &rhs)=default
Event & operator= (const Event &that)=default
Protected Attributes inherited from inviwo::InteractionEvent
ContextMenuCallback contextMenuCallback_
KeyModifiers modifiers_
ToolTipCallback tooltip_

Member Function Documentation

◆ button()

MouseButton inviwo::MouseEvent::button ( ) const

The button responsible for the current event.

◆ clone()

virtual MouseEvent * inviwo::MouseEvent::clone ( ) const
overridevirtual

◆ hash()

virtual uint64_t inviwo::MouseEvent::hash ( ) const
overridevirtual

Implements inviwo::Event.

◆ print()

virtual void inviwo::MouseEvent::print ( std::ostream & ss) const
overridevirtual

Reimplemented from inviwo::Event.

◆ state()

MouseState inviwo::MouseEvent::state ( ) const

The state of the button that generated the event.


The documentation for this class was generated from the following file:
  • include/inviwo/core/interaction/events/mouseevent.h