fawkes::GeomDrawingArea Class Reference
A Gtk::DrawingArea that allows to easily display drawable objects of the geometry library. More...
#include <geometry/gtk/geom_drawing_area.h>
Public Member Functions | |
| GeomDrawingArea (float max_x=5.0, float max_y=5.0, float min_x=-5.0, float min_y=-5.0) | |
| Constructor. | |
| GeomDrawingArea (BaseObjectType *cobject, const Glib::RefPtr< Gnome::Glade::Xml > &ref_xml) | |
| Constructor. | |
| virtual | ~GeomDrawingArea () |
| Destructor. | |
| void | clear () |
| Clear the drawing area. | |
| GeomDrawingArea & | operator<< (fawkes::HomPoint &p) |
| <<-operator for HomPoint objects | |
| GeomDrawingArea & | operator<< (const fawkes::HomPoint &p) |
| <<-operator for HomPoint objects | |
| GeomDrawingArea & | operator<< (std::pair< HomVector, HomPoint > v) |
| <<-operator for HomVector objects | |
| GeomDrawingArea & | operator<< (fawkes::LineSegment &l) |
| <<-operator for LineSegments objects | |
| GeomDrawingArea & | operator<< (fawkes::Bezier &b) |
| <<-operator for Bezier objects. | |
| GeomDrawingArea & | operator<< (fawkes::Spline &s) |
| <<-operator for Spline objects. | |
| GeomDrawingArea & | operator<< (const fawkes::Spline &s) |
| <<-operator for Spline objects. | |
| GeomDrawingArea & | operator<< (fawkes::DrawingManipulator *m) |
| <<-operator for DrawingManipulator objects. | |
| virtual void | to_drawing_coords (int window_x, int window_y, float &drawing_x, float &drawing_y) |
| Convert the given window coordinates into the frame of the drawing area. | |
Protected Member Functions | |
| virtual void | pre_draw (Cairo::RefPtr< Cairo::Context > &context) |
| This method is called by the expose signal handler before the draw routines of the registered drawers are called. | |
| virtual void | post_draw (Cairo::RefPtr< Cairo::Context > &context) |
| This method is called by the expose signal handler after the draw routines of the registered drawers are called. | |
Detailed Description
A Gtk::DrawingArea that allows to easily display drawable objects of the geometry library.
Definition at line 42 of file geom_drawing_area.h.
Constructor & Destructor Documentation
| fawkes::GeomDrawingArea::GeomDrawingArea | ( | float | max_x = 5.0, |
|
| float | max_y = 5.0, |
|||
| float | min_x = -5.0, |
|||
| float | min_y = -5.0 | |||
| ) |
Constructor.
- Parameters:
-
max_x top right corner max_y top right corner min_x bottom left corner min_y bottom left corner
Definition at line 75 of file geom_drawing_area.cpp.
| fawkes::GeomDrawingArea::GeomDrawingArea | ( | BaseObjectType * | cobject, | |
| const Glib::RefPtr< Gnome::Glade::Xml > & | ref_xml | |||
| ) |
Constructor.
- Parameters:
-
cobject pointer to the base object ref_xml Glade XML file
Definition at line 91 of file geom_drawing_area.cpp.
| fawkes::GeomDrawingArea::~GeomDrawingArea | ( | ) | [virtual] |
Member Function Documentation
| void fawkes::GeomDrawingArea::clear | ( | void | ) |
Clear the drawing area.
Definition at line 111 of file geom_drawing_area.cpp.
Referenced by ~GeomDrawingArea().
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | fawkes::DrawingManipulator * | m | ) |
<<-operator for DrawingManipulator objects.
Note: the drawing area takes over the ownwership of the manipulator.
- Parameters:
-
m a DrawingManipulator object
- Returns:
- a reference to the drawing area
Definition at line 232 of file geom_drawing_area.cpp.
References fawkes::DrawingManipulator::integrate().
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | const fawkes::Spline & | s | ) |
<<-operator for Spline objects.
- Parameters:
-
s a Spline object
- Returns:
- a reference to the drawing area
Definition at line 218 of file geom_drawing_area.cpp.
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | fawkes::Spline & | s | ) |
<<-operator for Spline objects.
- Parameters:
-
s a Spline object
- Returns:
- a reference to the drawing area
Definition at line 205 of file geom_drawing_area.cpp.
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | fawkes::Bezier & | b | ) |
<<-operator for Bezier objects.
- Parameters:
-
b a Bezier object
- Returns:
- a reference to the drawing area
Definition at line 192 of file geom_drawing_area.cpp.
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | fawkes::LineSegment & | l | ) |
<<-operator for LineSegments objects
- Parameters:
-
l a LineSegment object
- Returns:
- a reference to the drawing area
Definition at line 179 of file geom_drawing_area.cpp.
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | std::pair< HomVector, HomPoint > | vp | ) |
<<-operator for HomVector objects
- Parameters:
-
vp a pair constisting of the vector and the offset
- Returns:
- a reference to the drawing area
Definition at line 164 of file geom_drawing_area.cpp.
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | const fawkes::HomPoint & | p | ) |
<<-operator for HomPoint objects
- Parameters:
-
p a HomPoint object
- Returns:
- a reference to the drawing area
Definition at line 147 of file geom_drawing_area.cpp.
References fawkes::DrawingManipulator::get_point_size(), and fawkes::HomPointDrawer::set_point_size().
| GeomDrawingArea & fawkes::GeomDrawingArea::operator<< | ( | fawkes::HomPoint & | p | ) |
<<-operator for HomPoint objects
- Parameters:
-
p a HomPoint object
- Returns:
- a reference to the drawing area
Definition at line 130 of file geom_drawing_area.cpp.
References fawkes::DrawingManipulator::get_point_size(), and fawkes::HomPointDrawer::set_point_size().
| void fawkes::GeomDrawingArea::post_draw | ( | Cairo::RefPtr< Cairo::Context > & | context | ) | [protected, virtual] |
This method is called by the expose signal handler after the draw routines of the registered drawers are called.
Derived classes might want to change this to add static drawing elements.
- Parameters:
-
context the drawing context
Definition at line 329 of file geom_drawing_area.cpp.
| void fawkes::GeomDrawingArea::pre_draw | ( | Cairo::RefPtr< Cairo::Context > & | context | ) | [protected, virtual] |
This method is called by the expose signal handler before the draw routines of the registered drawers are called.
Derived classes might want to change this to add static drawing elements or to change the viewing matrix.
- Parameters:
-
context the drawing context
Definition at line 316 of file geom_drawing_area.cpp.
| void fawkes::GeomDrawingArea::to_drawing_coords | ( | int | window_x, | |
| int | window_y, | |||
| float & | drawing_x, | |||
| float & | drawing_y | |||
| ) | [virtual] |
Convert the given window coordinates into the frame of the drawing area.
- Parameters:
-
window_x the window coordinate window_y the window coordinate drawing_x the drawing coordinate drawing_y the drawing coordinate
Definition at line 298 of file geom_drawing_area.cpp.
The documentation for this class was generated from the following files:
- src/libs/geometry/gtk/geom_drawing_area.h
- src/libs/geometry/gtk/geom_drawing_area.cpp

