diff options
author | Chris Sherlock <chris.sherlock79@gmail.com> | 2016-01-13 12:13:12 +1100 |
---|---|---|
committer | Chris Sherlock <chris.sherlock79@gmail.com> | 2016-01-13 05:55:22 +0000 |
commit | bfd690701ff414496ad77c2b268bf7200947dc3a (patch) | |
tree | a25a8235d0c226a408e3f755878b88eeb8877597 /vcl/inc/impfont.hxx | |
parent | 78efa95b8088f7e23a77d7a746186ae2ecd0055c (diff) |
vcl: Create accessor and mutator for full stop centered in FontMetric
Accessor and mutator created for full stop centered flag, removed
bit field.
See commit description in 8bfccd3a71d911b6d ("vcl: Create accessor
and mutator for font scaling in FontMetric") for reasoning behind
patch.
Unit tests
- check to ensure that can set full stop centered flag
- check equality operator on FontMetric after setting full stop
centered flag
Change-Id: I9cacb0fbf9ea65cfebcaebdc9f0481c0a796cbcf
Reviewed-on: https://gerrit.libreoffice.org/21413
Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
Diffstat (limited to 'vcl/inc/impfont.hxx')
-rw-r--r-- | vcl/inc/impfont.hxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/vcl/inc/impfont.hxx b/vcl/inc/impfont.hxx index 376c0cb16ed5..5367a77f8a21 100644 --- a/vcl/inc/impfont.hxx +++ b/vcl/inc/impfont.hxx @@ -105,6 +105,7 @@ private: sal_uInt32 mnRefCount; // Reference Counter bool mbScalableFont; + bool mbFullstopCentered; // TODO: As these are progressively moved from bit fields into boolean variables, comment them out. // Eventually this enum will not be needed and we can remove it. @@ -113,8 +114,8 @@ private: /* SCALABLE_FLAG=2, */ LATIN_FLAG=4, CJK_FLAG=8, - CTL_FLAG=16, - FULLSTOP_CENTERED_FLAG=32 + CTL_FLAG=16 + /* FULLSTOP_CENTERED_FLAG=32 */ }; public: @@ -131,12 +132,13 @@ public: long GetExtLeading() const { return mnExtLeading; } long GetLineHeight() const { return mnLineHeight; } long GetSlant() const { return mnSlant; } + long GetBulletOffset() const { return mnBulletOffset; } bool IsScalable() const { return mbScalableFont; } - bool IsFullstopCentered() const { return ((mnMiscFlags & FULLSTOP_CENTERED_FLAG ) != 0); } - long GetBulletOffset() const { return mnBulletOffset; } + bool IsFullstopCentered() const { return mbFullstopCentered; } void SetScalableFlag(bool bScalable) { mbScalableFont = bScalable; } + void SetFullstopCenteredFlag(bool bCentered) { mbFullstopCentered = bCentered; } }; |