summaryrefslogtreecommitdiff
path: root/core/include/fpdfdoc/fpdf_ap.h
diff options
context:
space:
mode:
authorJohn Abd-El-Malek <jabdelmalek@google.com>2014-05-23 17:28:10 -0700
committerJohn Abd-El-Malek <jabdelmalek@google.com>2014-05-23 17:41:56 -0700
commit3f3b45cc74b0499912409f766a595945dbbfc4c5 (patch)
treeec400b6965477b88ea7f0d335f7e5c52044c346c /core/include/fpdfdoc/fpdf_ap.h
parent6fe4aed948337175f6f7f81bb03c37b9c7f535da (diff)
downloadpdfium-3f3b45cc74b0499912409f766a595945dbbfc4c5.tar.xz
Convert all line endings to LF.
Diffstat (limited to 'core/include/fpdfdoc/fpdf_ap.h')
-rw-r--r--core/include/fpdfdoc/fpdf_ap.h184
1 files changed, 92 insertions, 92 deletions
diff --git a/core/include/fpdfdoc/fpdf_ap.h b/core/include/fpdfdoc/fpdf_ap.h
index 4b6a371110..c2299fc0fc 100644
--- a/core/include/fpdfdoc/fpdf_ap.h
+++ b/core/include/fpdfdoc/fpdf_ap.h
@@ -1,92 +1,92 @@
-// Copyright 2014 PDFium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
-
-#define _FPDF_AP_H_
-#include "../fxcrt/fx_basic.h"
-#include "../fpdfapi/fpdf_parser.h"
-#include "fpdf_vt.h"
-class IPVT_FontMap
-{
-public:
-
- virtual CPDF_Font* GetPDFFont(FX_INT32 nFontIndex) = 0;
-
- virtual CFX_ByteString GetPDFFontAlias(FX_INT32 nFontIndex) = 0;
-};
-struct CPVT_Dash {
-
- CPVT_Dash(FX_INT32 dash, FX_INT32 gap, FX_INT32 phase) : nDash(dash), nGap(gap), nPhase(phase)
- {}
-
- FX_INT32 nDash;
-
- FX_INT32 nGap;
-
- FX_INT32 nPhase;
-};
-#define CT_TRANSPARENT 0
-#define CT_GRAY 1
-#define CT_RGB 2
-#define CT_CMYK 3
-struct CPVT_Color {
-
- CPVT_Color(FX_INT32 type = 0, FX_FLOAT color1 = 0.0f, FX_FLOAT color2 = 0.0f, FX_FLOAT color3 = 0.0f, FX_FLOAT color4 = 0.0f)
- : nColorType(type), fColor1(color1), fColor2(color2), fColor3(color3), fColor4(color4)
- {}
-
- FX_INT32 nColorType;
- FX_FLOAT fColor1;
- FX_FLOAT fColor2;
- FX_FLOAT fColor3;
- FX_FLOAT fColor4;
-};
-class CPVT_Provider : public IPDF_VariableText_Provider
-{
-public:
-
- CPVT_Provider(IPVT_FontMap * pFontMap);
-
- virtual ~CPVT_Provider();
-
- FX_INT32 GetCharWidth(FX_INT32 nFontIndex, FX_WORD word, FX_INT32 nWordStyle);
-
- FX_INT32 GetTypeAscent(FX_INT32 nFontIndex);
-
- FX_INT32 GetTypeDescent(FX_INT32 nFontIndex);
-
- FX_INT32 GetWordFontIndex(FX_WORD word, FX_INT32 charset, FX_INT32 nFontIndex);
-
- FX_BOOL IsLatinWord(FX_WORD word);
-
- FX_INT32 GetDefaultFontIndex();
-private:
-
- IPVT_FontMap * m_pFontMap;
-};
-#define PBS_SOLID 0
-#define PBS_DASH 1
-#define PBS_BEVELED 2
-#define PBS_INSET 3
-#define PBS_UNDERLINED 4
-class CPVT_GenerateAP
-{
-public:
-
- static FX_BOOL GenerateTextFieldAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
-
- static FX_BOOL GenerateComboBoxAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
-
- static FX_BOOL GenerateListBoxAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
-
- static CFX_ByteString GenerateEditAP(IPVT_FontMap * pFontMap, IPDF_VariableText_Iterator * pIterator,
- const CPDF_Point & ptOffset, FX_BOOL bContinuous, FX_WORD SubWord = 0, const CPVT_WordRange * pVisible = NULL);
-
- static CFX_ByteString GenerateBorderAP(const CPDF_Rect & rect, FX_FLOAT fWidth,
- const CPVT_Color & color, const CPVT_Color & crLeftTop, const CPVT_Color & crRightBottom,
- FX_INT32 nStyle, const CPVT_Dash & dash);
-
- static CFX_ByteString GenerateColorAP(const CPVT_Color & color, const FX_BOOL & bFillOrStroke);
-};
+// Copyright 2014 PDFium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
+
+#define _FPDF_AP_H_
+#include "../fxcrt/fx_basic.h"
+#include "../fpdfapi/fpdf_parser.h"
+#include "fpdf_vt.h"
+class IPVT_FontMap
+{
+public:
+
+ virtual CPDF_Font* GetPDFFont(FX_INT32 nFontIndex) = 0;
+
+ virtual CFX_ByteString GetPDFFontAlias(FX_INT32 nFontIndex) = 0;
+};
+struct CPVT_Dash {
+
+ CPVT_Dash(FX_INT32 dash, FX_INT32 gap, FX_INT32 phase) : nDash(dash), nGap(gap), nPhase(phase)
+ {}
+
+ FX_INT32 nDash;
+
+ FX_INT32 nGap;
+
+ FX_INT32 nPhase;
+};
+#define CT_TRANSPARENT 0
+#define CT_GRAY 1
+#define CT_RGB 2
+#define CT_CMYK 3
+struct CPVT_Color {
+
+ CPVT_Color(FX_INT32 type = 0, FX_FLOAT color1 = 0.0f, FX_FLOAT color2 = 0.0f, FX_FLOAT color3 = 0.0f, FX_FLOAT color4 = 0.0f)
+ : nColorType(type), fColor1(color1), fColor2(color2), fColor3(color3), fColor4(color4)
+ {}
+
+ FX_INT32 nColorType;
+ FX_FLOAT fColor1;
+ FX_FLOAT fColor2;
+ FX_FLOAT fColor3;
+ FX_FLOAT fColor4;
+};
+class CPVT_Provider : public IPDF_VariableText_Provider
+{
+public:
+
+ CPVT_Provider(IPVT_FontMap * pFontMap);
+
+ virtual ~CPVT_Provider();
+
+ FX_INT32 GetCharWidth(FX_INT32 nFontIndex, FX_WORD word, FX_INT32 nWordStyle);
+
+ FX_INT32 GetTypeAscent(FX_INT32 nFontIndex);
+
+ FX_INT32 GetTypeDescent(FX_INT32 nFontIndex);
+
+ FX_INT32 GetWordFontIndex(FX_WORD word, FX_INT32 charset, FX_INT32 nFontIndex);
+
+ FX_BOOL IsLatinWord(FX_WORD word);
+
+ FX_INT32 GetDefaultFontIndex();
+private:
+
+ IPVT_FontMap * m_pFontMap;
+};
+#define PBS_SOLID 0
+#define PBS_DASH 1
+#define PBS_BEVELED 2
+#define PBS_INSET 3
+#define PBS_UNDERLINED 4
+class CPVT_GenerateAP
+{
+public:
+
+ static FX_BOOL GenerateTextFieldAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
+
+ static FX_BOOL GenerateComboBoxAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
+
+ static FX_BOOL GenerateListBoxAP(CPDF_Document* pDoc, CPDF_Dictionary* pAnnotDict);
+
+ static CFX_ByteString GenerateEditAP(IPVT_FontMap * pFontMap, IPDF_VariableText_Iterator * pIterator,
+ const CPDF_Point & ptOffset, FX_BOOL bContinuous, FX_WORD SubWord = 0, const CPVT_WordRange * pVisible = NULL);
+
+ static CFX_ByteString GenerateBorderAP(const CPDF_Rect & rect, FX_FLOAT fWidth,
+ const CPVT_Color & color, const CPVT_Color & crLeftTop, const CPVT_Color & crRightBottom,
+ FX_INT32 nStyle, const CPVT_Dash & dash);
+
+ static CFX_ByteString GenerateColorAP(const CPVT_Color & color, const FX_BOOL & bFillOrStroke);
+};