VSTGUI 4.10 Graphical User Interface Framework not only for VST plugins

Loading...
Searching...
No Matches
Classes | Enumerations | Functions
Version 4.11
New classes

## Classes
struct | EventConsumeState
| EventConsumeState. More...
struct | Event
| Event. More...
struct | Modifiers
| Modifiers. More...
struct | ModifierEvent
| ModifierEvent. More...
struct | MousePositionEvent
| MousePositionEvent. More...
struct | MouseEventButtonState
| MouseEventButtonState. More...
struct | MouseEvent
| MouseEvent. More...
struct | MouseEnterEvent
| MouseEnterEvent. More...
struct | MouseExitEvent
| MouseExitEvent. More...
struct | MouseDownUpMoveEvent
| MouseDownUpMoveEvent. More...
struct | MouseDownEvent
| MouseDownEvent. More...
struct | MouseUpEvent
| MouseUpEvent. More...
struct | MouseMoveEvent
| MouseMoveEvent. More...
struct | MouseCancelEvent
| MouseCancelEvent. More...
struct | MouseWheelEvent
| MouseWheelEvent. More...
struct | GestureEvent
| GestureEvent. More...
struct | ZoomGestureEvent
| ZoomGestureEvent. More...
struct | KeyboardEvent
| KeyboardEvent. More...
class | IViewEventListener
| View Event Listener Interface. More...

## Enumerations
enum class | EventType : uint32_t { Unknown , MouseDown , MouseMove , MouseUp , MouseCancel , MouseEnter , MouseExit , MouseWheel , ZoomGesture , KeyUp , KeyDown }
| EventType. More...
enum class | MouseButton : uint32_t { None = 0 , Left = 1 << 1 , Middle = 1 << 2 , Right = 1 << 3 , Fourth = 1 << 4 , Fifth = 1 << 5 }
| MouseButton. More...
enum class | VirtualKey : uint32_t { None = 0 , Back , Tab , Clear , Return , Pause , Escape , Space , Next , End , Home , Left , Up , Right , Down , PageUp , PageDown , Select , Print , Enter , Snapshot , Insert , Delete , Help , NumPad0 , NumPad1 , NumPad2 , NumPad3 , NumPad4 , NumPad5 , NumPad6 , NumPad7 , NumPad8 , NumPad9 , Multiply , Add , Separator , Subtract , Decimal , Divide , F1 , F2 , F3 , F4 , F5 , F6 , F7 , F8 , F9 , F10 , F11 , F12 , NumLock , Scroll , ShiftModifier , ControlModifier , AltModifier , Equals }
| VirtualKey. More...
enum class | ModifierKey : uint32_t { Shift = 1 << 0 , Alt = 1 << 1 , Control = 1 << 2 , Super = 1 << 3 , None = 0 }
| ModifierKey. More...

## Functions
template<typename EventT, typename OutputT = MousePositionEvent, typename MousePositionEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>
MousePositionEventT * | asMousePositionEvent (EventT &event)
| event as mouse position event or nullpointer if not a mouse position event
template<typename EventT, typename OutputT = MouseEvent, typename MouseEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>
MouseEventT * | asMouseEvent (EventT &event)
| event as mouse position event or nullpointer if not a mouse position event
template<typename EventT, typename OutputT = MouseDownEvent, typename MouseDownEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>
MouseDownEventT * | asMouseDownEvent (EventT &event)
| event as mouse down event or nullpointer if not a mouse down event
template<typename EventT, typename OutputT = ModifierEvent, typename ModifierEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>
ModifierEventT * | asModifierEvent (EventT &event)
| event as modifier event or nullpointer if not a modifier event
template<typename EventT, typename OutputT = KeyboardEvent, typename KeyboardEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>
KeyboardEventT * | asKeyboardEvent (EventT &event)
| event as keyboard event or nullpointer if not a keyboard event
MousePositionEvent & | castMousePositionEvent (Event &event)
| cast event to a mouse position event
MouseEvent & | castMouseEvent (Event &event)
| cast event to a mouse event
MouseDownEvent & | castMouseDownEvent (Event &event)
| cast event to a mouse down event
MouseMoveEvent & | castMouseMoveEvent (Event &event)
| cast event to a mouse move event
MouseUpEvent & | castMouseUpEvent (Event &event)
| cast event to a mouse up event
MouseEnterEvent & | castMouseEnterEvent (Event &event)
| cast event to a mouse enter event
MouseExitEvent & | castMouseExitEvent (Event &event)
| cast event to a mouse exit event
MouseCancelEvent & | castMouseCancelEvent (Event &event)
| cast event to a mouse cancel event
MouseWheelEvent & | castMouseWheelEvent (Event &event)
| cast event to a mouse wheel event
ZoomGestureEvent & | castZoomGestureEvent (Event &event)
| cast event to a zoom gesture event
KeyboardEvent & | castKeyboardEvent (Event &event)
| cast event to a mouse wheel event
CButtonState | buttonStateFromEventModifiers (const Modifiers &mods)
| convert from new Modifiers to old CButtonState
CButtonState | buttonStateFromMouseEvent (const MouseEvent &event)
| convert from new MouseEvent to old CButtonState
unsigned char | toVstVirtualKey (VirtualKey key)
| helper function to convert from new VirtualKey to old VstVirtualKey
virtual void | viewOnMouseEnabled (CView *view, bool state)=0
| called when a view's mouse handling is enabled or disabled

## Detailed Description

## Enumeration Type Documentation

## ◆ EventType

enum class EventType : uint32_t
| strong

EventType.

Enumerator
Unknown |
MouseDown |
MouseMove |
MouseUp |
MouseCancel |
MouseEnter |
MouseExit |
MouseWheel |
ZoomGesture |
KeyUp |
KeyDown |

## ◆ ModifierKey

enum class ModifierKey : uint32_t
| strong

ModifierKey.

Enumerator
Shift | the left or right shift key
Alt | the alternate key
Control | the control key (Command key on macOS and control key on other platforms)
Super | the super key (Control key on macOS, Windows key on Windows and Super key on other platforms)
None |

## ◆ MouseButton

enum class MouseButton : uint32_t
| strong

MouseButton.

Enumerator
None |
Left |
Middle |
Right |
Fourth |
Fifth |

## ◆ VirtualKey

enum class VirtualKey : uint32_t
| strong

VirtualKey.

Enumerator
None |
Back |
Tab |
Clear |
Return |
Pause |
Escape |
Space |
Next |
End |
Home |
Left |
Up |
Right |
Down |
PageUp |
PageDown |
Select |
Print |
Enter |
Snapshot |
Insert |
Delete |
Help |
NumPad0 |
NumPad1 |
NumPad2 |
NumPad3 |
NumPad4 |
NumPad5 |
NumPad6 |
NumPad7 |
NumPad8 |
NumPad9 |
Multiply |
Add |
Separator |
Subtract |
Decimal |
Divide |
F1 |
F2 |
F3 |
F4 |
F5 |
F6 |
F7 |
F8 |
F9 |
F10 |
F11 |
F12 |
NumLock |
Scroll |
ShiftModifier |
ControlModifier |
AltModifier |
Equals |

## Function Documentation

## ◆ asKeyboardEvent()

template<typename EventT, typename OutputT = KeyboardEvent, typename KeyboardEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>

KeyboardEventT * asKeyboardEvent | ( | EventT & | event | ) |
| inline

event as keyboard event or nullpointer if not a keyboard event

## ◆ asModifierEvent()

template<typename EventT, typename OutputT = ModifierEvent, typename ModifierEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>

ModifierEventT * asModifierEvent | ( | EventT & | event | ) |
| inline

event as modifier event or nullpointer if not a modifier event

## ◆ asMouseDownEvent()

template<typename EventT, typename OutputT = MouseDownEvent, typename MouseDownEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>

MouseDownEventT * asMouseDownEvent | ( | EventT & | event | ) |
| inline

event as mouse down event or nullpointer if not a mouse down event

## ◆ asMouseEvent()

template<typename EventT, typename OutputT = MouseEvent, typename MouseEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>

MouseEventT * asMouseEvent | ( | EventT & | event | ) |
| inline

event as mouse position event or nullpointer if not a mouse position event

## ◆ asMousePositionEvent()

template<typename EventT, typename OutputT = MousePositionEvent, typename MousePositionEventT = typename std::conditional< std::is_const_v<EventT>, typename std::add_const_t<OutputT>, OutputT>::type>

MousePositionEventT * asMousePositionEvent | ( | EventT & | event | ) |
| inline

event as mouse position event or nullpointer if not a mouse position event

## ◆ buttonStateFromEventModifiers()

CButtonState buttonStateFromEventModifiers | ( | const Modifiers & | mods | ) |

convert from new Modifiers to old CButtonState

## ◆ buttonStateFromMouseEvent()

CButtonState buttonStateFromMouseEvent | ( | const MouseEvent & | event | ) |

convert from new MouseEvent to old CButtonState

## ◆ castKeyboardEvent()

KeyboardEvent & castKeyboardEvent | ( | Event & | event | ) |
| inline

cast event to a mouse wheel event

## ◆ castMouseCancelEvent()

MouseCancelEvent & castMouseCancelEvent | ( | Event & | event | ) |
| inline

cast event to a mouse cancel event

## ◆ castMouseDownEvent()

MouseDownEvent & castMouseDownEvent | ( | Event & | event | ) |
| inline

cast event to a mouse down event

## ◆ castMouseEnterEvent()

MouseEnterEvent & castMouseEnterEvent | ( | Event & | event | ) |
| inline

cast event to a mouse enter event

## ◆ castMouseEvent()

MouseEvent & castMouseEvent | ( | Event & | event | ) |
| inline

cast event to a mouse event

## ◆ castMouseExitEvent()

MouseExitEvent & castMouseExitEvent | ( | Event & | event | ) |
| inline

cast event to a mouse exit event

## ◆ castMouseMoveEvent()

MouseMoveEvent & castMouseMoveEvent | ( | Event & | event | ) |
| inline

cast event to a mouse move event

## ◆ castMousePositionEvent()

MousePositionEvent & castMousePositionEvent | ( | Event & | event | ) |
| inline

cast event to a mouse position event

## ◆ castMouseUpEvent()

MouseUpEvent & castMouseUpEvent | ( | Event & | event | ) |
| inline

cast event to a mouse up event

## ◆ castMouseWheelEvent()

MouseWheelEvent & castMouseWheelEvent | ( | Event & | event | ) |
| inline

cast event to a mouse wheel event

## ◆ castZoomGestureEvent()

ZoomGestureEvent & castZoomGestureEvent | ( | Event & | event | ) |
| inline

cast event to a zoom gesture event

## ◆ toVstVirtualKey()

unsigned char toVstVirtualKey | ( | VirtualKey | key | ) |
| inline

helper function to convert from new VirtualKey to old VstVirtualKey

returns 0 if key cannot be mapped

## ◆ viewOnMouseEnabled()

virtual void viewOnMouseEnabled | ( | CView * | view,
|  | bool | state )
| pure virtual

called when a view's mouse handling is enabled or disabled

Implemented in ViewListenerAdapter.