repaint_handler Struct Reference

Derive from repaint_handler to implement your repaint object which will be invoked whenever there is a resize event or if some other viewport is created or deleted or activated. Your repaint handler is expected to ask for the viewports size and completely repaint this region. The cmd passed to your repaint handler is one of the cmd_constant enum values. More...

#include <cursorwindow.h>

Inheritance diagram for repaint_handler:
Inheritance graph
[legend]

List of all members.

Public Types

enum  cmd_constant {
  activate,
  deactivate,
  resize
}
 

values that will be passed to the function call operator method.

More...

Public Member Functions

virtual void operator() (viewport *vp, int cmd)=0
virtual ~repaint_handler ()

Detailed Description

Derive from repaint_handler to implement your repaint object which will be invoked whenever there is a resize event or if some other viewport is created or deleted or activated. Your repaint handler is expected to ask for the viewports size and completely repaint this region. The cmd passed to your repaint handler is one of the cmd_constant enum values.

Maintenance note: a repaint_handler should not store a pointer to its viewport because the viewport associated with a viewer will change over time. A viewer has the responsibility of completely repainting the viewport it given when asked to do so. This means, you can't store the size of the viewport either -- but must inquire it from the viewport passed during resizes and handle_event() calls.

Definition at line 772 of file cursorwindow.h.


Member Enumeration Documentation

values that will be passed to the function call operator method.

Enumerator:
activate 

means you have been activated

deactivate 

some other viewport has taken focus

resize 

only the size has changed

Definition at line 793 of file cursorwindow.h.


Constructor & Destructor Documentation

~repaint_handler (  )  [virtual]

Definition at line 1925 of file cursorwindow.cxx.


Member Function Documentation

virtual void operator() ( viewport vp,
int  cmd 
) [pure virtual]

The documentation for this struct was generated from the following files:
Generated on Wed Feb 29 22:54:06 2012 for CXXUtilities by  doxygen 1.6.3