1 // Copyright 2018 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 XFA_FDE_CFDE_DATA_H_ 8 #define XFA_FDE_CFDE_DATA_H_ 9 10 #include "core/fxcrt/fx_coordinates.h" 11 12 enum class FDE_TextAlignment : uint8_t { 13 kTopLeft = 0, 14 kCenterLeft, 15 kCenter, 16 kCenterRight 17 }; 18 19 struct FDE_TextStyle { FDE_TextStyleFDE_TextStyle20 FDE_TextStyle() 21 : single_line_(false), line_wrap_(false), last_line_height_(false) {} ~FDE_TextStyleFDE_TextStyle22 ~FDE_TextStyle() {} 23 ResetFDE_TextStyle24 void Reset() { 25 single_line_ = false; 26 line_wrap_ = false; 27 last_line_height_ = false; 28 } 29 30 bool single_line_; 31 bool line_wrap_; 32 bool last_line_height_; 33 }; 34 35 struct FDE_TTOPIECE { 36 FDE_TTOPIECE(); 37 FDE_TTOPIECE(const FDE_TTOPIECE& that); 38 ~FDE_TTOPIECE(); 39 40 int32_t iStartChar; 41 int32_t iChars; 42 uint32_t dwCharStyles; 43 CFX_RectF rtPiece; 44 }; 45 46 #endif // XFA_FDE_CFDE_DATA_H_ 47