VTK  9.1.0
vtkContextKeyEvent.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkContextScene.h
5
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13
14=========================================================================*/
15
25#ifndef vtkContextKeyEvent_h
26#define vtkContextKeyEvent_h
27
28#include "vtkRenderingContext2DModule.h" // For export macro
29#include "vtkVector.h" // For vtkVector2i
30#include "vtkWeakPointer.h" // For vtkWeakPointer
31
33
34class VTKRENDERINGCONTEXT2D_EXPORT vtkContextKeyEvent
35{
36public:
38
43
49
54
58 vtkVector2i GetPosition() const { return this->Position; }
59
60 char GetKeyCode() const;
61
62protected:
65};
66
67#endif // vtkContextKeyEvent_h
68// VTK-HeaderTest-Exclude: vtkContextKeyEvent.h
data structure to represent key events.
vtkWeakPointer< vtkRenderWindowInteractor > Interactor
vtkVector2i GetPosition() const
Get the position of the mouse when the key was pressed.
void SetPosition(const vtkVector2i &position)
Set the position of the mouse when the key was pressed.
vtkRenderWindowInteractor * GetInteractor() const
Get the interactor for the key event.
char GetKeyCode() const
void SetInteractor(vtkRenderWindowInteractor *interactor)
Set the interactor for the key event.
platform-independent render window interaction including picking and frame rate control.
Some derived classes for the different vectors commonly used.
Definition: vtkVector.h:478
@ position
Definition: vtkX3D.h:267