OLD | NEW |
(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_FPDFDOC_INCLUDE_CPDF_DEFAULTAPPEARANCE_H_ |
| 8 #define CORE_FPDFDOC_INCLUDE_CPDF_DEFAULTAPPEARANCE_H_ |
| 9 |
| 10 #include "core/fpdfdoc/include/cpdf_defaultappearance.h" |
| 11 #include "core/fxcrt/include/fx_coordinates.h" |
| 12 #include "core/fxcrt/include/fx_string.h" |
| 13 #include "core/fxcrt/include/fx_system.h" |
| 14 #include "core/fxge/include/fx_dib.h" |
| 15 |
| 16 enum class BorderStyle { SOLID, DASH, BEVELED, INSET, UNDERLINE }; |
| 17 |
| 18 class CPDF_DefaultAppearance { |
| 19 public: |
| 20 CPDF_DefaultAppearance() {} |
| 21 explicit CPDF_DefaultAppearance(const CFX_ByteString& csDA) : m_csDA(csDA) {} |
| 22 |
| 23 CPDF_DefaultAppearance(const CPDF_DefaultAppearance& cDA) { |
| 24 m_csDA = cDA.GetStr(); |
| 25 } |
| 26 |
| 27 CFX_ByteString GetStr() const { return m_csDA; } |
| 28 |
| 29 FX_BOOL HasFont(); |
| 30 CFX_ByteString GetFontString(); |
| 31 void GetFont(CFX_ByteString& csFontNameTag, FX_FLOAT& fFontSize); |
| 32 |
| 33 FX_BOOL HasColor(FX_BOOL bStrokingOperation = FALSE); |
| 34 CFX_ByteString GetColorString(FX_BOOL bStrokingOperation = FALSE); |
| 35 void GetColor(int& iColorType, |
| 36 FX_FLOAT fc[4], |
| 37 FX_BOOL bStrokingOperation = FALSE); |
| 38 void GetColor(FX_ARGB& color, |
| 39 int& iColorType, |
| 40 FX_BOOL bStrokingOperation = FALSE); |
| 41 |
| 42 FX_BOOL HasTextMatrix(); |
| 43 CFX_ByteString GetTextMatrixString(); |
| 44 CFX_Matrix GetTextMatrix(); |
| 45 |
| 46 private: |
| 47 CFX_ByteString m_csDA; |
| 48 }; |
| 49 |
| 50 #endif // CORE_FPDFDOC_INCLUDE_CPDF_DEFAULTAPPEARANCE_H_ |
OLD | NEW |