#include <grid.h>
Public Member Functions | |
PAPYRUS_DRAWABLE (Grid) | |
virtual | ~Grid () |
double | x_min () |
void | set_x_min (double min) |
double | x_max () |
void | set_x_max (double max) |
void | x_min_max (double &min, double &max) |
void | set_x_min_max (double min, double max) |
double | y_min () |
void | set_y_min (double min) |
double | y_max () |
void | set_y_max (double max) |
void | y_min_max (double &min, double &max) |
void | set_y_min_max (double min, double max) |
void | xy_min_max (double &x_min, double &x_max, double &y_min, double &y_max) |
void | set_xy_min_max (double x_min, double x_max, double y_min, double y_max) |
void | enable_axis (unsigned which=X_AXIS|Y_AXIS) |
void | disable_axis (unsigned which=X_AXIS|Y_AXIS) |
Stroke::pointer | x_axis_stroke () const |
void | set_x_axis_stroke (Stroke::pointer stroke) |
Stroke::pointer | y_axis_stroke () const |
void | set_y_axis_stroke (Stroke::pointer stroke) |
void | set_xy_axis_stroke (Stroke::pointer stroke) |
void | enable_border (unsigned which=TOP|RIGHT|BOTTOM|LEFT) |
void | disable_border (unsigned which=TOP|RIGHT|BOTTOM|LEFT) |
void | set_border_stroke (Stroke::pointer stroke, unsigned which=TOP|RIGHT|BOTTOM|LEFT) |
double | x_interval () |
void | set_x_interval (double x_interval) |
Stroke::pointer | x_interval_stroke () |
void | set_x_interval_stroke (Stroke::pointer) |
double | y_interval () |
void | set_y_interval (double y_interval) |
Stroke::pointer | y_interval_stroke () |
void | set_y_interval_stroke (Stroke::pointer) |
void | xy_interval (double &x_interval, double &y_interval) |
void | set_xy_interval (double interval) |
void | set_xy_interval (double x_interval, double y_interval) |
void | xy_interval_stroke (Stroke::pointer x_stroke, Stroke::pointer y_stroke) |
void | set_xy_interval_stroke (Stroke::pointer stroke) |
void | set_xy_interval_stroke (Stroke::pointer x_stroke, Stroke::pointer y_stroke) |
virtual void | draw (Context &cairo) const |
Draws on the provided context. | |
Static Public Member Functions | |
static pointer | create (double xmin=-infinity, double xmax=infinity, double ymin=-infinity, double ymax=infinity) |
static pointer | create (const Glib::ustring &id, double xmin=-infinity, double xmax=infinity, double ymin=-infinity, double ymax=infinity) |
Static Public Attributes | |
static const double | infinity = 1.5e4 |
Protected Member Functions | |
Grid (const Glib::ustring &id, double xmin=-infinity, double xmax=infinity, double ymin=-infinity, double ymax=infinity) | |
Protected Attributes | |
Stroke::pointer | m_x_axis_stroke |
Stroke::pointer | m_y_axis_stroke |
Stroke::pointer | m_x_interval_stroke |
Stroke::pointer | m_y_interval_stroke |
Stroke::pointer | m_border_stroke [4] |
double | m_x_min |
double | m_x_max |
double | m_y_min |
double | m_y_max |
double | m_x_interval |
double | m_y_interval |
unsigned int | m_enabled_axes |
unsigned int | m_enabled_borders |
Papyrus::Grid::Grid | ( | const Glib::ustring & | id, | |
double | xmin = -infinity , |
|||
double | xmax = infinity , |
|||
double | ymin = -infinity , |
|||
double | ymax = infinity | |||
) | [protected] |
Papyrus::Grid::~Grid | ( | ) | [virtual] |
Grid::pointer Papyrus::Grid::create | ( | const Glib::ustring & | id, | |
double | xmin = -infinity , |
|||
double | xmax = infinity , |
|||
double | ymin = -infinity , |
|||
double | ymax = infinity | |||
) | [static] |
References PAPYRUS_CREATE.
Grid::pointer Papyrus::Grid::create | ( | double | xmin = -infinity , |
|
double | xmax = infinity , |
|||
double | ymin = -infinity , |
|||
double | ymax = infinity | |||
) | [static] |
References PAPYRUS_CREATE.
void Papyrus::Grid::disable_axis | ( | unsigned | which = X_AXIS | Y_AXIS |
) |
References m_enabled_axes, and Papyrus::Drawable::redraw().
void Papyrus::Grid::disable_border | ( | unsigned | which = TOP | RIGHT | BOTTOM | LEFT |
) |
References m_enabled_borders, and Papyrus::Drawable::redraw().
void Papyrus::Grid::draw | ( | Context & | cairo | ) | const [virtual] |
Draws on the provided context.
Implements Papyrus::Drawable.
References Papyrus::BOTTOM, Papyrus::LEFT, m_border_stroke, m_enabled_axes, m_enabled_borders, m_x_axis_stroke, m_x_interval, m_x_interval_stroke, m_x_max, m_x_min, m_y_axis_stroke, m_y_interval, m_y_interval_stroke, m_y_max, m_y_min, Papyrus::RIGHT, Papyrus::Context::stroke(), Papyrus::TOP, Papyrus::X_AXIS, and Papyrus::Y_AXIS.
void Papyrus::Grid::enable_axis | ( | unsigned | which = X_AXIS | Y_AXIS |
) |
References m_enabled_axes, and Papyrus::Drawable::redraw().
void Papyrus::Grid::enable_border | ( | unsigned | which = TOP | RIGHT | BOTTOM | LEFT |
) |
References m_enabled_borders, and Papyrus::Drawable::redraw().
Papyrus::Grid::PAPYRUS_DRAWABLE | ( | Grid | ) |
void Papyrus::Grid::set_border_stroke | ( | Stroke::pointer | stroke, | |
unsigned | which = TOP | RIGHT | BOTTOM | LEFT | |||
) |
References Papyrus::BOTTOM, Papyrus::LEFT, m_border_stroke, Papyrus::RIGHT, and Papyrus::TOP.
void Papyrus::Grid::set_x_axis_stroke | ( | Stroke::pointer | stroke | ) |
References m_x_axis_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_x_interval | ( | double | x_interval | ) |
References m_x_interval, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_x_interval_stroke | ( | Stroke::pointer | stroke | ) |
References m_x_interval_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_x_max | ( | double | max | ) |
References m_x_max, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_x_min | ( | double | min | ) |
References m_x_min, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_x_min_max | ( | double | min, | |
double | max | |||
) |
References m_x_max, m_x_min, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_axis_stroke | ( | Stroke::pointer | stroke | ) |
References m_x_axis_stroke, m_y_axis_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_interval | ( | double | x_interval, | |
double | y_interval | |||
) |
References m_x_interval, m_y_interval, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_interval | ( | double | interval | ) |
References m_x_interval, m_y_interval, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_interval_stroke | ( | Stroke::pointer | x_stroke, | |
Stroke::pointer | y_stroke | |||
) |
References m_x_interval_stroke, m_y_interval_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_interval_stroke | ( | Stroke::pointer | stroke | ) |
References m_x_interval_stroke, m_y_interval_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_xy_min_max | ( | double | x_min, | |
double | x_max, | |||
double | y_min, | |||
double | y_max | |||
) |
References m_x_max, m_x_min, m_y_max, m_y_min, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_axis_stroke | ( | Stroke::pointer | stroke | ) |
References m_y_axis_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_interval | ( | double | y_interval | ) |
References m_y_interval, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_interval_stroke | ( | Stroke::pointer | stroke | ) |
References m_y_interval_stroke, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_max | ( | double | max | ) |
References m_y_max, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_min | ( | double | min | ) |
References m_y_min, and Papyrus::Drawable::redraw().
void Papyrus::Grid::set_y_min_max | ( | double | min, | |
double | max | |||
) |
References m_y_max, m_y_min, and Papyrus::Drawable::redraw().
Stroke::pointer Papyrus::Grid::x_axis_stroke | ( | ) | const |
References m_x_axis_stroke.
double Papyrus::Grid::x_interval | ( | ) |
References m_x_interval.
Stroke::pointer Papyrus::Grid::x_interval_stroke | ( | ) |
References m_x_interval_stroke.
double Papyrus::Grid::x_max | ( | ) |
References m_x_max.
double Papyrus::Grid::x_min | ( | ) |
References m_x_min.
void Papyrus::Grid::xy_interval | ( | double & | x_interval, | |
double & | y_interval | |||
) |
References m_x_interval, and m_y_interval.
void Papyrus::Grid::xy_interval_stroke | ( | Stroke::pointer | x_stroke, | |
Stroke::pointer | y_stroke | |||
) |
References m_x_interval_stroke, and m_y_interval_stroke.
void Papyrus::Grid::xy_min_max | ( | double & | x_min, | |
double & | x_max, | |||
double & | y_min, | |||
double & | y_max | |||
) |
Stroke::pointer Papyrus::Grid::y_axis_stroke | ( | ) | const |
References m_y_axis_stroke.
double Papyrus::Grid::y_interval | ( | ) |
References m_y_interval.
Stroke::pointer Papyrus::Grid::y_interval_stroke | ( | ) |
References m_y_interval_stroke.
double Papyrus::Grid::y_max | ( | ) |
References m_y_max.
double Papyrus::Grid::y_min | ( | ) |
References m_y_min.
const double Papyrus::Grid::infinity = 1.5e4 [static] |
Stroke::pointer Papyrus::Grid::m_border_stroke[4] [protected] |
Referenced by draw(), and set_border_stroke().
unsigned int Papyrus::Grid::m_enabled_axes [protected] |
Referenced by disable_axis(), draw(), and enable_axis().
unsigned int Papyrus::Grid::m_enabled_borders [protected] |
Referenced by disable_border(), draw(), and enable_border().
Stroke::pointer Papyrus::Grid::m_x_axis_stroke [protected] |
Referenced by draw(), set_x_axis_stroke(), set_xy_axis_stroke(), and x_axis_stroke().
double Papyrus::Grid::m_x_interval [protected] |
Referenced by draw(), set_x_interval(), set_xy_interval(), x_interval(), and xy_interval().
Stroke::pointer Papyrus::Grid::m_x_interval_stroke [protected] |
Referenced by draw(), set_x_interval_stroke(), set_xy_interval_stroke(), x_interval_stroke(), and xy_interval_stroke().
double Papyrus::Grid::m_x_max [protected] |
Referenced by draw(), set_x_max(), set_x_min_max(), set_xy_min_max(), x_max(), x_min_max(), and xy_min_max().
double Papyrus::Grid::m_x_min [protected] |
Referenced by draw(), set_x_min(), set_x_min_max(), set_xy_min_max(), x_min(), x_min_max(), and xy_min_max().
Stroke::pointer Papyrus::Grid::m_y_axis_stroke [protected] |
Referenced by draw(), set_xy_axis_stroke(), set_y_axis_stroke(), and y_axis_stroke().
double Papyrus::Grid::m_y_interval [protected] |
Referenced by draw(), set_xy_interval(), set_y_interval(), xy_interval(), and y_interval().
Stroke::pointer Papyrus::Grid::m_y_interval_stroke [protected] |
Referenced by draw(), set_xy_interval_stroke(), set_y_interval_stroke(), xy_interval_stroke(), and y_interval_stroke().
double Papyrus::Grid::m_y_max [protected] |
Referenced by draw(), set_xy_min_max(), set_y_max(), set_y_min_max(), xy_min_max(), y_max(), and y_min_max().
double Papyrus::Grid::m_y_min [protected] |
Referenced by draw(), set_xy_min_max(), set_y_min(), set_y_min_max(), xy_min_max(), y_min(), and y_min_max().