summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Sherlock <chris.sherlock79@gmail.com>2016-01-04 16:06:13 +1100
committerChris Sherlock <chris.sherlock79@gmail.com>2016-01-04 06:26:18 +0000
commit21f152a52397bf99364e5dc5ba9519e11452f260 (patch)
tree95f833cc83a2f91949e8bd96f8a02a320a1c9916
parentf4dc8a869ac49f19c20fc5fa606448e9103726bd (diff)
vcl: split classes out of metric.hxx
Change-Id: Id3b155abec7b7a2ff43d0a35e98709f5ee51c6b9 Reviewed-on: https://gerrit.libreoffice.org/21069 Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com> Tested-by: Chris Sherlock <chris.sherlock79@gmail.com>
-rw-r--r--cui/source/dialogs/cuicharmap.cxx1
-rw-r--r--include/vcl/fontcharmap.hxx169
-rw-r--r--include/vcl/metric.hxx161
-rw-r--r--include/vcl/textrectinfo.hxx57
-rw-r--r--sc/source/filter/excel/xistyle.cxx1
-rw-r--r--starmath/source/dialog.cxx1
-rw-r--r--svtools/source/misc/sampletext.cxx1
-rw-r--r--svx/source/dialog/charmap.cxx1
-rw-r--r--vcl/generic/fontmanager/fontmanager.cxx1
-rw-r--r--vcl/generic/glyphs/gcach_ftyp.cxx3
-rw-r--r--vcl/generic/print/genpspgraphics.cxx1
-rw-r--r--vcl/headless/svptext.cxx1
-rw-r--r--vcl/inc/win/salgdi.h1
-rw-r--r--vcl/qa/cppunit/fontcharmap.cxx2
-rw-r--r--vcl/quartz/salgdi.cxx1
-rw-r--r--vcl/source/filter/wmf/wmfwr.cxx1
-rw-r--r--vcl/source/gdi/impfont.cxx2
-rw-r--r--vcl/source/outdev/font.cxx1
-rw-r--r--vcl/source/outdev/text.cxx1
-rw-r--r--vcl/source/window/brdwin.cxx1
-rw-r--r--vcl/source/window/msgbox.cxx1
-rw-r--r--vcl/unx/generic/gdi/cairotextrender.cxx1
-rw-r--r--vcl/unx/generic/gdi/salgdi3.cxx1
-rw-r--r--vcl/win/gdi/salfont.cxx1
24 files changed, 249 insertions, 163 deletions
diff --git a/cui/source/dialogs/cuicharmap.cxx b/cui/source/dialogs/cuicharmap.cxx
index 62346d850cea..ee26bca6d980 100644
--- a/cui/source/dialogs/cuicharmap.cxx
+++ b/cui/source/dialogs/cuicharmap.cxx
@@ -31,6 +31,7 @@
#include <vcl/msgbox.hxx>
#include <vcl/settings.hxx>
#include <vcl/builderfactory.hxx>
+#include <vcl/fontcharmap.hxx>
#include <svl/stritem.hxx>
#include <cuires.hrc>
diff --git a/include/vcl/fontcharmap.hxx b/include/vcl/fontcharmap.hxx
new file mode 100644
index 000000000000..c4d495c368fd
--- /dev/null
+++ b/include/vcl/fontcharmap.hxx
@@ -0,0 +1,169 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef INCLUDED_FONTCHARMAP_METRIC_HXX
+#define INCLUDED_FONTCHARMAP_METRIC_HXX
+
+#include <vcl/dllapi.h>
+#include <vcl/font.hxx>
+#include <vcl/outdev.hxx>
+
+#include <boost/intrusive_ptr.hpp>
+
+class ImplFontCharMap;
+class CmapResult;
+
+typedef sal_uInt32 sal_UCS4;
+typedef boost::intrusive_ptr< ImplFontCharMap > ImplFontCharMapPtr;
+typedef boost::intrusive_ptr< FontCharMap > FontCharMapPtr;
+
+class VCL_DLLPUBLIC FontCharMap
+{
+public:
+ /** A new FontCharMap is created based on a "default" map, which includes
+ all codepoints in the Unicode BMP range, including surrogates.
+ **/
+ FontCharMap();
+ FontCharMap( const CmapResult& rCR );
+ ~FontCharMap();
+
+ /** Get the default font character map
+
+ @returns the default font character map.
+ */
+ static FontCharMapPtr GetDefaultMap( bool bSymbols=false );
+
+ /** Determines if the font character map is the "default". The default map
+ includes all codepoints in the Unicode BMP range, including surrogates.
+
+ @returns true if default map, false if not default map.
+ */
+ bool IsDefaultMap() const;
+
+ /** Does the font character map include the UCS4 character?
+
+ @returns true if character exists in font character map, false is not.
+ */
+ bool HasChar( sal_UCS4 ) const;
+
+ /** Returns the number of chars supported by the font, which
+ are inside the unicode range from cMin to cMax (inclusive).
+
+ @param cMin Lowest codepoint in range to be counted
+ @param cMax Highest codepoitn in range to be counted
+
+ @returns number of characters in the font charmap between the two
+ codepoints.
+ */
+ int CountCharsInRange( sal_UCS4 cMin, sal_UCS4 cMax ) const;
+
+ /** Get the number of characters in the font character map.
+
+ @returns number of characters in the font character map.
+ */
+ int GetCharCount() const;
+
+ /** Get the first character in the font character map.
+
+ @returns first character in the font character map.
+ */
+ sal_UCS4 GetFirstChar() const;
+
+ /** Get the last character in the font character map.
+
+ @returns last character in the font character map.
+ */
+ sal_UCS4 GetLastChar() const;
+
+ /** Get the next character in the font character map. This is important
+ because character maps (e.g. the default map which holds the characters
+ in the BMP plane) can have discontiguous ranges.
+
+ @param cChar Character from which to find next character
+
+ @returns next character in the font character map.
+ */
+ sal_UCS4 GetNextChar( sal_UCS4 cChar ) const;
+
+ /** Get the previous character in the font character map. This is important
+ because character maps (e.g. the default map which holds the characters
+ in the BMP plane) can have discontiguous ranges.
+
+ @param cChar Character from which to find previous character
+
+ @returns previous character in the font character map.
+ */
+ sal_UCS4 GetPrevChar( sal_UCS4 cChar ) const;
+
+ /** Get the index of a particular character in the font character map. The
+ index is different from the codepoint, because font character maps can
+
+ determine the index.
+
+ @param cChar Character used to find index number
+
+ @returns Index of character in font character map.
+ */
+ int GetIndexFromChar( sal_UCS4 cChar ) const;
+
+ /** Get the character at a particular index in the font character map. The
+ index is different from the codepoint, because font character maps can
+
+ determine the character.
+
+ @param nCharIndex Index used to find the character
+
+ @returns Character in font character map.
+ */
+ sal_UCS4 GetCharFromIndex( int nCharIndex ) const;
+
+ int GetGlyphIndex( sal_UCS4 ) const;
+
+private:
+ ImplFontCharMapPtr mpImplFontCharMap;
+
+ friend class ::OutputDevice;
+ friend void intrusive_ptr_release(FontCharMap* pFontCharMap);
+ friend void intrusive_ptr_add_ref(FontCharMap* pFontCharMap);
+
+ int findRangeIndex( sal_uInt32 ) const;
+
+ FontCharMap( ImplFontCharMapPtr pIFCMap );
+
+ sal_uInt32 mnRefCount;
+
+ // prevent assignment and copy construction
+ FontCharMap( const FontCharMap& ) = delete;
+ void operator=( const FontCharMap& ) = delete;
+};
+
+inline void intrusive_ptr_add_ref(FontCharMap* pFontCharMap)
+{
+ ++pFontCharMap->mnRefCount;
+}
+
+inline void intrusive_ptr_release(FontCharMap* pFontCharMap)
+{
+ if (--pFontCharMap->mnRefCount == 0)
+ delete pFontCharMap;
+}
+
+#endif // INCLUDED_FONTCHARMAP_METRIC_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/vcl/metric.hxx b/include/vcl/metric.hxx
index 57e471c44328..28b582f63929 100644
--- a/include/vcl/metric.hxx
+++ b/include/vcl/metric.hxx
@@ -80,167 +80,6 @@ inline std::basic_ostream<charT, traits> & operator <<(
return stream;
}
-class VCL_DLLPUBLIC FontCharMap
-{
-public:
- /** A new FontCharMap is created based on a "default" map, which includes
- all codepoints in the Unicode BMP range, including surrogates.
- **/
- FontCharMap();
- FontCharMap( const CmapResult& rCR );
- ~FontCharMap();
-
- /** Get the default font character map
-
- @returns the default font character map.
- */
- static FontCharMapPtr GetDefaultMap( bool bSymbols=false );
-
- /** Determines if the font character map is the "default". The default map
- includes all codepoints in the Unicode BMP range, including surrogates.
-
- @returns true if default map, false if not default map.
- */
- bool IsDefaultMap() const;
-
- /** Does the font character map include the UCS4 character?
-
- @returns true if character exists in font character map, false is not.
- */
- bool HasChar( sal_UCS4 ) const;
-
- /** Returns the number of chars supported by the font, which
- are inside the unicode range from cMin to cMax (inclusive).
-
- @param cMin Lowest codepoint in range to be counted
- @param cMax Highest codepoitn in range to be counted
-
- @returns number of characters in the font charmap between the two
- codepoints.
- */
- int CountCharsInRange( sal_UCS4 cMin, sal_UCS4 cMax ) const;
-
- /** Get the number of characters in the font character map.
-
- @returns number of characters in the font character map.
- */
- int GetCharCount() const;
-
- /** Get the first character in the font character map.
-
- @returns first character in the font character map.
- */
- sal_UCS4 GetFirstChar() const;
-
- /** Get the last character in the font character map.
-
- @returns last character in the font character map.
- */
- sal_UCS4 GetLastChar() const;
-
- /** Get the next character in the font character map. This is important
- because character maps (e.g. the default map which holds the characters
- in the BMP plane) can have discontiguous ranges.
-
- @param cChar Character from which to find next character
-
- @returns next character in the font character map.
- */
- sal_UCS4 GetNextChar( sal_UCS4 cChar ) const;
-
- /** Get the previous character in the font character map. This is important
- because character maps (e.g. the default map which holds the characters
- in the BMP plane) can have discontiguous ranges.
-
- @param cChar Character from which to find previous character
-
- @returns previous character in the font character map.
- */
- sal_UCS4 GetPrevChar( sal_UCS4 cChar ) const;
-
- /** Get the index of a particular character in the font character map. The
- index is different from the codepoint, because font character maps can
-
- determine the index.
-
- @param cChar Character used to find index number
-
- @returns Index of character in font character map.
- */
- int GetIndexFromChar( sal_UCS4 cChar ) const;
-
- /** Get the character at a particular index in the font character map. The
- index is different from the codepoint, because font character maps can
-
- determine the character.
-
- @param nCharIndex Index used to find the character
-
- @returns Character in font character map.
- */
- sal_UCS4 GetCharFromIndex( int nCharIndex ) const;
-
- int GetGlyphIndex( sal_UCS4 ) const;
-
-private:
- ImplFontCharMapPtr mpImplFontCharMap;
-
- friend class ::OutputDevice;
- friend void intrusive_ptr_release(FontCharMap* pFontCharMap);
- friend void intrusive_ptr_add_ref(FontCharMap* pFontCharMap);
-
- int findRangeIndex( sal_uInt32 ) const;
-
- FontCharMap( ImplFontCharMapPtr pIFCMap );
-
- sal_uInt32 mnRefCount;
-
- // prevent assignment and copy construction
- FontCharMap( const FontCharMap& ) = delete;
- void operator=( const FontCharMap& ) = delete;
-};
-
-inline void intrusive_ptr_add_ref(FontCharMap* pFontCharMap)
-{
- ++pFontCharMap->mnRefCount;
-}
-
-inline void intrusive_ptr_release(FontCharMap* pFontCharMap)
-{
- if (--pFontCharMap->mnRefCount == 0)
- delete pFontCharMap;
-}
-
-class VCL_DLLPUBLIC TextRectInfo
-{
- friend class ::OutputDevice;
-
-private:
- long mnMaxWidth;
- sal_uInt16 mnLineCount;
- bool mbEllipsis;
-
-public:
- TextRectInfo();
-
- long GetMaxLineWidth() const { return mnMaxWidth; }
- bool IsEllipses() const { return mbEllipsis; }
-
- bool operator ==( const TextRectInfo& rInfo ) const
- { return ((mnMaxWidth == rInfo.mnMaxWidth) &&
- (mnLineCount == rInfo.mnLineCount) &&
- (mbEllipsis == rInfo.mbEllipsis)); }
- bool operator !=( const TextRectInfo& rInfo ) const
- { return !(TextRectInfo::operator==( rInfo )); }
-};
-
-inline TextRectInfo::TextRectInfo()
-{
- mnMaxWidth = 0;
- mnLineCount = 0;
- mbEllipsis = false;
-}
-
#endif // INCLUDED_VCL_METRIC_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/vcl/textrectinfo.hxx b/include/vcl/textrectinfo.hxx
new file mode 100644
index 000000000000..8b98e1a37c99
--- /dev/null
+++ b/include/vcl/textrectinfo.hxx
@@ -0,0 +1,57 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef INCLUDED_VCL_TEXTRECTINFO_HXX
+#define INCLUDED_VCL_TEXTRECTINFO_HXX
+
+#include <vcl/outdev.hxx>
+
+class VCL_DLLPUBLIC TextRectInfo
+{
+ friend class ::OutputDevice;
+
+private:
+ long mnMaxWidth;
+ sal_uInt16 mnLineCount;
+ bool mbEllipsis;
+
+public:
+ TextRectInfo();
+
+ long GetMaxLineWidth() const { return mnMaxWidth; }
+ bool IsEllipses() const { return mbEllipsis; }
+
+ bool operator ==( const TextRectInfo& rInfo ) const
+ { return ((mnMaxWidth == rInfo.mnMaxWidth) &&
+ (mnLineCount == rInfo.mnLineCount) &&
+ (mbEllipsis == rInfo.mbEllipsis)); }
+ bool operator !=( const TextRectInfo& rInfo ) const
+ { return !(TextRectInfo::operator==( rInfo )); }
+};
+
+inline TextRectInfo::TextRectInfo()
+{
+ mnMaxWidth = 0;
+ mnLineCount = 0;
+ mbEllipsis = false;
+}
+
+#endif // INCLUDED_VCL_TEXTRECTINFO_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sc/source/filter/excel/xistyle.cxx b/sc/source/filter/excel/xistyle.cxx
index ad99a0286fb3..05c1516ddc93 100644
--- a/sc/source/filter/excel/xistyle.cxx
+++ b/sc/source/filter/excel/xistyle.cxx
@@ -43,6 +43,7 @@
#include <editeng/flstitem.hxx>
#include <editeng/justifyitem.hxx>
#include <sal/macros.h>
+#include <vcl/fontcharmap.hxx>
#include "document.hxx"
#include "docpool.hxx"
#include "attrib.hxx"
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index 0a4ebfbba4ab..1b6b34929303 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -36,6 +36,7 @@
#include <vcl/waitobj.hxx>
#include <vcl/settings.hxx>
#include <vcl/wall.hxx>
+#include <vcl/fontcharmap.hxx>
#include <sfx2/dispatch.hxx>
#include <sfx2/sfx.hrc>
#include <osl/diagnose.h>
diff --git a/svtools/source/misc/sampletext.cxx b/svtools/source/misc/sampletext.cxx
index 54e62dbd1fff..031536162e9d 100644
--- a/svtools/source/misc/sampletext.cxx
+++ b/svtools/source/misc/sampletext.cxx
@@ -11,6 +11,7 @@
#include <vcl/outdev.hxx>
#include <vcl/virdev.hxx>
#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
#include <i18nutil/unicode.hxx>
// This should only be used when a commonly used font incorrectly declares its
diff --git a/svx/source/dialog/charmap.cxx b/svx/source/dialog/charmap.cxx
index 5c34df44a31a..d4fb271653d8 100644
--- a/svx/source/dialog/charmap.cxx
+++ b/svx/source/dialog/charmap.cxx
@@ -22,6 +22,7 @@
#include <vcl/svapp.hxx>
#include <vcl/settings.hxx>
#include <vcl/builderfactory.hxx>
+#include <vcl/fontcharmap.hxx>
#include <svtools/colorcfg.hxx>
#include <rtl/textenc.h>
diff --git a/vcl/generic/fontmanager/fontmanager.cxx b/vcl/generic/fontmanager/fontmanager.cxx
index f8cbc7d0c33e..86dfab3b0a9d 100644
--- a/vcl/generic/fontmanager/fontmanager.cxx
+++ b/vcl/generic/fontmanager/fontmanager.cxx
@@ -34,6 +34,7 @@
#include "vcl/strhelper.hxx"
#include "vcl/ppdparser.hxx"
#include <vcl/embeddedfontshelper.hxx>
+#include <vcl/fontcharmap.hxx>
#include "tools/urlobj.hxx"
#include "tools/stream.hxx"
diff --git a/vcl/generic/glyphs/gcach_ftyp.cxx b/vcl/generic/glyphs/gcach_ftyp.cxx
index fe15d11fc335..686be0060ad0 100644
--- a/vcl/generic/glyphs/gcach_ftyp.cxx
+++ b/vcl/generic/glyphs/gcach_ftyp.cxx
@@ -17,6 +17,9 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+
+#include <vcl/fontcharmap.hxx>
+
#include "gcach_ftyp.hxx"
#include "vcl/svapp.hxx"
diff --git a/vcl/generic/print/genpspgraphics.cxx b/vcl/generic/print/genpspgraphics.cxx
index f892eca01197..096536a2703c 100644
--- a/vcl/generic/print/genpspgraphics.cxx
+++ b/vcl/generic/print/genpspgraphics.cxx
@@ -40,6 +40,7 @@
#include <vcl/settings.hxx>
#include <vcl/svapp.hxx>
#include <vcl/sysdata.hxx>
+#include <vcl/fontcharmap.hxx>
#include <config_cairo_canvas.h>
#include "fontsubset.hxx"
diff --git a/vcl/headless/svptext.cxx b/vcl/headless/svptext.cxx
index 785461d1fc39..df156ed5f33e 100644
--- a/vcl/headless/svptext.cxx
+++ b/vcl/headless/svptext.cxx
@@ -18,6 +18,7 @@
*/
#include <sal/types.h>
+#include <vcl/fontcharmap.hxx>
#include <basegfx/range/b2ibox.hxx>
#include "headless/svpgdi.hxx"
#include <config_cairo_canvas.h>
diff --git a/vcl/inc/win/salgdi.h b/vcl/inc/win/salgdi.h
index b8b7d74cd5b2..c58c17a5e67d 100644
--- a/vcl/inc/win/salgdi.h
+++ b/vcl/inc/win/salgdi.h
@@ -28,6 +28,7 @@
#include "PhysicalFontFace.hxx"
#include "impfont.hxx"
#include <vcl/fontcapabilities.hxx>
+#include <vcl/fontcharmap.hxx>
#include <memory>
#include <unordered_set>
diff --git a/vcl/qa/cppunit/fontcharmap.cxx b/vcl/qa/cppunit/fontcharmap.cxx
index 17923afc983e..4453ffa4cb95 100644
--- a/vcl/qa/cppunit/fontcharmap.cxx
+++ b/vcl/qa/cppunit/fontcharmap.cxx
@@ -12,7 +12,7 @@
#include <osl/file.hxx>
#include <osl/process.h>
-#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
class VclFontCharMapTest : public test::BootstrapFixture
{
diff --git a/vcl/quartz/salgdi.cxx b/vcl/quartz/salgdi.cxx
index c36eacf1da08..ca83b61e3748 100644
--- a/vcl/quartz/salgdi.cxx
+++ b/vcl/quartz/salgdi.cxx
@@ -33,6 +33,7 @@
#include <rtl/strbuf.hxx>
#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
#include <vcl/svapp.hxx>
#include <vcl/sysdata.hxx>
diff --git a/vcl/source/filter/wmf/wmfwr.cxx b/vcl/source/filter/wmf/wmfwr.cxx
index dbb9ad3a7a34..73f0489da7e5 100644
--- a/vcl/source/filter/wmf/wmfwr.cxx
+++ b/vcl/source/filter/wmf/wmfwr.cxx
@@ -37,6 +37,7 @@
#include <basegfx/polygon/b2dpolygon.hxx>
#include <basegfx/polygon/b2dpolypolygon.hxx>
#include <memory>
+#include <vcl/fontcharmap.hxx>
// MS Windows defines
diff --git a/vcl/source/gdi/impfont.cxx b/vcl/source/gdi/impfont.cxx
index e8c68fc3cb5d..f99bed10dc11 100644
--- a/vcl/source/gdi/impfont.cxx
+++ b/vcl/source/gdi/impfont.cxx
@@ -15,7 +15,7 @@
* except in compliance with the License. You may obtain a copy of
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
#include <outfont.hxx>
#include <impfont.hxx>
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx
index f328a4f7e64b..237cca2d94ce 100644
--- a/vcl/source/outdev/font.cxx
+++ b/vcl/source/outdev/font.cxx
@@ -26,6 +26,7 @@
#include <vcl/edit.hxx>
#include <vcl/settings.hxx>
#include <vcl/sysdata.hxx>
+#include <vcl/fontcharmap.hxx>
#include "sallayout.hxx"
#include "svdata.hxx"
diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index 6a04eb88313d..b396e535cead 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -32,6 +32,7 @@
#include <comphelper/processfactory.hxx>
+#include <vcl/textrectinfo.hxx>
#include <vcl/outdev.hxx>
#include <vcl/virdev.hxx>
#include <vcl/bmpacc.hxx>
diff --git a/vcl/source/window/brdwin.cxx b/vcl/source/window/brdwin.cxx
index 1e273749f073..962bd8ae51b3 100644
--- a/vcl/source/window/brdwin.cxx
+++ b/vcl/source/window/brdwin.cxx
@@ -22,6 +22,7 @@
#include <brdwin.hxx>
#include <window.h>
+#include <vcl/textrectinfo.hxx>
#include <vcl/event.hxx>
#include <vcl/decoview.hxx>
#include <vcl/syswin.hxx>
diff --git a/vcl/source/window/msgbox.cxx b/vcl/source/window/msgbox.cxx
index 6f84fbcd4778..600a1a88e1fe 100644
--- a/vcl/source/window/msgbox.cxx
+++ b/vcl/source/window/msgbox.cxx
@@ -24,6 +24,7 @@
#include <brdwin.hxx>
#include <window.h>
+#include <vcl/textrectinfo.hxx>
#include <vcl/metric.hxx>
#include <vcl/svapp.hxx>
#include <vcl/wrkwin.hxx>
diff --git a/vcl/unx/generic/gdi/cairotextrender.cxx b/vcl/unx/generic/gdi/cairotextrender.cxx
index 419dc58ceec2..7727e12c34bf 100644
--- a/vcl/unx/generic/gdi/cairotextrender.cxx
+++ b/vcl/unx/generic/gdi/cairotextrender.cxx
@@ -23,6 +23,7 @@
#include <vcl/settings.hxx>
#include <vcl/sysdata.hxx>
#include <vcl/svapp.hxx>
+#include <vcl/fontcharmap.hxx>
#include "generic/printergfx.hxx"
#include "generic/genpspgraphics.h"
diff --git a/vcl/unx/generic/gdi/salgdi3.cxx b/vcl/unx/generic/gdi/salgdi3.cxx
index 27e339a45ff1..ae63464b2a5a 100644
--- a/vcl/unx/generic/gdi/salgdi3.cxx
+++ b/vcl/unx/generic/gdi/salgdi3.cxx
@@ -40,6 +40,7 @@
#include <vcl/printerinfomanager.hxx>
#include <vcl/svapp.hxx>
#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
#include "fontmanager.hxx"
#include "impfont.hxx"
diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx
index dba8568710ee..1f83835ceba9 100644
--- a/vcl/win/gdi/salfont.cxx
+++ b/vcl/win/gdi/salfont.cxx
@@ -40,6 +40,7 @@
#include <vcl/settings.hxx>
#include <vcl/sysdata.hxx>
#include <vcl/metric.hxx>
+#include <vcl/fontcharmap.hxx>
#include "fontsubset.hxx"
#include "outdev.h"