OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #include "xfa/src/fde/fde_geobject.h" | 7 #include "xfa/fde/fde_geobject.h" |
8 | 8 |
9 #include "xfa/src/fde/fde_object.h" | 9 #include "xfa/fde/fde_object.h" |
10 | 10 |
11 IFDE_Path* IFDE_Path::Create() { | 11 IFDE_Path* IFDE_Path::Create() { |
12 return new CFDE_Path; | 12 return new CFDE_Path; |
13 } | 13 } |
14 FX_BOOL CFDE_Path::StartFigure() { | 14 FX_BOOL CFDE_Path::StartFigure() { |
15 return CloseFigure(); | 15 return CloseFigure(); |
16 } | 16 } |
17 FX_BOOL CFDE_Path::CloseFigure() { | 17 FX_BOOL CFDE_Path::CloseFigure() { |
18 FX_PATHPOINT* pPoint = GetLastPoint(); | 18 FX_PATHPOINT* pPoint = GetLastPoint(); |
19 if (pPoint) { | 19 if (pPoint) { |
(...skipping 226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
246 bbox.Set(rect.left, rect.top, rect.Width(), rect.Height()); | 246 bbox.Set(rect.left, rect.top, rect.Width(), rect.Height()); |
247 bbox.Normalize(); | 247 bbox.Normalize(); |
248 } | 248 } |
249 void CFDE_Path::GetBBox(CFX_RectF& bbox, | 249 void CFDE_Path::GetBBox(CFX_RectF& bbox, |
250 FX_FLOAT fLineWidth, | 250 FX_FLOAT fLineWidth, |
251 FX_FLOAT fMiterLimit) const { | 251 FX_FLOAT fMiterLimit) const { |
252 CFX_FloatRect rect = m_Path.GetBoundingBox(fLineWidth, fMiterLimit); | 252 CFX_FloatRect rect = m_Path.GetBoundingBox(fLineWidth, fMiterLimit); |
253 bbox.Set(rect.left, rect.top, rect.Width(), rect.Height()); | 253 bbox.Set(rect.left, rect.top, rect.Width(), rect.Height()); |
254 bbox.Normalize(); | 254 bbox.Normalize(); |
255 } | 255 } |
OLD | NEW |