#include <path.h>

Public Member Functions

 Path ()
 
void bezier_to (const Pointf &control, const Pointf &point)
 
void bezier_to (const Pointf &control1, const Pointf &control2, const Pointf &point)
 
Path clone () const
 
void close ()
 
void fill (Canvas &canvas, const Brush &brush)
 Fills a path.
 
void fill_and_stroke (Canvas &canvas, const Pen &pen, const Brush &brush)
 First fills a path, then strokes on top.
 
std::shared_ptr< PathImpl > get_impl () const
 
void line_to (const Pointf &point)
 
void line_to (float x, float y)
 
void move_to (const Pointf &point)
 
void move_to (float x, float y)
 
void operator+= (const Path &path)
 += operator to concatenate a path onto this path.
 
void set_fill_mode (PathFillMode fill_mode)
 
void stroke (Canvas &canvas, const Pen &pen)
 Strokes a path.
 
Pathtransform_self (const Mat3f &transform)
 Transform this path.
 

Static Public Member Functions

static Path circle (const Pointf &center, float radius)
 
static Path circle (float center_x, float center_y, float radius)
 
static Path ellipse (const Pointf &center, const Sizef &radius)
 
static Path ellipse (float center_x, float center_y, float radius_x, float radius_y)
 
static Path glyph (Canvas &canvas, Font &font, unsigned int glyph, GlyphMetrics &out_metrics)
 
static Path line (const Pointf &start, const Pointf &end)
 
static Path line (float x1, float y1, float x2, float y2)
 
static Path rect (const Rectf &box)
 
static Path rect (const Rectf &box, const clan::Sizef &corner)
 
static Path rect (float x, float y, float width, float height)
 

Friends

class CanvasImpl
 

Constructor & Destructor Documentation

◆ Path()

clan::Path::Path ( )

Member Function Documentation

◆ bezier_to() [1/2]

void clan::Path::bezier_to ( const Pointf & control,
const Pointf & point )

◆ bezier_to() [2/2]

void clan::Path::bezier_to ( const Pointf & control1,
const Pointf & control2,
const Pointf & point )

◆ circle() [1/2]

static Path clan::Path::circle ( const Pointf & center,
float radius )
inlinestatic

References clan::center, and ellipse().

◆ circle() [2/2]

static Path clan::Path::circle ( float center_x,
float center_y,
float radius )
inlinestatic

References ellipse().

◆ clone()

Path clan::Path::clone ( ) const

◆ close()

void clan::Path::close ( )

◆ ellipse() [1/2]

static Path clan::Path::ellipse ( const Pointf & center,
const Sizef & radius )
static

◆ ellipse() [2/2]

static Path clan::Path::ellipse ( float center_x,
float center_y,
float radius_x,
float radius_y )
inlinestatic

References ellipse().

Referenced by circle(), circle(), and ellipse().

◆ fill()

void clan::Path::fill ( Canvas & canvas,
const Brush & brush )

Fills a path.

◆ fill_and_stroke()

void clan::Path::fill_and_stroke ( Canvas & canvas,
const Pen & pen,
const Brush & brush )

First fills a path, then strokes on top.

◆ get_impl()

std::shared_ptr< PathImpl > clan::Path::get_impl ( ) const
inline

◆ glyph()

static Path clan::Path::glyph ( Canvas & canvas,
Font & font,
unsigned int glyph,
GlyphMetrics & out_metrics )
static

◆ line() [1/2]

static Path clan::Path::line ( const Pointf & start,
const Pointf & end )
static

Referenced by line().

◆ line() [2/2]

static Path clan::Path::line ( float x1,
float y1,
float x2,
float y2 )
inlinestatic

References line().

◆ line_to() [1/2]

void clan::Path::line_to ( const Pointf & point)

◆ line_to() [2/2]

void clan::Path::line_to ( float x,
float y )
inline

References line_to(), clan::x, and clan::y.

Referenced by line_to().

◆ move_to() [1/2]

void clan::Path::move_to ( const Pointf & point)

◆ move_to() [2/2]

void clan::Path::move_to ( float x,
float y )
inline

References move_to(), clan::x, and clan::y.

Referenced by move_to().

◆ operator+=()

void clan::Path::operator+= ( const Path & path)

+= operator to concatenate a path onto this path.

Useful when manually building complex paths from primitives

◆ rect() [1/3]

static Path clan::Path::rect ( const Rectf & box)
static

Referenced by rect().

◆ rect() [2/3]

static Path clan::Path::rect ( const Rectf & box,
const clan::Sizef & corner )
static

◆ rect() [3/3]

static Path clan::Path::rect ( float x,
float y,
float width,
float height )
inlinestatic

References rect(), clan::x, and clan::y.

◆ set_fill_mode()

void clan::Path::set_fill_mode ( PathFillMode fill_mode)

◆ stroke()

void clan::Path::stroke ( Canvas & canvas,
const Pen & pen )

Strokes a path.

◆ transform_self()

Path & clan::Path::transform_self ( const Mat3f & transform)

Transform this path.

Useful when manually building complex paths from primitives

Parameters
transform= Transform matrix
Returns
reference to this object

Friends And Related Symbol Documentation

◆ CanvasImpl

friend class CanvasImpl
friend

The documentation for this class was generated from the following file: