|
Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
|
2D canvas for generating EEPIC/LaTeX picture environments. More...
#include <eepicgeom.H>
Public Types | |
| typedef void(Eepic_Plane::* | Draw_Segment_Fct) (const Segment &poly, std::ostream &output) |
Public Member Functions | |
| double | h_geom_number_to_eepic (const Geom_Number &x) const |
Convert a geometric x proportion into plane units using wide. | |
| double | v_geom_number_to_eepic (const Geom_Number &y) const |
Convert a geometric y proportion into plane units using height. | |
| double | x_geom_number_to_eepic (const Geom_Number &x) const |
| Convert a geometric x coordinate into plane x coordinate. | |
| double | y_geom_number_to_eepic (const Geom_Number &y) const |
| Convert a geometric y coordinate into plane y coordinate. | |
| void | compute_extreme_points () |
| Linear scan over all objects to compute extreme points. | |
| void | zoom (const double &factor) |
| Scale the EEPIC plane in real points (zoom in/out). | |
| const Point & | leftmost () const |
| const Point & | rightmost () const |
| const Point & | highest () const |
| const Point & | lowest () const |
| std::string | point_string (const Point &p) |
| Given point p, returns "(x,y)" in normalized plane coordinates. | |
| void | draw (std::ostream &output, const bool &squarize=true) |
Emits a complete LaTeX picture environment containing the geometric objects. | |
| const double & | get_wide () const |
| Plane accessors. | |
| const double & | get_height () const |
| Picture height (in EEPIC units). | |
| const double & | get_yoffset () const |
| Y offset of the LaTeX picture environment. | |
| const double & | get_xoffset () const |
| X offset of the LaTeX picture environment. | |
| const double & | get_r () const |
| Radius used to draw points (also used as text baseline offset). | |
| Eepic_Plane (const double &__wide, const double &__height, const double &__xoffset=0.0, const double &__yoffset=0.0) | |
| Construct a plane with a fixed picture frame. | |
| ~Eepic_Plane () | |
| Destructor: deletes all stored Eepic_Geom_Object clones. | |
| void | put_cartesian_axis () |
| Enable drawing Cartesian axes when calling draw(). | |
| void | put (const Eepic_Geom_Object &__eepic_geom_obj) |
| Design note: why Eepic_Plane stores Eepic_Geom_Object wrappers. | |
| void | set_resolution (const double &res) |
| Set the output resolution in millimeters (unitlength = res mm). | |
| const double & | get_resolution () const |
| Return the current output resolution in millimeters. | |
| void | set_fill_type (const std::string &ftype) |
| Set the fill type used by LaTeX eepic (e.g., "black"). | |
| void | set_shade_thickness (const double &__thickness) |
| Set the thickness used for shaded primitives. | |
| double | get_shade_thickness () const |
| Return the current shading thickness. | |
| double | get_dotgap () const |
| Return the dot gap used for dotted/dashed lines. | |
| void | draw_point (const Point &p, std::ostream &output) |
| EEPIC "primitive drawing" methods. | |
| void | draw_segment (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw segment sg. | |
| void | draw_arrow (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw segment sg with an arrow head. | |
| void | draw_dotted_segment (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw dotted segment sg. | |
| void | draw_dash_segment (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw dashed segment sg. | |
| void | draw_arrow_dotted_segment (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw dotted segment sg with arrow head. | |
| void | draw_arrow_dash_segment (const Segment &sg, std::ostream &output) |
Emit EEPIC code to draw dashed segment sg with arrow head. | |
| void | draw_ellipse (const Ellipse &e, std::ostream &output) |
Emit EEPIC code to draw ellipse e. | |
| template<class Poly > | |
| void | draw_polygon (Poly &poly, std::ostream &output, Draw_Segment_Fct draw_sg_fct) |
| template<class Poly > | |
| void | draw_closed_polygon (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_dotted_closed_polygon (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_dots_from_polygon (Poly &poly, std::ostream &output) |
| void | draw_arrow_extreme (const Segment &sg, std::ostream &output) |
| template<class Poly > | |
| void | draw_arrows_in_polygon (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_closed_polygon_with_arrows (Poly &poly, std::ostream &output) |
| void | draw_point_text (const Point &p, std::ostream &output) |
| template<class Poly > | |
| void | draw_points_text_in_polygon (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_vertex_numbers_in_polygon (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_spline (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_dash_spline (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_spline_arrow (Poly &poly, std::ostream &output) |
| template<class Poly > | |
| void | draw_dash_spline_arrow (Poly &poly, std::ostream &output) |
| void | draw_text (const Text &t, std::ostream &output, const double &hfactor, const double &vfactor) |
Static Public Attributes | |
| static const double | arrow_width_in_mm = 0.5 |
| static const double | arrow_lenght_in_mm = 1.5 |
Private Member Functions | |
| double | geom_number_to_plane (const Geom_Number &p, const Geom_Number &geom_max, const double &max) const |
Rescales a coordinate value p from a geometric scale geom_max into the plane scale max. | |
| double | xpic (const double &x) const |
| Points must be normalized to the plane size (in picture coordinates). | |
| double | ypic (const double &y) const |
| Normalize to y-axis origin. | |
| void | compute_geom_plane (const bool &squarize) |
| Compute extreme coordinates and derive width/height of all objects. | |
| void | draw_cartesian_axis (std::ostream &output) |
Private Attributes | |
| double | wide |
| Width in resolution points. | |
| double | height |
| Height in resolution points. | |
| double | real_wide = 0 |
| Actual width after scaling. | |
| double | real_height = 0 |
| Actual height after scaling. | |
| double | xoffset |
| Additional horizontal margin. | |
| double | yoffset |
| Additional vertical margin. | |
| Geom_Number | geom_wide |
| Width from leftmost to rightmost point. | |
| Geom_Number | geom_height |
| Height from lowest to highest point. | |
| DynDlist< Eepic_Geom_Object * > | list |
| List of geometric objects. | |
| Geom_Number | geom_x_min |
| Minimum x value in geometric coordinates. | |
| Geom_Number | geom_y_min |
| Minimum y value in geometric coordinates. | |
| double | x_min |
| Minimum x value in plane coordinates. | |
| double | y_min |
| Minimum y value in plane coordinates. | |
| Point | __leftmost |
| Point with minimum x-coordinate. | |
| Point | __rightmost |
| Point with maximum x-coordinate. | |
| Point | __highest |
| Point with maximum y-coordinate. | |
| Point | __lowest |
| Point with minimum y-coordinate. | |
| bool | with_cartesian_axis |
| Flag to draw Cartesian axes. | |
| double | r |
| Actual radius in real points for drawing a point. | |
| double | resolution |
| Resolution in millimeters (default: 0.05mm) | |
| std::string | fill_type |
| Fill type for shapes (e.g., "black") | |
| std::string | shade_type |
| Shading type for segments. | |
| double | shade_thickness |
| Current shading thickness. | |
Static Private Attributes | |
| static const double | default_r = 20 |
| Default radius for drawing points (also used for text height) | |
| static const double | normal_thickness = 20 |
| Default line thickness. | |
| static const double | default_shade_thickness = 200 |
| Default shading thickness. | |
| static const double | dotgap = 65 |
| Gap between dots in dotted lines. | |
2D canvas for generating EEPIC/LaTeX picture environments.
Eepic_Plane serves as a container for geometric objects and handles the transformation from geometric coordinates to EEPIC picture coordinates. It generates a complete LaTeX picture environment that can be included in any LaTeX document with the eepic package.
The plane maintains two coordinate systems:
The transformation between these systems handles:
The class provides primitive drawing methods for:
Definition at line 249 of file eepicgeom.H.
| typedef void(Eepic_Plane::* Eepic_Plane::Draw_Segment_Fct) (const Segment &poly, std::ostream &output) |
Definition at line 836 of file eepicgeom.H.
|
inline |
Construct a plane with a fixed picture frame.
| __wide | Picture width. |
| __height | Picture height. |
| __xoffset | X offset for the LaTeX picture environment. |
| __yoffset | Y offset for the LaTeX picture environment. |
Definition at line 544 of file eepicgeom.H.
|
inline |
Destructor: deletes all stored Eepic_Geom_Object clones.
Definition at line 557 of file eepicgeom.H.
References Aleph::Dlink::is_empty(), list, Aleph::maps(), and Aleph::DynDlist< T >::remove_first_ne().
|
inline |
Linear scan over all objects to compute extreme points.
Definition at line 364 of file eepicgeom.H.
References __highest, __leftmost, __lowest, __rightmost, Aleph::DynDlist< T >::Iterator::get_curr(), Aleph::Dlink::Iterator::has_curr(), Eepic_Geom_Object::highest_point(), Eepic_Geom_Object::leftmost_point(), list, Eepic_Geom_Object::lowest_point(), Aleph::DynDlist< T >::Iterator::next(), Aleph::DynDlist< T >::Iterator::next_ne(), and Eepic_Geom_Object::rightmost_point().
Referenced by compute_geom_plane().
Compute extreme coordinates and derive width/height of all objects.
If squarize is true, rescaling preserves aspect ratio (no distortion).
Definition at line 406 of file eepicgeom.H.
References __highest, __leftmost, __lowest, __rightmost, compute_extreme_points(), geom_height, geom_number_to_double(), geom_wide, geom_x_min, geom_y_min, h_geom_number_to_eepic(), height, Aleph::maps(), real_height, real_wide, squarize, v_geom_number_to_eepic(), wide, x_geom_number_to_eepic(), x_min, y_geom_number_to_eepic(), and y_min.
Referenced by draw().
Emits a complete LaTeX picture environment containing the geometric objects.
If squarize == false, objects are scaled independently in x/y to fit exactly in the plane defined at construction time.
If squarize == true, aspect ratio is preserved (no distortion) but the available space may be used less efficiently.
Definition at line 475 of file eepicgeom.H.
References __highest, __leftmost, __lowest, __rightmost, compute_geom_plane(), Eepic_Geom_Object::draw(), draw_cartesian_axis(), fill_type, Aleph::Dlink::Iterator::has_curr(), list, output, point_string(), real_height, real_wide, resolution, Aleph::DynDlist< T >::size(), squarize, xoffset, and yoffset.
Referenced by generate_picture(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), and TEST().
Emit EEPIC code to draw segment sg with an arrow head.
Definition at line 731 of file eepicgeom.H.
References DRAW_ARROW, and output.
Referenced by Eepic_Arrow::draw(), Eepic_Thick_Arrow::draw(), and draw_cartesian_axis().
Emit EEPIC code to draw dashed segment sg with arrow head.
Definition at line 805 of file eepicgeom.H.
References DRAW_ARROW_DASH_SEGMENT, and output.
Referenced by Eepic_Dash_Arrow::draw(), and Eepic_Thick_Dash_Arrow::draw().
Emit EEPIC code to draw dotted segment sg with arrow head.
Definition at line 786 of file eepicgeom.H.
References DRAW_ARROW_DOTTED_SEGMENT, and output.
Referenced by Eepic_Dotted_Arrow::draw().
Definition at line 895 of file eepicgeom.H.
References COMPUTE_SEGMENT_EEPIC_COORDENATES, and PUT_ARROW.
Referenced by Eepic_Dash_Polygon_With_Arrow::draw(), Eepic_Thick_Dash_Polygon_With_Arrow::draw(), draw_arrows_in_polygon(), draw_dash_spline_arrow(), and draw_spline_arrow().
Definition at line 903 of file eepicgeom.H.
References draw_arrow_extreme(), and output.
Referenced by Eepic_Shade_Polygon_With_Arrows::draw(), Eepic_Thick_Shade_Polygon_With_Arrows::draw(), Eepic_Shade_Regular_Polygon_With_Arrows::draw(), and draw_closed_polygon_with_arrows().
|
private |
Definition at line 243 of file eepicgeom.C.
References __highest, __leftmost, __lowest, __rightmost, draw_arrow(), Aleph::maps(), output, and with_cartesian_axis.
Referenced by draw().
Definition at line 855 of file eepicgeom.H.
References output, and point_string().
Referenced by Eepic_Shade_Polygon::draw(), Eepic_Shade_Polygon_With_Points::draw(), Eepic_Shade_Polygon_With_Arrows::draw(), Eepic_Shade_Polygon_With_Text_Points::draw(), Eepic_Shade_Polygon_With_Vertex_Numbers::draw(), Eepic_Thick_Shade_Polygon::draw(), Eepic_Thick_Shade_Polygon_With_Points::draw(), Eepic_Thick_Shade_Polygon_With_Arrows::draw(), Eepic_Thick_Shade_Polygon_With_Text_Points::draw(), Eepic_Thick_Shade_Polygon_With_Vertex_Numbers::draw(), Eepic_Shade_Regular_Polygon::draw(), Eepic_Shade_Regular_Polygon_With_Points::draw(), Eepic_Shade_Regular_Polygon_With_Arrows::draw(), Eepic_Shade_Regular_Polygon_With_Text_Points::draw(), Eepic_Shade_Regular_Polygon_With_Vertex_Numbers::draw(), and draw_closed_polygon_with_arrows().
Definition at line 914 of file eepicgeom.H.
References draw_arrows_in_polygon(), draw_closed_polygon(), and output.
Referenced by Eepic_Polygon_With_Arrows::draw(), and Eepic_Thick_Polygon_With_Arrows::draw().
Emit EEPIC code to draw dashed segment sg.
Definition at line 767 of file eepicgeom.H.
References DRAW_DASH_SEGMENT, and output.
Referenced by Eepic_Thick_Dash_Segment::draw(), Eepic_Dash_Segment::draw(), Eepic_Dash_Polygon::draw(), Eepic_Dash_Polygon_With_Points::draw(), Eepic_Dash_Polygon_With_Arrow::draw(), Eepic_Thick_Dash_Polygon::draw(), Eepic_Thick_Dash_Polygon_With_Points::draw(), Eepic_Thick_Dash_Polygon_With_Arrow::draw(), Eepic_Dash_Regular_Polygon::draw(), and Eepic_Dash_Regular_Polygon_With_Points::draw().
Definition at line 987 of file eepicgeom.H.
References output, and point_string().
Referenced by Eepic_Dash_Spline::draw(), Eepic_Thick_Dash_Spline::draw(), and draw_dash_spline_arrow().
Definition at line 1013 of file eepicgeom.H.
References draw_arrow_extreme(), draw_dash_spline(), and output.
Referenced by Eepic_Dash_Spline_Arrow::draw(), and Eepic_Thick_Dash_Spline_Arrow::draw().
Definition at line 884 of file eepicgeom.H.
References draw_point(), and output.
Referenced by Eepic_Polygon_With_Points::draw(), Eepic_Dotted_Polygon_With_Points::draw(), Eepic_Dash_Polygon_With_Points::draw(), Eepic_Shade_Polygon_With_Points::draw(), Eepic_Thick_Polygon_With_Points::draw(), Eepic_Thick_Dotted_Polygon_With_Points::draw(), Eepic_Thick_Dash_Polygon_With_Points::draw(), Eepic_Thick_Shade_Polygon_With_Points::draw(), Eepic_Regular_Polygon_With_Points::draw(), Eepic_Dotted_Regular_Polygon_With_Points::draw(), Eepic_Dash_Regular_Polygon_With_Points::draw(), and Eepic_Shade_Regular_Polygon_With_Points::draw().
Definition at line 870 of file eepicgeom.H.
References dotgap, output, and point_string().
Emit EEPIC code to draw dotted segment sg.
Definition at line 749 of file eepicgeom.H.
References DRAW_DOTTED_SEGMENT, and output.
Referenced by Eepic_Dotted_Segment::draw(), Eepic_Dotted_Polygon::draw(), Eepic_Dotted_Polygon_With_Points::draw(), Eepic_Thick_Dotted_Polygon::draw(), Eepic_Thick_Dotted_Polygon_With_Points::draw(), Eepic_Dotted_Regular_Polygon::draw(), and Eepic_Dotted_Regular_Polygon_With_Points::draw().
Emit EEPIC code to draw ellipse e.
Definition at line 811 of file eepicgeom.H.
References Ellipse::get_center(), Ellipse::get_hradius(), Ellipse::get_vradius(), h_geom_number_to_eepic(), hd, output, v_geom_number_to_eepic(), vd, x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by Eepic_Ellipse::draw(), Eepic_Shade_Ellipse::draw(), and Eepic_Thick_Ellipse::draw().
EEPIC "primitive drawing" methods.
The draw() method of each Eepic_* wrapper may call one (or more) of these primitives. They are also callable by users (at their own risk).
This family of primitives assumes that the extreme points required to map geometric coordinates into EEPIC coordinates were already computed by compute_geom_plane(). Emit EEPIC code to draw point p into output.
Definition at line 644 of file eepicgeom.H.
References output, r, x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by Eepic_Point::draw(), and draw_dots_from_polygon().
Definition at line 921 of file eepicgeom.H.
References output, r, x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by draw_points_text_in_polygon().
Definition at line 940 of file eepicgeom.H.
References draw_point_text(), and output.
Referenced by Eepic_Shade_Polygon_With_Text_Points::draw(), Eepic_Thick_Shade_Polygon_With_Text_Points::draw(), and Eepic_Shade_Regular_Polygon_With_Text_Points::draw().
|
inline |
Definition at line 844 of file eepicgeom.H.
References Aleph::maps(), and output.
Referenced by Eepic_Polygon::draw(), Eepic_Polygon_With_Points::draw(), Eepic_Dotted_Polygon::draw(), Eepic_Dash_Polygon::draw(), Eepic_Dotted_Polygon_With_Points::draw(), Eepic_Dash_Polygon_With_Points::draw(), Eepic_Dash_Polygon_With_Arrow::draw(), Eepic_Thick_Polygon_With_Points::draw(), Eepic_Thick_Dotted_Polygon::draw(), Eepic_Thick_Dash_Polygon::draw(), Eepic_Thick_Dotted_Polygon_With_Points::draw(), Eepic_Thick_Dash_Polygon_With_Points::draw(), Eepic_Thick_Dash_Polygon_With_Arrow::draw(), Eepic_Regular_Polygon::draw(), Eepic_Regular_Polygon_With_Points::draw(), Eepic_Dotted_Regular_Polygon::draw(), Eepic_Dash_Regular_Polygon::draw(), Eepic_Dotted_Regular_Polygon_With_Points::draw(), and Eepic_Dash_Regular_Polygon_With_Points::draw().
Emit EEPIC code to draw segment sg.
Definition at line 679 of file eepicgeom.H.
References DRAW_SEGMENT, and output.
Referenced by Eepic_Segment::draw(), Eepic_Thick_Segment::draw(), Eepic_Polygon::draw(), Eepic_Polygon_With_Points::draw(), Eepic_Thick_Polygon_With_Points::draw(), Eepic_Regular_Polygon::draw(), and Eepic_Regular_Polygon_With_Points::draw().
Definition at line 972 of file eepicgeom.H.
References output, and point_string().
Referenced by Eepic_Spline::draw(), Eepic_Thick_Spline::draw(), and draw_spline_arrow().
Definition at line 1002 of file eepicgeom.H.
References draw_arrow_extreme(), draw_spline(), and output.
Referenced by Eepic_Spline_Arrow::draw(), and Eepic_Thick_Spline_Arrow::draw().
|
inline |
Definition at line 1022 of file eepicgeom.H.
References Text::font_height_in_points, Text::font_width_in_points, Text::get_point(), Text::get_str(), Text::len(), Aleph::maps(), output, tiny_keys, x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by Eepic_Text::draw(), Eepic_Left_Text::draw(), Eepic_Right_Text::draw(), and Eepic_Center_Text::draw().
Definition at line 949 of file eepicgeom.H.
References output, r, x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by Eepic_Shade_Polygon_With_Vertex_Numbers::draw(), Eepic_Thick_Shade_Polygon_With_Vertex_Numbers::draw(), and Eepic_Shade_Regular_Polygon_With_Vertex_Numbers::draw().
|
inlineprivate |
Rescales a coordinate value p from a geometric scale geom_max into the plane scale max.
Formula: result = p * max / geom_max
Definition at line 306 of file eepicgeom.H.
References geom_number_to_double(), Aleph::maps(), and max().
Referenced by h_geom_number_to_eepic(), v_geom_number_to_eepic(), x_geom_number_to_eepic(), and y_geom_number_to_eepic().
|
inline |
Return the dot gap used for dotted/dashed lines.
Definition at line 631 of file eepicgeom.H.
References dotgap.
Radius used to draw points (also used as text baseline offset).
Definition at line 535 of file eepicgeom.H.
References r.
Return the current output resolution in millimeters.
Definition at line 613 of file eepicgeom.H.
References resolution.
|
inline |
Return the current shading thickness.
Definition at line 628 of file eepicgeom.H.
References shade_thickness.
Plane accessors.
Picture width (in EEPIC units).
Definition at line 523 of file eepicgeom.H.
References wide.
X offset of the LaTeX picture environment.
Definition at line 532 of file eepicgeom.H.
References xoffset.
Y offset of the LaTeX picture environment.
Definition at line 529 of file eepicgeom.H.
References yoffset.
|
inline |
Convert a geometric x proportion into plane units using wide.
Definition at line 338 of file eepicgeom.H.
References geom_number_to_plane(), geom_wide, and wide.
Referenced by compute_geom_plane(), and draw_ellipse().
Definition at line 449 of file eepicgeom.H.
References __leftmost.
Given point p, returns "(x,y)" in normalized plane coordinates.
Definition at line 458 of file eepicgeom.H.
References x_geom_number_to_eepic(), y, and y_geom_number_to_eepic().
Referenced by draw(), draw_closed_polygon(), draw_dash_spline(), draw_dotted_closed_polygon(), and draw_spline().
|
inline |
Design note: why Eepic_Plane stores Eepic_Geom_Object wrappers.
Eepic_Plane stores objects of type Eepic_Geom_Object. However, the goal is to let users work directly with objects derived from Geom_Object.
One approach would be to make Geom_Object highly polymorphic (virtual clone, virtual draw, virtual extreme points). This header avoids that for two reasons:
For that reason, this header defines an external helper: put_in_plane(plane, geom_obj), which:
For implementation simplicity, the insertion primitive is public, but its intended usage is indirect (via put_in_plane()). Insert an already-wrapped EEPIC drawable into the plane.
This method clones the input object (polymorphic copy via clone()) and stores it in the plane. Typical usage is through the helper put_in_plane(plane, geom_obj) which builds the right wrapper type.
| __eepic_geom_obj | An Eepic_Geom_Object wrapper to clone and store. |
Definition at line 599 of file eepicgeom.H.
References Aleph::DynDlist< T >::append(), list, and Aleph::maps().
|
inline |
Enable drawing Cartesian axes when calling draw().
Definition at line 564 of file eepicgeom.H.
References with_cartesian_axis.
Definition at line 451 of file eepicgeom.H.
References __rightmost.
Set the fill type used by LaTeX eepic (e.g., "black").
Definition at line 616 of file eepicgeom.H.
References fill_type, and Aleph::maps().
Set the output resolution in millimeters (unitlength = res mm).
Definition at line 607 of file eepicgeom.H.
References Aleph::maps(), and resolution.
Set the thickness used for shaded primitives.
Definition at line 622 of file eepicgeom.H.
References Aleph::maps(), and shade_thickness.
|
inline |
Convert a geometric y proportion into plane units using height.
Definition at line 344 of file eepicgeom.H.
References geom_height, geom_number_to_plane(), height, and y.
Referenced by compute_geom_plane(), and draw_ellipse().
|
inline |
Convert a geometric x coordinate into plane x coordinate.
Definition at line 350 of file eepicgeom.H.
References geom_number_to_plane(), geom_wide, wide, and xpic().
Referenced by compute_geom_plane(), Eepic_Triangle::draw(), draw_ellipse(), draw_point(), draw_point_text(), draw_text(), draw_vertex_numbers_in_polygon(), and point_string().
Points must be normalized to the plane size (in picture coordinates).
These routines normalize a coordinate with respect to the origin (x or y axis). Normalize to x-axis origin.
Definition at line 325 of file eepicgeom.H.
References x_min.
Referenced by x_geom_number_to_eepic().
|
inline |
Convert a geometric y coordinate into plane y coordinate.
Definition at line 356 of file eepicgeom.H.
References geom_height, geom_number_to_plane(), height, y, and ypic().
Referenced by compute_geom_plane(), Eepic_Triangle::draw(), draw_ellipse(), draw_point(), draw_point_text(), draw_text(), draw_vertex_numbers_in_polygon(), and point_string().
Normalize to y-axis origin.
Definition at line 331 of file eepicgeom.H.
Referenced by y_geom_number_to_eepic().
Scale the EEPIC plane in real points (zoom in/out).
Definition at line 395 of file eepicgeom.H.
References ah_domain_error_if, height, and wide.
Referenced by generate_picture(), TEST_F(), TEST_F(), and TEST_F().
|
private |
Point with maximum y-coordinate.
Definition at line 278 of file eepicgeom.H.
Referenced by compute_extreme_points(), compute_geom_plane(), draw(), draw_cartesian_axis(), and highest().
|
private |
Point with minimum x-coordinate.
Definition at line 276 of file eepicgeom.H.
Referenced by compute_extreme_points(), compute_geom_plane(), draw(), draw_cartesian_axis(), and leftmost().
|
private |
Point with minimum y-coordinate.
Definition at line 279 of file eepicgeom.H.
Referenced by compute_extreme_points(), compute_geom_plane(), draw(), draw_cartesian_axis(), and lowest().
|
private |
Point with maximum x-coordinate.
Definition at line 277 of file eepicgeom.H.
Referenced by compute_extreme_points(), compute_geom_plane(), draw(), draw_cartesian_axis(), and rightmost().
Definition at line 686 of file eepicgeom.H.
Definition at line 684 of file eepicgeom.H.
Default radius for drawing points (also used for text height)
Definition at line 284 of file eepicgeom.H.
Default shading thickness.
Definition at line 295 of file eepicgeom.H.
Gap between dots in dotted lines.
Definition at line 299 of file eepicgeom.H.
Referenced by draw_dotted_closed_polygon(), and get_dotgap().
|
private |
Fill type for shapes (e.g., "black")
Definition at line 291 of file eepicgeom.H.
Referenced by draw(), and set_fill_type().
|
private |
Height from lowest to highest point.
Definition at line 263 of file eepicgeom.H.
Referenced by compute_geom_plane(), v_geom_number_to_eepic(), and y_geom_number_to_eepic().
|
private |
Width from leftmost to rightmost point.
Definition at line 262 of file eepicgeom.H.
Referenced by compute_geom_plane(), h_geom_number_to_eepic(), and x_geom_number_to_eepic().
|
private |
Minimum x value in geometric coordinates.
Definition at line 267 of file eepicgeom.H.
Referenced by compute_geom_plane().
|
private |
Minimum y value in geometric coordinates.
Definition at line 268 of file eepicgeom.H.
Referenced by compute_geom_plane().
|
private |
Height in resolution points.
Definition at line 253 of file eepicgeom.H.
Referenced by compute_geom_plane(), get_height(), v_geom_number_to_eepic(), y_geom_number_to_eepic(), and zoom().
|
private |
List of geometric objects.
Definition at line 265 of file eepicgeom.H.
Referenced by ~Eepic_Plane(), compute_extreme_points(), draw(), and put().
Default line thickness.
Definition at line 294 of file eepicgeom.H.
|
private |
Actual radius in real points for drawing a point.
Definition at line 286 of file eepicgeom.H.
Referenced by draw_point(), draw_point_text(), draw_vertex_numbers_in_polygon(), and get_r().
|
private |
Actual height after scaling.
Definition at line 257 of file eepicgeom.H.
Referenced by compute_geom_plane(), and draw().
|
private |
Actual width after scaling.
Definition at line 256 of file eepicgeom.H.
Referenced by compute_geom_plane(), and draw().
|
private |
Resolution in millimeters (default: 0.05mm)
Definition at line 289 of file eepicgeom.H.
Referenced by draw(), get_resolution(), and set_resolution().
|
private |
Current shading thickness.
Definition at line 297 of file eepicgeom.H.
Referenced by get_shade_thickness(), and set_shade_thickness().
|
private |
Shading type for segments.
Definition at line 292 of file eepicgeom.H.
|
private |
Width in resolution points.
Definition at line 252 of file eepicgeom.H.
Referenced by compute_geom_plane(), get_wide(), h_geom_number_to_eepic(), x_geom_number_to_eepic(), and zoom().
|
private |
Flag to draw Cartesian axes.
Definition at line 281 of file eepicgeom.H.
Referenced by draw_cartesian_axis(), and put_cartesian_axis().
|
private |
Minimum x value in plane coordinates.
Definition at line 272 of file eepicgeom.H.
Referenced by compute_geom_plane(), and xpic().
|
private |
Additional horizontal margin.
Definition at line 259 of file eepicgeom.H.
Referenced by draw(), and get_xoffset().
|
private |
Minimum y value in plane coordinates.
Definition at line 273 of file eepicgeom.H.
Referenced by compute_geom_plane(), and ypic().
|
private |
Additional vertical margin.
Definition at line 260 of file eepicgeom.H.
Referenced by draw(), and get_yoffset().