25 #include <geometry/gtk/drawing_manipulator.h>
46 m_line_width_set =
false;
47 m_point_size_set =
false;
64 if ( !m_line_width_set && m->m_line_width_set )
65 { m_line_width = m->m_line_width; }
67 if ( !m_point_size_set && m->m_point_size_set)
68 { m_point_size = m->m_point_size; }
70 if ( !m_color_set && m->m_color_set)
72 m_color_r = m->m_color_r;
73 m_color_g = m->m_color_g;
74 m_color_b = m->m_color_b;
88 m_line_width_set =
true;
110 m_point_size_set =
true;
178 if ( 0 > r || 1 < r || 0 > g || 1 < g || 0 > b || 1 < b )
204 if (m_line_width_set)
205 { context->set_line_width(m_line_width); }
208 { context->set_source_rgb(m_color_r, m_color_g, m_color_b); }
float get_point_size() const
Get the point size.
virtual ~DrawingManipulator()
Desctructor.
float get_line_width() const
Get the line width.
DrawingManipulator * set_point_size(float s)
Creates a drawing manipulator which sets the given point size.
Color
Some pre-defined colors.
Fawkes library namespace.
DrawingManipulator * set_color(float r, float g, float b)
Creates a drawing manipulator which sets the given color.
void set_point_size(float s)
Set the point size.
DrawingManipulator * set_line_width(float w)
Creates a drawing manipulator which sets the given line width.
DrawingManipulator()
Constructor.
void set_color(Color c)
Set the color.
void get_color(float &r, float &g, float &b) const
Get the color.
void set_line_width(float w)
Set the line width.
void integrate(const DrawingManipulator *m)
Integrates the parameters of another manipulator.
Allows to control some aspects of the rendering of objects.
virtual void draw(Cairo::RefPtr< Cairo::Context > &context)
This method is called by the GeomDrawingArea.