
#include <GUI/XWinManaged.H>
Inheritance diagram for XWinManaged:


This class is an extension of the XWindow class to allow event handling. In the current implementation, exposure and resize events are handled. Instead of destroying the window, clicking the close button will set a flag that can be accessed by calling pressedCloseButton().
Definition at line 67 of file XWinManaged.H.
Public Member Functions | |
| XWinManaged (const Dims &dims, const int x=-1, const int y=-1, const char *title="USC Neuromorphic Vision") | |
| Constructor: create, display and map the window, start the event handling. | |
| XWinManaged (const Image< PixRGB< byte > > &img, const char *title="USC Neuromorphic Vision") | |
| Constructor: create a window as large as img and display img. | |
| XWinManaged (const Image< byte > &img, const char *title="USC Neuromorphic Vision") | |
| Constructor: create a window as large as img and display img. | |
| XWinManaged (const Image< float > &img, const char *title="USC Neuromorphic Vision", bool normalize=true) | |
| Constructor: create a window as large as img and display img. | |
| virtual | ~XWinManaged () |
| Destructor: destroy the window and stop the event handling. | |
| bool | pressedCloseButton () |
| returns whether the user has clicked the close button. | |
| void | setTraceEvents (bool on) |
| request that event tracing be turned on or off | |
| int | getLastKeyPress () |
| returns the key press at the front of the keyboard buffer | |
| std::string | getLastKeyString () |
| get the decoded string of the last key press | |
| KeySym | getLastKeySym (std::string *s=0) |
| get the decoded keysym of the last key press | |
| bool | getLastKeyEvent (XKeyEvent *ev) |
| copy the last key event into ev, and pop that event from the queue | |
| Point2D< int > | getLastMouseClick () |
| returns the last mouse click at the front of the click buffer | |
| bool | getLastButtonEvent (XButtonEvent *ev) |
| copy the last button press event into ev, and pop that event from the queue | |
| std::string | describeKeyEvent (const XKeyEvent *ev) const |
| std::string | describeButtonEvent (const XButtonEvent *ev) const |
| std::string | describeEvent (const XEvent *ev) const |
|
||||||||||||||||||||
|
Constructor: create, display and map the window, start the event handling. The call of to the constructor is identical to the parent class XWindow. In addition to creating the window, the event handling is started.
Definition at line 78 of file XWinManaged.C. |
|
||||||||||||
|
Constructor: create a window as large as img and display img.
Definition at line 89 of file XWinManaged.C. References XWindow::drawImage(). |
|
||||||||||||
|
Constructor: create a window as large as img and display img.
Definition at line 101 of file XWinManaged.C. References XWindow::drawImage(). |
|
||||||||||||||||
|
Constructor: create a window as large as img and display img.
Definition at line 111 of file XWinManaged.C. References XWindow::drawImage(). |
|
|
Destructor: destroy the window and stop the event handling.
Definition at line 123 of file XWinManaged.C. References rutz::mutex_atomic_int::atomic_set(), and LERROR. |
|
|
copy the last button press event into ev, and pop that event from the queue
Definition at line 294 of file XWinManaged.C. References GVX_MUTEX_LOCK. Referenced by PrefsWindow::update(). |
|
|
copy the last key event into ev, and pop that event from the queue
Definition at line 272 of file XWinManaged.C. References GVX_MUTEX_LOCK. |
|
|
returns the key press at the front of the keyboard buffer returns -1 if no key press has occured since the last call Definition at line 226 of file XWinManaged.C. References ev. Referenced by ENV_SHOWIMG(), BotControl::getUserInput(), main(), SHOWIMG(), and BeoPilot::updateGUI(). |
|
|
get the decoded string of the last key press returns an empty string if no key press has occured since the last call Definition at line 236 of file XWinManaged.C. Referenced by getDigit(), and main(). |
|
|
get the decoded keysym of the last key press Returns NoSymbol if no key press has occured since the last call. Also return the corresponding string through s if s is non-null. Definition at line 252 of file XWinManaged.C. Referenced by PrefsWindow::update(). |
|
|
returns the last mouse click at the front of the click buffer does not distinguish between right and left buttons; returns (-1,-1) if no mouse clicks have occured since the last call Definition at line 284 of file XWinManaged.C. References ev. Referenced by ENV_SHOWIMG(), BotControl::getUserInput(), main(), and SHOWIMG(). |
|
|
returns whether the user has clicked the close button.
Definition at line 105 of file XWinManaged.H. Referenced by LeastSquaresLearner::getBiasMap(), main(), and BeoPilot::updateGUI(). |
|
|
request that event tracing be turned on or off
Definition at line 220 of file XWinManaged.C. References rutz::mutex_atomic_int::atomic_set(). |
1.4.4