14#ifndef X11GRAPHICSWINDOW_H
15#define X11GRAPHICSWINDOW_H
26class x11GraphicsWindow :
public GraphicsWindow {
28 x11GraphicsWindow(GraphicsEngine *engine, GraphicsPipe *pipe,
29 const std::string &name,
34 GraphicsOutput *host);
35 virtual ~x11GraphicsWindow();
52 virtual void close_window();
53 virtual bool open_window();
55 virtual void mouse_mode_absolute();
56 virtual void mouse_mode_relative();
61 virtual void setup_colormap(XVisualInfo *visual);
62 void handle_keystroke(XKeyEvent &event);
63 void handle_keypress(XKeyEvent &event);
64 void handle_keyrelease(XKeyEvent &event);
66 ButtonHandle get_button(XKeyEvent &key_event,
bool allow_shift);
69 ButtonHandle get_mouse_button(XButtonEvent &button_event);
70 virtual ButtonMap *get_keyboard_map()
const;
72 static Bool check_event(X11_Display *display, XEvent *event,
char *arg);
77 X11_Cursor get_cursor(
const Filename &filename);
78 X11_Cursor read_ico(std::istream &ico);
81 X11_Display *_display;
86 XVisualInfo *_visual_info;
87 Rotation _orig_rotation;
90 LVecBase2i _fixed_size;
95 clock_t _awaiting_configure_since;
96 bool _dga_mouse_enabled;
97 Bool _override_redirect;
98 Atom _wm_delete_window;
100 x11GraphicsPipe::pfn_XRRGetScreenInfo _XRRGetScreenInfo;
101 x11GraphicsPipe::pfn_XRRSetScreenConfig _XRRSetScreenConfig;
107 static void init_type() {
108 GraphicsWindow::init_type();
110 GraphicsWindow::get_class_type());
113 return get_class_type();
115 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
123 pmap<Filename, X11_Cursor> _cursor_filenames;
The name of a file, such as a texture file or an Egg file.
A container for the various kinds of properties we might ask to have on a graphics frameBuffer before...
Encapsulates all the communication with a particular instance of a given rendering backend.
A thread; that is, a lightweight process.
TypeHandle is the identifier used to differentiate C++ class types.
A container for the various kinds of properties we might ask to have on a graphics window before we o...
virtual bool begin_frame(FrameMode mode, Thread *current_thread)
This function will be called within the draw thread before beginning rendering for a given frame.
virtual void process_events()
Do whatever processing is necessary to ensure that the window responds to user events.
virtual void clear(Thread *current_thread)
Clears the entire framebuffer before rendering, according to the settings of get_color_clear_active()...
virtual bool move_pointer(int device, int x, int y)
Forces the pointer to the indicated position within the window, if possible.
void enable_detectable_auto_repeat()
Enables detectable auto-repeat if supported by the X server.
virtual void set_properties_now(WindowProperties &properties)
Applies the requested set of properties to the window, if possible, for instance to request a change ...
virtual MouseData get_pointer(int device) const
Returns the MouseData associated with the nth input device's pointer.
X11_Window get_xwindow() const
Returns the X11 Window handle.
virtual void end_frame(FrameMode mode, Thread *current_thread)
This function will be called within the draw thread after rendering is completed for a given frame.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
BEGIN_PUBLISH typedef PointerData MouseData
Deprecated alias for PointerData.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.