Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

X11Display Class Reference

#include <x11_display.hxx>

Inheritance diagram for X11Display:

Inheritance graph
[legend]
Collaboration diagram for X11Display:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 X11Display (int w, int h, bool fullscreen_)
virtual ~X11Display ()
void draw_lines (std::vector< Line > &lines, Color color, int wide=0)
void draw_line (float x1, float y1, float x2, float y2, Color color, int wide=0)
void draw_rect (float x1, float y1, float x2, float y2, Color color)
void draw_fill_rect (float x1, float y1, float x2, float y2, Color color)
void draw_circle (float x, float y, float r, Color color)
void draw_circles (std::vector< Circle > &circles, Color color)
void draw_fill_circle (float x, float y, float r, Color color)
void draw_string (float x, float y, const std::string &str, Color color)
void draw_string_centered (float x, float y, const std::string &str, Color color)
int get_width ()
int get_height ()
void set_fullscreen (bool fullscreen)
void restore_mode ()
void clear ()
void flip ()
void real_flip ()
void flip (int x1, int y1, int x2, int y2)
int get_mouse_x ()
int get_mouse_y ()
bool get_key (int key)
void wait_for_events_blocking ()
void wait_for_events ()
void run ()
void set_clip_rect (int x1_, int y1_, int x2_, int y2_)
unsigned int get_color_value (Color &color)

Detailed Description

X11Display driver

Definition at line 46 of file x11_display.hxx.


Constructor & Destructor Documentation

X11Display::X11Display int    w,
int    h,
bool    fullscreen_
 

Definition at line 47 of file x11_display.cxx.

References set_fullscreen(), settings, VERSION, and wm_delete_window.

X11Display::~X11Display   [virtual]
 

Definition at line 152 of file x11_display.cxx.

References restore_mode().


Member Function Documentation

void X11Display::clear   [virtual]
 

Implements GraphicContext.

Definition at line 542 of file x11_display.cxx.

void X11Display::draw_circle float    x,
float    y,
float    r,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 228 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_circles std::vector< Circle > &    circles,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 182 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_fill_circle float    x,
float    y,
float    r,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 217 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_fill_rect float    x1,
float    y1,
float    x2,
float    y2,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 208 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_line float    x1,
float    y1,
float    x2,
float    y2,
Color    color,
int    wide = 0
[virtual]
 

Implements GraphicContext.

Definition at line 201 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_lines std::vector< Line > &    lines,
Color    color,
int    wide = 0
[virtual]
 

Implements GraphicContext.

Definition at line 166 of file x11_display.cxx.

void X11Display::draw_rect float    x1,
float    y1,
float    x2,
float    y2,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 236 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_string float    x,
float    y,
const std::string &    str,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 245 of file x11_display.cxx.

References get_color_value().

void X11Display::draw_string_centered float    x,
float    y,
const std::string &    str,
Color    color
[virtual]
 

Implements GraphicContext.

Definition at line 252 of file x11_display.cxx.

References get_color_value().

void X11Display::flip int    x1,
int    y1,
int    x2,
int    y2
[virtual]
 

Implements GraphicContext.

Definition at line 549 of file x11_display.cxx.

References FlipRect::x1, FlipRect::x2, FlipRect::y1, and FlipRect::y2.

void X11Display::flip   [virtual]
 

Flip the double buffered display

Implements GraphicContext.

Definition at line 584 of file x11_display.cxx.

unsigned int X11Display::get_color_value Color   color
 

Definition at line 764 of file x11_display.cxx.

References Color::b, Color::g, and Color::r.

Referenced by draw_circle(), draw_circles(), draw_fill_circle(), draw_fill_rect(), draw_line(), draw_rect(), draw_string(), and draw_string_centered().

int X11Display::get_height   [inline, virtual]
 

Implements GraphicContext.

Definition at line 92 of file x11_display.hxx.

bool X11Display::get_key int    key [virtual]
 

Returns:
true if the button with the given keycode is currently pressed, false otherwise

Implements InputContext.

Definition at line 273 of file x11_display.cxx.

int X11Display::get_mouse_x   [virtual]
 

Returns:
mouse x coordinate

Implements InputContext.

Definition at line 261 of file x11_display.cxx.

int X11Display::get_mouse_y   [virtual]
 

Returns:
mouse y coordinate

Implements InputContext.

Definition at line 267 of file x11_display.cxx.

int X11Display::get_width   [inline, virtual]
 

Implements GraphicContext.

Definition at line 91 of file x11_display.hxx.

void X11Display::real_flip   [virtual]
 

perform the real flip, only flip marked reagions

Reimplemented from GraphicContext.

Definition at line 565 of file x11_display.cxx.

void X11Display::restore_mode  
 

Definition at line 717 of file x11_display.cxx.

Referenced by ~X11Display().

void X11Display::run  
 

Definition at line 699 of file x11_display.cxx.

References Controller::instance(), ScreenManager::instance(), ScreenManager::is_finished(), Controller::is_running(), ScreenManager::run_once(), SystemContext::sleep(), system_context, wait_for_events(), and wait_for_events_blocking().

void X11Display::set_clip_rect int    x1_,
int    y1_,
int    x2_,
int    y2_
[virtual]
 

Implements GraphicContext.

Definition at line 748 of file x11_display.cxx.

void X11Display::set_fullscreen bool    fullscreen
 

Definition at line 599 of file x11_display.cxx.

Referenced by X11Display().

void X11Display::wait_for_events  
 

Definition at line 287 of file x11_display.cxx.

Referenced by run().

void X11Display::wait_for_events_blocking  
 

Waits for events to come in, blocks until new events are available

Definition at line 279 of file x11_display.cxx.

Referenced by run().


The documentation for this class was generated from the following files:
Generated on Thu Jul 24 10:25:30 2003 for Construo by doxygen1.3-rc3

Rabisu Mirror Service We provide mirrors to support Open source communities. Our mirror server is located in Istanbul/Turkey region.

Please do not hesitate to contact mirror@rabisu.com for new open source mirror submissions.