VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkInteractorStyleUser Class Reference

provides customizable interaction routines More...

#include <vtkInteractorStyleUser.h>

Inherits vtkInteractorStyle.

Public Types

typedef vtkInteractorStyle Superclass
 

Public Member Functions

virtual int IsA (const char *type)
 
vtkInteractorStyleUserNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent)
 
virtual void OnTimer ()
 
virtual int * GetLastPos ()
 
virtual void GetLastPos (int &, int &)
 
virtual void GetLastPos (int[2])
 
virtual int * GetOldPos ()
 
virtual void GetOldPos (int &, int &)
 
virtual void GetOldPos (int[2])
 
virtual int GetShiftKey ()
 
virtual int GetCtrlKey ()
 
virtual int GetChar ()
 
virtual char * GetKeySym ()
 
virtual int GetButton ()
 
virtual void OnMouseMove ()
 
virtual void OnLeftButtonDown ()
 
virtual void OnLeftButtonUp ()
 
virtual void OnMiddleButtonDown ()
 
virtual void OnMiddleButtonUp ()
 
virtual void OnRightButtonDown ()
 
virtual void OnRightButtonUp ()
 
virtual void OnChar ()
 
virtual void OnKeyPress ()
 
virtual void OnKeyRelease ()
 
virtual void OnExpose ()
 
virtual void OnConfigure ()
 
virtual void OnEnter ()
 
virtual void OnLeave ()
 

Static Public Member Functions

static vtkInteractorStyleUserNew ()
 
static int IsTypeOf (const char *type)
 
static vtkInteractorStyleUserSafeDownCast (vtkObjectBase *o)
 

Protected Member Functions

virtual vtkObjectBase * NewInstanceInternal () const
 
 vtkInteractorStyleUser ()
 
 ~vtkInteractorStyleUser ()
 

Protected Attributes

int LastPos [2]
 
int OldPos [2]
 
int ShiftKey
 
int CtrlKey
 
int Char
 
char * KeySym
 
int Button
 

Detailed Description

provides customizable interaction routines

The most common way to customize user interaction is to write a subclass of vtkInteractorStyle: vtkInteractorStyleUser allows you to customize the interaction to without subclassing vtkInteractorStyle. This is particularly useful for setting up custom interaction modes in scripting languages such as Tcl and Python. This class allows you to hook into the MouseMove, ButtonPress/Release, KeyPress/Release, etc. events. If you want to hook into just a single mouse button, but leave the interaction modes for the others unchanged, you must use e.g. SetMiddleButtonPressMethod() instead of the more general SetButtonPressMethod().

Events:
vtkCommand::MouseMoveEvent vtkCommand::LeftButtonReleaseEvent vtkCommand::ExposeEvent vtkCommand::ConfigureEvent vtkCommand::MiddleButtonReleaseEvent vtkCommand::LeftButtonPressEvent vtkCommand::UserEvent vtkCommand::RightButtonPressEvent vtkCommand::KeyPressEvent vtkCommand::KeyReleaseEvent vtkCommand::LeaveEvent vtkCommand::TimerEvent vtkCommand::MiddleButtonPressEvent vtkCommand::EnterEvent vtkCommand::RightButtonReleaseEvent vtkCommand::CharEvent
Examples:
vtkInteractorStyleUser (Examples)

Definition at line 47 of file vtkInteractorStyleUser.h.

Member Typedef Documentation

typedef vtkInteractorStyle vtkInteractorStyleUser::Superclass

Definition at line 51 of file vtkInteractorStyleUser.h.

Constructor & Destructor Documentation

vtkInteractorStyleUser::vtkInteractorStyleUser ( )
protected
vtkInteractorStyleUser::~vtkInteractorStyleUser ( )
protected

Member Function Documentation

static vtkInteractorStyleUser* vtkInteractorStyleUser::New ( )
static
static int vtkInteractorStyleUser::IsTypeOf ( const char *  type)
static
virtual int vtkInteractorStyleUser::IsA ( const char *  type)
virtual
static vtkInteractorStyleUser* vtkInteractorStyleUser::SafeDownCast ( vtkObjectBase *  o)
static
virtual vtkObjectBase* vtkInteractorStyleUser::NewInstanceInternal ( ) const
protectedvirtual
vtkInteractorStyleUser* vtkInteractorStyleUser::NewInstance ( ) const
void vtkInteractorStyleUser::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
virtual int* vtkInteractorStyleUser::GetLastPos ( )
virtual

Get the most recent mouse position during mouse motion. In your user interaction method, you must use this to track the mouse movement. Do not use GetEventPosition(), which records the last position where a mouse button was pressed.

virtual void vtkInteractorStyleUser::GetLastPos ( int &  ,
int &   
)
virtual

Get the most recent mouse position during mouse motion. In your user interaction method, you must use this to track the mouse movement. Do not use GetEventPosition(), which records the last position where a mouse button was pressed.

virtual void vtkInteractorStyleUser::GetLastPos ( int  [2])
virtual

Get the most recent mouse position during mouse motion. In your user interaction method, you must use this to track the mouse movement. Do not use GetEventPosition(), which records the last position where a mouse button was pressed.

virtual int* vtkInteractorStyleUser::GetOldPos ( )
virtual

Get the previous mouse position during mouse motion, or after a key press. This can be used to calculate the relative displacement of the mouse.

virtual void vtkInteractorStyleUser::GetOldPos ( int &  ,
int &   
)
virtual

Get the previous mouse position during mouse motion, or after a key press. This can be used to calculate the relative displacement of the mouse.

virtual void vtkInteractorStyleUser::GetOldPos ( int  [2])
virtual

Get the previous mouse position during mouse motion, or after a key press. This can be used to calculate the relative displacement of the mouse.

virtual int vtkInteractorStyleUser::GetShiftKey ( )
virtual

Test whether modifiers were held down when mouse button or key was pressed

virtual int vtkInteractorStyleUser::GetCtrlKey ( )
virtual

Test whether modifiers were held down when mouse button or key was pressed

virtual int vtkInteractorStyleUser::GetChar ( )
virtual

Get the character for a Char event.

virtual char* vtkInteractorStyleUser::GetKeySym ( )
virtual

Get the KeySym (in the same format as Tk KeySyms) for a KeyPress or KeyRelease method.

virtual int vtkInteractorStyleUser::GetButton ( )
virtual

Get the mouse button that was last pressed inside the window (returns zero when the button is released).

virtual void vtkInteractorStyleUser::OnMouseMove ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnLeftButtonDown ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnLeftButtonUp ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnMiddleButtonDown ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnMiddleButtonUp ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnRightButtonDown ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnRightButtonUp ( )
virtual

Generic event bindings

virtual void vtkInteractorStyleUser::OnChar ( )
virtual

Keyboard functions

virtual void vtkInteractorStyleUser::OnKeyPress ( )
virtual

Keyboard functions

virtual void vtkInteractorStyleUser::OnKeyRelease ( )
virtual

Keyboard functions

virtual void vtkInteractorStyleUser::OnExpose ( )
virtual

These are more esoteric events, but are useful in some cases.

virtual void vtkInteractorStyleUser::OnConfigure ( )
virtual

These are more esoteric events, but are useful in some cases.

virtual void vtkInteractorStyleUser::OnEnter ( )
virtual

These are more esoteric events, but are useful in some cases.

virtual void vtkInteractorStyleUser::OnLeave ( )
virtual

These are more esoteric events, but are useful in some cases.

virtual void vtkInteractorStyleUser::OnTimer ( )
virtual

Member Data Documentation

int vtkInteractorStyleUser::LastPos[2]
protected

Definition at line 126 of file vtkInteractorStyleUser.h.

int vtkInteractorStyleUser::OldPos[2]
protected

Definition at line 127 of file vtkInteractorStyleUser.h.

int vtkInteractorStyleUser::ShiftKey
protected

Definition at line 129 of file vtkInteractorStyleUser.h.

int vtkInteractorStyleUser::CtrlKey
protected

Definition at line 130 of file vtkInteractorStyleUser.h.

int vtkInteractorStyleUser::Char
protected

Definition at line 131 of file vtkInteractorStyleUser.h.

char* vtkInteractorStyleUser::KeySym
protected

Definition at line 132 of file vtkInteractorStyleUser.h.

int vtkInteractorStyleUser::Button
protected

Definition at line 133 of file vtkInteractorStyleUser.h.


The documentation for this class was generated from the following file: