|
Index
C++ Code Documentation
gtk::widget1::GLWindow
Derived from: gtk::widget0::Window
File: WIDGET/gtk/widget1/GLWindow.H
public:
- GLWindow();
 | void constructor | |
- virtual ~GLWindow();
 | destructor | |
- void enable_draw(bool state = true);
- void clear_screen();
- void show_screen(bool state);
- void swap_buffers();
- void refresh();
 | call gtk_widget_draw() on the screen | |
- void make_current();
 | set the OpenGL context to this screen | |
- uint area_width() const;
 | return the width of the window | |
- uint area_height() const;
 | return the height of the window | |
- static uint const DEFAULT_WIDTH = 500;
 | default window width | |
- static uint const DEFAULT_HEIGHT = 500;
 | default window height | |
protected:
- virtual void draw() = 0;
- virtual int configure_event_cb( GdkEventConfigure * );
 | Called _screen_w is first created and when it changes size | |
- virtual int expose_event_cb( GdkEventExpose * );
 | Called by gtk when _screen_w needs to be redrawn | |
- virtual int button_press_event_cb( GdkEventButton * ) = 0;
 | Called by gtk when the user presses a mouse button. | |
- virtual int button_release_event_cb( GdkEventButton * ) = 0;
 | Called by gtk when the user presses a mouse button. | |
- virtual int motion_notify_event_cb( GdkEventMotion * ) = 0;
 | Called by gtk when user moves or drags the mouse over the window | |
- virtual int key_press_event_cb( GdkEventKey * ) = 0;
 | Called by gtk when a keyboard key is pressed (and the window has focus) | |
- virtual int key_release_event_cb( GdkEventKey * ) = 0;
 | Called by gtk when a keyboard key is released | |
- virtual int focus_in_event_cb( GdkEventFocus * ) = 0;
 | Called by gtk when a keyboard key is released | |
- virtual int focus_out_event_cb( GdkEventFocus * ) = 0;
 | Called by gtk when a keyboard key is released | |
- virtual int delete_event_cb();
- virtual void destroy_cb();
private:
- GLArea *_screen_w;
 | The OpenGL drawing area inside the window. | |
- static gint configure_event_cb_( GtkWidget *, GdkEventConfigure *event, gpointer p );
 | static callback functions -- wrappers for non-static versions | |
- static gint expose_event_cb_( GtkWidget *, GdkEventExpose *event, gpointer p );
- static gint button_press_event_cb_( GtkWidget *, GdkEventButton *event, gpointer p );
- static gint button_release_event_cb_( GtkWidget *, GdkEventButton *event, gpointer p );
- static gint motion_notify_event_cb_( GtkWidget *, GdkEventMotion *event, gpointer p );
- static gint key_press_event_cb_( GtkWidget *, GdkEventKey *event, gpointer p );
- static gint key_release_event_cb_( GtkWidget *, GdkEventKey *event, gpointer p );
- static gint focus_in_event_cb_( GtkWidget *, GdkEventFocus *event, gpointer p );
- static gint focus_out_event_cb_( GtkWidget *, GdkEventFocus *event, gpointer p );
- static void destroy_cb_( GtkWidget *, gpointer p );
- static gint delete_event_cb_( GtkWidget *, GdkEvent *, gpointer p );
- uint _enable_draw;
- GLWindow( GLWindow const & );
 | disabled copy constructor | |
- GLWindow &operator=( GLWindow const & );
 | disabled assignment operator | |
|