summaryrefslogtreecommitdiff
path: root/xfa/fxgraphics/cfx_path_generator.h
diff options
context:
space:
mode:
authordan sinclair <dsinclair@chromium.org>2017-02-22 19:56:15 -0500
committerChromium commit bot <commit-bot@chromium.org>2017-02-23 01:17:40 +0000
commitb147e07ee36be10ca0796a6566be107077c21a03 (patch)
tree637b1b206000a88fb3e198f648e86a9ee5178f1b /xfa/fxgraphics/cfx_path_generator.h
parente3f237740fd8bea50b4a6f37f56455dfa0328546 (diff)
downloadpdfium-b147e07ee36be10ca0796a6566be107077c21a03.tar.xz
Convert point x,y into CFX_PointF
This Cl converts the PointX,PointY pairs into a CFX_PointF. Change-Id: I46897832077c317a5bffb4e568550705decbc40c Reviewed-on: https://pdfium-review.googlesource.com/2821 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org> Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'xfa/fxgraphics/cfx_path_generator.h')
-rw-r--r--xfa/fxgraphics/cfx_path_generator.h47
1 files changed, 17 insertions, 30 deletions
diff --git a/xfa/fxgraphics/cfx_path_generator.h b/xfa/fxgraphics/cfx_path_generator.h
index 916400d529..d3ba290f1c 100644
--- a/xfa/fxgraphics/cfx_path_generator.h
+++ b/xfa/fxgraphics/cfx_path_generator.h
@@ -20,43 +20,30 @@ class CFX_PathGenerator {
void AddPathData(CFX_PathData* path_data);
- void MoveTo(FX_FLOAT x, FX_FLOAT y);
- void LineTo(FX_FLOAT x, FX_FLOAT y);
- void BezierTo(FX_FLOAT ctrl_x1,
- FX_FLOAT ctrl_y1,
- FX_FLOAT ctrl_x2,
- FX_FLOAT ctrl_y2,
- FX_FLOAT to_x,
- FX_FLOAT to_y);
+ void MoveTo(const CFX_PointF& point);
+ void LineTo(const CFX_PointF& point);
+ void BezierTo(const CFX_PointF& c1,
+ const CFX_PointF& c2,
+ const CFX_PointF& to);
void Close();
- void ArcTo(FX_FLOAT x,
- FX_FLOAT y,
- FX_FLOAT width,
- FX_FLOAT height,
+ void ArcTo(const CFX_PointF& point,
+ const CFX_SizeF& size,
FX_FLOAT start_angle,
FX_FLOAT sweep_angle);
- void AddLine(FX_FLOAT x1, FX_FLOAT y1, FX_FLOAT x2, FX_FLOAT y2);
- void AddBezier(FX_FLOAT start_x,
- FX_FLOAT start_y,
- FX_FLOAT ctrl_x1,
- FX_FLOAT ctrl_y1,
- FX_FLOAT ctrl_x2,
- FX_FLOAT ctrl_y2,
- FX_FLOAT end_x,
- FX_FLOAT end_y);
+ void AddLine(const CFX_PointF& p1, const CFX_PointF& p2);
+ void AddBezier(const CFX_PointF& p1,
+ const CFX_PointF& c1,
+ const CFX_PointF& c2,
+ const CFX_PointF& p2);
void AddRectangle(FX_FLOAT x1, FX_FLOAT y1, FX_FLOAT x2, FX_FLOAT y2);
- void AddEllipse(FX_FLOAT x, FX_FLOAT y, FX_FLOAT width, FX_FLOAT height);
- void AddArc(FX_FLOAT x,
- FX_FLOAT y,
- FX_FLOAT width,
- FX_FLOAT height,
+ void AddEllipse(const CFX_PointF& point, const CFX_SizeF& size);
+ void AddArc(const CFX_PointF& point,
+ const CFX_SizeF& size,
FX_FLOAT start_angle,
FX_FLOAT sweep_angle);
- void AddPie(FX_FLOAT x,
- FX_FLOAT y,
- FX_FLOAT width,
- FX_FLOAT height,
+ void AddPie(const CFX_PointF& point,
+ const CFX_SizeF& size,
FX_FLOAT start_angle,
FX_FLOAT sweep_angle);