Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(509)

Side by Side Diff: core/fpdfapi/fpdf_page/include/cpdf_path.h

Issue 1811053002: Move core/include/fpdfapi/fpdf_pageobj.h into core/fpdfapi. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 PDFium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6
7 #ifndef CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_PATH_H_
8 #define CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_PATH_H_
9
10 #include "core/include/fxcrt/fx_system.h"
11 #include "core/include/fxge/fx_ge.h"
12
13 class CPDF_Path : public CFX_CountRef<CFX_PathData> {
14 public:
15 int GetPointCount() const { return m_pObject->m_PointCount; }
16 int GetFlag(int index) const { return m_pObject->m_pPoints[index].m_Flag; }
17
18 FX_FLOAT GetPointX(int index) const {
19 return m_pObject->m_pPoints[index].m_PointX;
20 }
21
22 FX_FLOAT GetPointY(int index) const {
23 return m_pObject->m_pPoints[index].m_PointY;
24 }
25
26 FX_PATHPOINT* GetPoints() const { return m_pObject->m_pPoints; }
27 CFX_FloatRect GetBoundingBox() const { return m_pObject->GetBoundingBox(); }
28
29 CFX_FloatRect GetBoundingBox(FX_FLOAT line_width,
30 FX_FLOAT miter_limit) const {
31 return m_pObject->GetBoundingBox(line_width, miter_limit);
32 }
33
34 FX_BOOL IsRect() const { return m_pObject->IsRect(); }
35
36 void Transform(const CFX_Matrix* pMatrix) { GetModify()->Transform(pMatrix); }
37
38 void Append(CPDF_Path src, const CFX_Matrix* pMatrix) {
39 m_pObject->Append(src.m_pObject, pMatrix);
40 }
41
42 void AppendRect(FX_FLOAT left,
43 FX_FLOAT bottom,
44 FX_FLOAT right,
45 FX_FLOAT top) {
46 m_pObject->AppendRect(left, bottom, right, top);
47 }
48 };
49
50 #endif // CORE_FPDFAPI_FPDF_PAGE_INCLUDE_CPDF_PATH_H_
OLDNEW
« no previous file with comments | « core/fpdfapi/fpdf_page/include/cpdf_pageobject.h ('k') | core/fpdfapi/fpdf_page/include/cpdf_pathobject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698