From 51d50d61fdee6a243ea1e2ec120560ae29c769e6 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Tue, 27 Mar 2018 19:35:14 +0000 Subject: Cleanup some CFDE_Data structs Change-Id: I9bf8d55d7d3624210cd54bc93db2c3671bec3a8f Reviewed-on: https://pdfium-review.googlesource.com/29270 Reviewed-by: Henrique Nakashima Commit-Queue: dsinclair --- xfa/fde/cfde_data.h | 22 +++++----------------- xfa/fde/cfde_textout.h | 11 +++++++++++ 2 files changed, 16 insertions(+), 17 deletions(-) diff --git a/xfa/fde/cfde_data.h b/xfa/fde/cfde_data.h index d4ca63d071..ad0740e5da 100644 --- a/xfa/fde/cfde_data.h +++ b/xfa/fde/cfde_data.h @@ -17,9 +17,8 @@ enum class FDE_TextAlignment : uint8_t { }; struct FDE_TextStyle { - FDE_TextStyle() - : single_line_(false), line_wrap_(false), last_line_height_(false) {} - ~FDE_TextStyle() {} + FDE_TextStyle() = default; + ~FDE_TextStyle() = default; void Reset() { single_line_ = false; @@ -27,20 +26,9 @@ struct FDE_TextStyle { last_line_height_ = false; } - bool single_line_; - bool line_wrap_; - bool last_line_height_; -}; - -struct FDE_TTOPIECE { - FDE_TTOPIECE(); - FDE_TTOPIECE(const FDE_TTOPIECE& that); - ~FDE_TTOPIECE(); - - int32_t iStartChar; - int32_t iChars; - uint32_t dwCharStyles; - CFX_RectF rtPiece; + bool single_line_ = false; + bool line_wrap_ = false; + bool last_line_height_ = false; }; #endif // XFA_FDE_CFDE_DATA_H_ diff --git a/xfa/fde/cfde_textout.h b/xfa/fde/cfde_textout.h index 6b6878e07c..6e72f8c441 100644 --- a/xfa/fde/cfde_textout.h +++ b/xfa/fde/cfde_textout.h @@ -22,6 +22,17 @@ class CFGAS_GEFont; class CFX_RenderDevice; class CFX_TxtBreak; +struct FDE_TTOPIECE { + FDE_TTOPIECE(); + FDE_TTOPIECE(const FDE_TTOPIECE& that); + ~FDE_TTOPIECE(); + + int32_t iStartChar; + int32_t iChars; + uint32_t dwCharStyles; + CFX_RectF rtPiece; +}; + class CFDE_TextOut { public: static bool DrawString(CFX_RenderDevice* device, -- cgit v1.2.3