CGAL 5.2.1 - CGAL and the Qt Graphics View Framework
CGAL::Qt::Converter< K > Class Template Reference

#include <CGAL/Qt/Converter.h>

Definition

An object of type Converter converts 2D CGAL Kernel objects to their equivalent objects in Qt, and the other way round.

Note that some objects have no equivalent. For example the CGAL::Circle_2<K> cannot be converted to something in Qt, and the unbounded objects CGAL::Ray_2<K> and CGAL::Line_2<K> are clipped. Note also that CGAL and Qt sometimes also use the same word for different things. For example line denotes an unbounded line in CGAL, wheras it denotes a bounded segment in Qt.

Template Parameters
Kmust be a model of Kernel.

Creation

 Converter (QRectF clippingRect)
 The clipping rect is used for unbounded CGAL objects.
 

From CGAL to Qt

QRectF operator() (Bbox_2)
 Converts a bounding box.
 
QPointF operator() (K::Point_2)
 Converts a point.
 
QLineF operator() (K::Segment_2)
 Converts a segment.
 
QLineF operator() (K::Ray_2)
 Clips the ray and converts the resulting segment.
 
QLineF operator() (K::Line_2)
 Clips the line and converts the resulting segment.
 
QPolygonF operator() (K::Triangle_2)
 Converts a triangle.
 
QRectF operator() (K::Iso_rectangle_2)
 Converts an iso rectangle.
 
QPolygonF operator() (std::list< K::Point_2 >)
 Converts a list of points to a polygon.
 

From Qt to CGAL

K::Point_2 operator() (QPointF)
 Converts a point.
 
K::Segment_2 operator() (QLineF)
 Converts a segment.
 
K::Iso_rectangle_2 operator() (QRectF)
 Converts an iso rectangle.
 
std::list< K::Point_2 > operator() (QPolygonF)
 Converts a polygon to a list of points.