wxMaxima
Loading...
Searching...
No Matches
pdfshape.h
Go to the documentation of this file.
1
2// Name: pdfshape.h
3// Purpose:
4// Author: Ulrich Telle
5// Created: 2009-05-14
6// Copyright: (c) Ulrich Telle
7// Licence: wxWindows licence
9
11
12#ifndef _PDF_SHAPE_H_
13#define _PDF_SHAPE_H_
14
15// wxWidgets headers
16#include <wx/dynarray.h>
17
18// wxPdfDocument headers
19#include "wx/pdfdocdef.h"
20#include "wx/pdfarraydouble.h"
21
24{
25 wxPDF_SEG_UNDEFINED,
26 wxPDF_SEG_MOVETO,
27 wxPDF_SEG_LINETO,
28 wxPDF_SEG_CURVETO,
29 wxPDF_SEG_CLOSE
30};
31
33class WXDLLIMPEXP_PDFDOC wxPdfShape
34{
35public:
37 wxPdfShape();
38
40 virtual ~wxPdfShape();
41
43
50 void MoveTo(double x, double y);
51
53
59 void LineTo(double x, double y);
60
62
73 void CurveTo(double x1, double y1, double x2, double y2, double x3, double y3);
74
76
79 void ClosePath();
80
82
85 unsigned int GetSegmentCount() const { return (unsigned int) m_types.GetCount(); }
86
88
94 wxPdfSegmentType GetSegment(int iterType, int iterPoints, double coords[]) const;
95
96private:
97 wxArrayInt m_types;
98 wxPdfArrayDouble m_x;
99 wxPdfArrayDouble m_y;
100 int m_subpath;
101 int m_index;
102};
103
104#endif
Class representing a shape consisting of line and curve segments.
Definition: pdfshape.h:34
unsigned int GetSegmentCount() const
Get the number of segments of the shape.
Definition: pdfshape.h:85
Definition of array of type double.
Compile time switches for the wxPdfDocument component.
wxPdfSegmentType
Shape segment types.
Definition: pdfshape.h:24