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

Side by Side Diff: core/fpdfdoc/include/cpdf_variabletext.h

Issue 2060913003: Make code compile with clang_use_chrome_plugin (part II) (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: rebase Created 4 years, 6 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
« no previous file with comments | « core/fpdfdoc/doc_vt.cpp ('k') | core/fpdfdoc/include/cpvt_word.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 PDFium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_ 7 #ifndef CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_
8 #define CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_ 8 #define CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_
9 9
10 #include <memory> 10 #include <memory>
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 IPVT_FontMap* const m_pFontMap; 80 IPVT_FontMap* const m_pFontMap;
81 }; 81 };
82 82
83 CPDF_VariableText(); 83 CPDF_VariableText();
84 ~CPDF_VariableText() override; 84 ~CPDF_VariableText() override;
85 85
86 void SetProvider(CPDF_VariableText::Provider* pProvider); 86 void SetProvider(CPDF_VariableText::Provider* pProvider);
87 CPDF_VariableText::Iterator* GetIterator(); 87 CPDF_VariableText::Iterator* GetIterator();
88 88
89 // CPDF_EditContainer. 89 // CPDF_EditContainer.
90 void SetPlateRect(const CFX_FloatRect& rect) override { 90 void SetPlateRect(const CFX_FloatRect& rect) override;
91 CPDF_EditContainer::SetPlateRect(rect);
92 }
93 CFX_FloatRect GetContentRect() const override; 91 CFX_FloatRect GetContentRect() const override;
94 const CFX_FloatRect& GetPlateRect() const override { 92 const CFX_FloatRect& GetPlateRect() const override;
95 return CPDF_EditContainer::GetPlateRect();
96 }
97 93
98 void SetAlignment(int32_t nFormat = 0) { m_nAlignment = nFormat; } 94 void SetAlignment(int32_t nFormat = 0) { m_nAlignment = nFormat; }
99 void SetPasswordChar(uint16_t wSubWord = '*') { m_wSubWord = wSubWord; } 95 void SetPasswordChar(uint16_t wSubWord = '*') { m_wSubWord = wSubWord; }
100 void SetLimitChar(int32_t nLimitChar = 0) { m_nLimitChar = nLimitChar; } 96 void SetLimitChar(int32_t nLimitChar = 0) { m_nLimitChar = nLimitChar; }
101 void SetCharSpace(FX_FLOAT fCharSpace = 0.0f) { m_fCharSpace = fCharSpace; } 97 void SetCharSpace(FX_FLOAT fCharSpace = 0.0f) { m_fCharSpace = fCharSpace; }
102 void SetHorzScale(int32_t nHorzScale = 100) { m_nHorzScale = nHorzScale; } 98 void SetHorzScale(int32_t nHorzScale = 100) { m_nHorzScale = nHorzScale; }
103 void SetMultiLine(FX_BOOL bMultiLine = TRUE) { m_bMultiLine = bMultiLine; } 99 void SetMultiLine(FX_BOOL bMultiLine = TRUE) { m_bMultiLine = bMultiLine; }
104 void SetAutoReturn(FX_BOOL bAuto = TRUE) { m_bLimitWidth = bAuto; } 100 void SetAutoReturn(FX_BOOL bAuto = TRUE) { m_bLimitWidth = bAuto; }
105 void SetFontSize(FX_FLOAT fFontSize) { m_fFontSize = fFontSize; } 101 void SetFontSize(FX_FLOAT fFontSize) { m_fFontSize = fFontSize; }
106 void SetCharArray(int32_t nCharArray = 0) { m_nCharArray = nCharArray; } 102 void SetCharArray(int32_t nCharArray = 0) { m_nCharArray = nCharArray; }
107 void SetAutoFontSize(FX_BOOL bAuto = TRUE) { m_bAutoFontSize = bAuto; } 103 void SetAutoFontSize(FX_BOOL bAuto = TRUE) { m_bAutoFontSize = bAuto; }
108 void SetRichText(FX_BOOL bRichText) { m_bRichText = bRichText; } 104 void SetRichText(FX_BOOL bRichText) { m_bRichText = bRichText; }
109 void SetLineLeading(FX_FLOAT fLineLeading) { m_fLineLeading = fLineLeading; } 105 void SetLineLeading(FX_FLOAT fLineLeading) { m_fLineLeading = fLineLeading; }
110 void Initialize(); 106 void Initialize();
107
111 FX_BOOL IsValid() const { return m_bInitial; } 108 FX_BOOL IsValid() const { return m_bInitial; }
112 FX_BOOL IsRichText() const { return m_bRichText; } 109 FX_BOOL IsRichText() const { return m_bRichText; }
110
113 void RearrangeAll(); 111 void RearrangeAll();
114 void RearrangePart(const CPVT_WordRange& PlaceRange); 112 void RearrangePart(const CPVT_WordRange& PlaceRange);
115 void ResetAll(); 113 void ResetAll();
116 void SetText(const FX_WCHAR* text, 114 void SetText(const FX_WCHAR* text,
117 int32_t charset = 1, 115 int32_t charset = 1,
118 const CPVT_SecProps* pSecProps = nullptr, 116 const CPVT_SecProps* pSecProps = nullptr,
119 const CPVT_WordProps* pWordProps = nullptr); 117 const CPVT_WordProps* pWordProps = nullptr);
120 CPVT_WordPlace InsertWord(const CPVT_WordPlace& place, 118 CPVT_WordPlace InsertWord(const CPVT_WordPlace& place,
121 uint16_t word, 119 uint16_t word,
122 int32_t charset = 1, 120 int32_t charset = 1,
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 int32_t m_nHorzScale; 243 int32_t m_nHorzScale;
246 uint16_t m_wSubWord; 244 uint16_t m_wSubWord;
247 FX_FLOAT m_fFontSize; 245 FX_FLOAT m_fFontSize;
248 FX_BOOL m_bInitial; 246 FX_BOOL m_bInitial;
249 FX_BOOL m_bRichText; 247 FX_BOOL m_bRichText;
250 CPDF_VariableText::Provider* m_pVTProvider; 248 CPDF_VariableText::Provider* m_pVTProvider;
251 std::unique_ptr<CPDF_VariableText::Iterator> m_pVTIterator; 249 std::unique_ptr<CPDF_VariableText::Iterator> m_pVTIterator;
252 }; 250 };
253 251
254 #endif // CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_ 252 #endif // CORE_FPDFDOC_INCLUDE_CPDF_VARIABLETEXT_H_
OLDNEW
« no previous file with comments | « core/fpdfdoc/doc_vt.cpp ('k') | core/fpdfdoc/include/cpvt_word.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698