[Libreoffice-commits] core.git: cui/source desktop/source editeng/source framework/source include/svtools include/vcl sc/source starmath/source svtools/source svx/source sw/source vcl/source vcl/workben

Chris Sherlock chris.sherlock79 at gmail.com
Sun Jan 3 08:19:39 PST 2016


 cui/source/options/fontsubs.cxx                       |    2 
 cui/source/tabpages/chardlg.cxx                       |   18 +--
 cui/source/tabpages/numpages.cxx                      |    2 
 desktop/source/lib/init.cxx                           |    4 
 editeng/source/editeng/editview.cxx                   |    2 
 framework/source/uielement/fontsizemenucontroller.cxx |    2 
 include/svtools/ctrlbox.hxx                           |    8 -
 include/svtools/ctrltool.hxx                          |   44 +++----
 include/svtools/stdmenu.hxx                           |    4 
 include/vcl/metric.hxx                                |   32 +----
 include/vcl/outdev.hxx                                |    2 
 sc/source/filter/excel/xehelper.cxx                   |    2 
 sc/source/filter/excel/xistyle.cxx                    |    2 
 starmath/source/dialog.cxx                            |    2 
 svtools/source/control/ctrlbox.cxx                    |   28 ++--
 svtools/source/control/ctrltool.cxx                   |  102 +++++++++---------
 svtools/source/control/stdmenu.cxx                    |    2 
 svx/source/mnuctrls/fntszctl.cxx                      |    2 
 svx/source/sidebar/nbdtmg.cxx                         |    2 
 svx/source/tbxctrls/tbcontrl.cxx                      |    4 
 svx/source/tbxctrls/tbunocontroller.cxx               |    2 
 sw/source/core/unocore/unocrsrhelper.cxx              |    2 
 sw/source/core/unocore/unosett.cxx                    |    2 
 sw/source/core/unocore/unostyle.cxx                   |    2 
 sw/source/filter/html/svxcss1.cxx                     |    4 
 sw/source/filter/html/swhtml.cxx                      |    4 
 sw/source/ui/config/optpage.cxx                       |    6 -
 sw/source/ui/dialog/ascfldlg.cxx                      |    2 
 sw/source/uibase/docvw/srcedtw.cxx                    |    2 
 vcl/source/gdi/metric.cxx                             |   31 +----
 vcl/source/outdev/font.cxx                            |    4 
 vcl/workben/svptest.cxx                               |    2 
 32 files changed, 146 insertions(+), 183 deletions(-)

New commits:
commit 8227b9955e4a06758f3e0a871e49731a0a607608
Author: Chris Sherlock <chris.sherlock79 at gmail.com>
Date:   Mon Jan 4 01:16:47 2016 +1100

    vcl: Excise vcl::FontInfo class
    
    This may sound crazy, but literally vcl::FontInfo serves no purpose
    that I can see. The inheritance chain is like this:
    
            ┌────────────────────────┐
            │                        │
            │        vcl::Font       │
            │                        │
            └────────────────────────┘
                         ^
                        ╱ ╲
                         │
                         │
            ┌────────────────────────┐
            │                        │
            │      vcl::FontInfo     │
            │                        │
            └────────────────────────┘
                         ^
                        ╱ ╲
                         │
                         │
    
            ┌────────────────────────┐
            │                        │
            │       FontMetric       │
            │                        │
            └────────────────────────┘
    
    vcl::FontInfo (which, incidentally, needs to be put into the vcl
    namespace due to collisions with poppler!) literally does nothing
    and is acting as a bridge between FontMetric and vcl::Font. Unlike
    a bridge though, this bridge doesn't actually *do* anything.
    
    So I'm removing it, which means one less class to deal with in the
    vcl fonts world.
    
    Change-Id: I32725669c9bca7fbb0846b6a062135464046e4f6
    Reviewed-on: https://gerrit.libreoffice.org/21058
    Reviewed-by: Chris Sherlock <chris.sherlock79 at gmail.com>
    Tested-by: Chris Sherlock <chris.sherlock79 at gmail.com>

diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx
index 2130435..4f7893d 100644
--- a/cui/source/options/fontsubs.cxx
+++ b/cui/source/options/fontsubs.cxx
@@ -359,7 +359,7 @@ IMPL_LINK_TYPED(SvxFontSubstTabPage, NonPropFontsHdl, Button*, pBox, void)
     sal_uInt16 nFontCount = aFntLst.GetFontNameCount();
     for(sal_uInt16 nFont = 0; nFont < nFontCount; nFont++)
     {
-        const vcl::FontInfo& rInfo = aFntLst.GetFontName( nFont );
+        const FontMetric& rInfo = aFntLst.GetFontName( nFont );
         if(!bNonPropOnly || rInfo.GetPitch() == PITCH_FIXED)
             m_pFontNameLB->InsertEntry(rInfo.GetName());
     }
diff --git a/cui/source/tabpages/chardlg.cxx b/cui/source/tabpages/chardlg.cxx
index ed1a26d..1747888 100644
--- a/cui/source/tabpages/chardlg.cxx
+++ b/cui/source/tabpages/chardlg.cxx
@@ -474,7 +474,7 @@ const FontList* SvxCharNamePage::GetFontList() const
 
 namespace
 {
-    vcl::FontInfo calcFontInfo(  SvxFont& _rFont,
+    FontMetric calcFontInfo(  SvxFont& _rFont,
                     SvxCharNamePage* _pPage,
                     const FontNameBox* _pFontNameLB,
                     const FontStyleBox* _pFontStyleLB,
@@ -486,7 +486,7 @@ namespace
     {
         Size aSize = _rFont.GetSize();
         aSize.Width() = 0;
-        vcl::FontInfo aFontInfo;
+        FontMetric aFontInfo;
         OUString sFontName(_pFontNameLB->GetText());
         bool bFontAvailable = _pFontList->IsAvailable( sFontName );
         if (bFontAvailable  || _pFontNameLB->IsValueChangedFromSaved())
@@ -559,19 +559,19 @@ void SvxCharNamePage::UpdatePreview_Impl()
     // Font
     const FontList* pFontList = GetFontList();
 
-    vcl::FontInfo aWestFontInfo = calcFontInfo(rFont, this, m_pWestFontNameLB,
+    FontMetric aWestFontInfo = calcFontInfo(rFont, this, m_pWestFontNameLB,
         m_pWestFontStyleLB, m_pWestFontSizeLB, m_pWestFontLanguageLB,
         pFontList, GetWhich(SID_ATTR_CHAR_FONT),
         GetWhich(SID_ATTR_CHAR_FONTHEIGHT));
     m_pWestFontTypeFT->SetText(pFontList->GetFontMapText(aWestFontInfo));
 
-    vcl::FontInfo aEastFontInfo = calcFontInfo(rCJKFont, this, m_pEastFontNameLB,
+    FontMetric aEastFontInfo = calcFontInfo(rCJKFont, this, m_pEastFontNameLB,
         m_pEastFontStyleLB, m_pEastFontSizeLB, m_pEastFontLanguageLB,
         pFontList, GetWhich(SID_ATTR_CHAR_CJK_FONT),
         GetWhich(SID_ATTR_CHAR_CJK_FONTHEIGHT));
     m_pEastFontTypeFT->SetText(pFontList->GetFontMapText(aEastFontInfo));
 
-    vcl::FontInfo aCTLFontInfo = calcFontInfo(rCTLFont,
+    FontMetric aCTLFontInfo = calcFontInfo(rCTLFont,
         this, m_pCTLFontNameLB, m_pCTLFontStyleLB, m_pCTLFontSizeLB,
         m_pCTLFontLanguageLB, pFontList, GetWhich(SID_ATTR_CHAR_CTL_FONT),
         GetWhich(SID_ATTR_CHAR_CTL_FONTHEIGHT));
@@ -648,7 +648,7 @@ void SvxCharNamePage::FillSizeBox_Impl( const FontNameBox* pNameBox )
         return;
     }
 
-    vcl::FontInfo _aFontInfo( pFontList->Get( pNameBox->GetText(), pStyleBox->GetText() ) );
+    FontMetric _aFontInfo( pFontList->Get( pNameBox->GetText(), pStyleBox->GetText() ) );
     pSizeBox->Fill( &_aFontInfo, pFontList );
 }
 
@@ -759,7 +759,7 @@ void SvxCharNamePage::Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp
     // currently chosen font
     if ( bStyle && pFontItem )
     {
-        vcl::FontInfo aInfo = pFontList->Get( pFontItem->GetFamilyName(), eWeight, eItalic );
+        FontMetric aInfo = pFontList->Get( pFontItem->GetFamilyName(), eWeight, eItalic );
         pStyleBox->SetText( pFontList->GetStyleName( aInfo ) );
     }
     else if ( !m_pImpl->m_bInSearchMode || !bStyle )
@@ -768,7 +768,7 @@ void SvxCharNamePage::Reset_Impl( const SfxItemSet& rSet, LanguageGroup eLangGrp
     }
     else if ( bStyle )
     {
-        vcl::FontInfo aInfo = pFontList->Get( OUString(), eWeight, eItalic );
+        FontMetric aInfo = pFontList->Get( OUString(), eWeight, eItalic );
         pStyleBox->SetText( pFontList->GetStyleName( aInfo ) );
     }
     if (!bStyleAvailable)
@@ -930,7 +930,7 @@ bool SvxCharNamePage::FillItemSet_Impl( SfxItemSet& rSet, LanguageGroup eLangGrp
     sal_Int32 nEntryPos = pStyleBox->GetEntryPos( aStyleBoxText );
     if ( nEntryPos >= m_pImpl->m_nExtraEntryPos )
         aStyleBoxText.clear();
-    vcl::FontInfo aInfo( pFontList->Get( rFontName, aStyleBoxText ) );
+    FontMetric aInfo( pFontList->Get( rFontName, aStyleBoxText ) );
     SvxFontItem aFontItem( aInfo.GetFamily(), aInfo.GetName(), aInfo.GetStyleName(),
                            aInfo.GetPitch(), aInfo.GetCharSet(), nWhich );
     pOld = GetOldItem( rSet, nSlot );
diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx
index c9b5b2a..0a25a78 100644
--- a/cui/source/tabpages/numpages.cxx
+++ b/cui/source/tabpages/numpages.cxx
@@ -736,7 +736,7 @@ IMPL_LINK_NOARG_TYPED(SvxNumPickTabPage, NumSelectHdl_Impl, ValueSet*, void)
                     }
                     if(pList && pList->IsAvailable( pLevelSettings->sBulletFont ) )
                     {
-                        vcl::FontInfo aInfo = pList->Get(
+                        FontMetric aInfo = pList->Get(
                             pLevelSettings->sBulletFont,WEIGHT_NORMAL, ITALIC_NONE);
                         vcl::Font aFont(aInfo);
                         aFmt.SetBulletFont(&aFont);
diff --git a/desktop/source/lib/init.cxx b/desktop/source/lib/init.cxx
index 5f5958b..6727681 100644
--- a/desktop/source/lib/init.cxx
+++ b/desktop/source/lib/init.cxx
@@ -1215,7 +1215,7 @@ static char* getFonts (const char* pCommand)
         for (sal_uInt16 i = 0; i < nFontCount; ++i)
         {
             boost::property_tree::ptree aChildren;
-            const vcl::FontInfo& rInfo = pList->GetFontName(i);
+            const FontMetric& rInfo = pList->GetFontName(i);
             const sal_IntPtr* pAry = pList->GetSizeAry(rInfo);
             sal_uInt16 nSizeCount = 0;
             while (pAry[nSizeCount])
@@ -1529,7 +1529,7 @@ unsigned char* doc_renderFont(LibreOfficeKitDocument* /*pThis*/,
         sal_uInt16 nFontCount = pList->GetFontNameCount();
         for (sal_uInt16 i = 0; i < nFontCount; ++i)
         {
-            const vcl::FontInfo& rInfo = pList->GetFontName(i);
+            const FontMetric& rInfo = pList->GetFontName(i);
             OUString aFontName = rInfo.GetName();
             if (!aSearchedFontName.equals(aFontName.toUtf8().getStr()))
                 continue;
diff --git a/editeng/source/editeng/editview.cxx b/editeng/source/editeng/editview.cxx
index 935fe5e..b9ed6d8e 100644
--- a/editeng/source/editeng/editview.cxx
+++ b/editeng/source/editeng/editview.cxx
@@ -1213,7 +1213,7 @@ bool EditView::ChangeFontSize( bool bGrow, SfxItemSet& rSet, const FontList* pFo
         const SfxMapUnit eUnit = rSet.GetPool()->GetMetric( *pWhich );
         nHeight = OutputDevice::LogicToLogic( nHeight * 10, (MapUnit)eUnit, MAP_POINT );
 
-        vcl::FontInfo aFontInfo = pFontList->Get( pFontItem->GetFamilyName(), pFontItem->GetStyleName() );
+        FontMetric aFontInfo = pFontList->Get( pFontItem->GetFamilyName(), pFontItem->GetStyleName() );
         const sal_IntPtr* pAry = pFontList->GetSizeAry( aFontInfo );
 
         if( bGrow )
diff --git a/framework/source/uielement/fontsizemenucontroller.cxx b/framework/source/uielement/fontsizemenucontroller.cxx
index 7bbfc04..705cdbd 100644
--- a/framework/source/uielement/fontsizemenucontroller.cxx
+++ b/framework/source/uielement/fontsizemenucontroller.cxx
@@ -152,7 +152,7 @@ void FontSizeMenuController::fillPopupMenu( Reference< css::awt::XPopupMenu >& r
         if ( !pFontList )
             pFontList.reset(new FontList( Application::GetDefaultDevice() ));
 
-        vcl::FontInfo aFntInfo = pFontList->Get( m_aFontDescriptor.Name, m_aFontDescriptor.StyleName );
+        FontMetric aFntInfo = pFontList->Get( m_aFontDescriptor.Name, m_aFontDescriptor.StyleName );
 
         // setup font size array
         delete m_pHeightArray;
diff --git a/include/svtools/ctrlbox.hxx b/include/svtools/ctrlbox.hxx
index 7c26d46..0be5c42 100644
--- a/include/svtools/ctrlbox.hxx
+++ b/include/svtools/ctrlbox.hxx
@@ -38,7 +38,7 @@ class ImpLineListData;
 
 typedef ::std::vector< ImplColorListData*    > ImpColorList;
 typedef ::std::vector< ImpLineListData*      > ImpLineList;
-typedef ::std::vector< vcl::FontInfo         > ImplFontList;
+typedef ::std::vector< FontMetric         > ImplFontList;
 
 /*************************************************************************
 
@@ -131,7 +131,7 @@ Additionally it supports an relative mod, which allows entering
 percentage values. This, eg., can be useful for template dialogs.
 This mode can only be enabled, but not disabled again.
 
-For DontKnow the FontSizeBox should be filled FontInfo(), so it will
+For DontKnow the FontSizeBox should be filled FontMetric(), so it will
 contain an list with the standard sizes. Th currently shown size
 probably needs to be reset by the application.
 
@@ -437,7 +437,7 @@ inline void FontStyleBox::SetText( const OUString& rText )
 
 class SVT_DLLPUBLIC FontSizeBox : public MetricBox
 {
-    vcl::FontInfo       aFontInfo;
+    FontMetric       aFontMetric;
     const FontList* pFontList;
     sal_uInt16          nRelMin;
     sal_uInt16          nRelMax;
@@ -462,7 +462,7 @@ public:
     void            Reformat() override;
     void            Modify() override;
 
-    void            Fill( const vcl::FontInfo* pInfo, const FontList* pList );
+    void            Fill( const FontMetric* pInfo, const FontList* pList );
 
     void            EnableRelativeMode( sal_uInt16 nMin = 50, sal_uInt16 nMax = 150,
                                         sal_uInt16 nStep = 5 );
diff --git a/include/svtools/ctrltool.hxx b/include/svtools/ctrltool.hxx
index 263846e..3c5449f 100644
--- a/include/svtools/ctrltool.hxx
+++ b/include/svtools/ctrltool.hxx
@@ -73,28 +73,28 @@ With sal_False vectorized and scalable fonts will be queried.
 
 --------------------------------------------------------------------------
 
-String FontList::GetStyleName( const vcl::FontInfo& rInfo ) const;
+String FontList::GetStyleName( const FontMetric& rInfo ) const;
 
-This method returns the StyleName of a vcl::FontInfo.
+This method returns the StyleName of a FontMetric.
 If no StyleName is set, a name will be generated from the set attributes.
 
 --------------------------------------------------------------------------
 
-OUString FontList::GetFontMapText( const vcl::FontInfo& rInfo ) const;
+OUString FontList::GetFontMapText( const FontMetric& rInfo ) const;
 
 This method returns a Matchstring which indicates the problem that could
 arise when using a font. This string should be displayed to the user.
 
 --------------------------------------------------------------------------
 
-vcl::FontInfo FontList::Get( const String& rName, const String& rStyleName ) const;
+FontMetric FontList::Get( const String& rName, const String& rStyleName ) const;
 
-This method search a vcl::FontInfo for the given name and the given style name.
+This method search a FontMetric for the given name and the given style name.
 The Stylename can also be a synthetic one.
-In that case the relevant vcl::FontInfo fields will be set.
-If a StyleName is provided, a vcl::FontInfo structure without a Stylename can be
+In that case the relevant FontMetric fields will be set.
+If a StyleName is provided, a FontMetric structure without a Stylename can be
 returned. To get a representation of the StyleName for displaying it to the user,
-call GetStyleName() on this vcl::FontInfo structure.
+call GetStyleName() on this FontMetric structure.
 
 Links:
 
@@ -102,13 +102,13 @@ FontList::GetStyleName()
 
 --------------------------------------------------------------------------
 
-vcl::FontInfo FontList::Get( const String& rName, FontWeight eWeight,
+FontMetric FontList::Get( const String& rName, FontWeight eWeight,
                         FontItalic eItalic ) const;
 
-This method search a vcl::FontInfo structure for a provided name and styles.
-This method can also return a vcl::FontInfo without a Stylename.
+This method search a FontMetric structure for a provided name and styles.
+This method can also return a FontMetric without a Stylename.
 To get a representation of the StyleName to be presented to the user
-call GetStyleName() with this vcl::FontInfo.
+call GetStyleName() with this FontMetric.
 
 Links:
 
@@ -116,7 +116,7 @@ FontList::GetStyleName()
 
 --------------------------------------------------------------------------
 
-const sal_IntPtr* FontList::GetSizeAry( const vcl::FontInfo& rInfo ) const;
+const sal_IntPtr* FontList::GetSizeAry( const FontMetric& rInfo ) const;
 
 This method returns the available sizes for the given font.
 If it is a scalable font, standard sizes are returned.
@@ -166,18 +166,18 @@ public:
 
     FontList*               Clone() const;
 
-    OUString                GetFontMapText( const vcl::FontInfo& rInfo ) const;
+    OUString                GetFontMapText( const FontMetric& rInfo ) const;
 
     const OUString&         GetNormalStr() const { return maNormal; }
     const OUString&         GetItalicStr() const { return maNormalItalic; }
     const OUString&         GetBoldStr() const { return maBold; }
     const OUString&         GetBoldItalicStr() const { return maBoldItalic; }
     const OUString&         GetStyleName( FontWeight eWeight, FontItalic eItalic ) const;
-    OUString                GetStyleName( const vcl::FontInfo& rInfo ) const;
+    OUString                GetStyleName( const FontMetric& rInfo ) const;
 
-    vcl::FontInfo           Get( const OUString& rName,
+    FontMetric           Get( const OUString& rName,
                                  const OUString& rStyleName ) const;
-    vcl::FontInfo           Get( const OUString& rName,
+    FontMetric           Get( const OUString& rName,
                                  FontWeight eWeight,
                                  FontItalic eItalic ) const;
 
@@ -186,12 +186,12 @@ public:
     {
         return (sal_uInt16)m_Entries.size();
     }
-    const vcl::FontInfo&    GetFontName( sal_uInt16 nFont ) const;
-    sal_Handle              GetFirstFontInfo( const OUString& rName ) const;
-    static sal_Handle           GetNextFontInfo( sal_Handle hFontInfo );
-    static const vcl::FontInfo& GetFontInfo( sal_Handle hFontInfo );
+    const FontMetric&    GetFontName( sal_uInt16 nFont ) const;
+    sal_Handle              GetFirstFontMetric( const OUString& rName ) const;
+    static sal_Handle           GetNextFontMetric( sal_Handle hFontMetric );
+    static const FontMetric& GetFontMetric( sal_Handle hFontMetric );
 
-    const sal_IntPtr*       GetSizeAry( const vcl::FontInfo& rInfo ) const;
+    const sal_IntPtr*       GetSizeAry( const FontMetric& rInfo ) const;
     static const sal_IntPtr* GetStdSizeAry() { return aStdSizeAry; }
 
 private:
diff --git a/include/svtools/stdmenu.hxx b/include/svtools/stdmenu.hxx
index 2a0b46d..299d2e2 100644
--- a/include/svtools/stdmenu.hxx
+++ b/include/svtools/stdmenu.hxx
@@ -26,7 +26,7 @@
 
 class FontList;
 namespace vcl {
-    class FontInfo;
+    class FontMetric;
 }
 
 /*************************************************************************
@@ -132,7 +132,7 @@ public:
     virtual void    Select() override;
     virtual void    Highlight() override;
 
-    void            Fill( const vcl::FontInfo& rInfo, const FontList* pList );
+    void            Fill( const FontMetric& rInfo, const FontList* pList );
 
     void            SetCurHeight( long nHeight );
     long            GetCurHeight() const { return mnCurHeight; }
diff --git a/include/vcl/metric.hxx b/include/vcl/metric.hxx
index fd3759a..57e471c 100644
--- a/include/vcl/metric.hxx
+++ b/include/vcl/metric.hxx
@@ -34,38 +34,18 @@ typedef sal_uInt32 sal_UCS4;
 typedef boost::intrusive_ptr< ImplFontCharMap > ImplFontCharMapPtr;
 typedef boost::intrusive_ptr< FontCharMap > FontCharMapPtr;
 
-namespace vcl {
-
-// avoid problems where poppler's FontInfo is picked up
-class VCL_DLLPUBLIC FontInfo : public vcl::Font
+class VCL_DLLPUBLIC FontMetric : public vcl::Font
 {
-    friend class ::OutputDevice;
 
-protected:
-    ImplFontMetric*     mpImplMetric;    // Implementation
+    friend class ::OutputDevice;
 
 public:
-                        FontInfo();
-                        FontInfo( const FontInfo& );
-                        ~FontInfo();
+                        FontMetric();
+                        FontMetric( const FontMetric& );
+                        ~FontMetric();
 
     FontType            GetType() const;
 
-    FontInfo&           operator=( const FontInfo& );
-    bool                operator==( const FontInfo& ) const;
-    bool                operator!=( const FontInfo& rInfo ) const
-                            { return !operator==( rInfo ); }
-};
-
-}
-
-class VCL_DLLPUBLIC FontMetric : public vcl::FontInfo
-{
-public:
-                        FontMetric() {}
-                        FontMetric( const FontMetric& );
-                        ~FontMetric() {}
-
     long                GetAscent() const;
     long                GetDescent() const;
     long                GetIntLeading() const;
@@ -79,6 +59,8 @@ public:
     bool                operator==( const FontMetric& rMetric ) const;
     bool                operator!=( const FontMetric& rMetric ) const
                             { return !operator==( rMetric ); }
+protected:
+    ImplFontMetric*     mpImplMetric;    // Implementation
 };
 
 template< typename charT, typename traits >
diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx
index 97d26de..cf0b621 100644
--- a/include/vcl/outdev.hxx
+++ b/include/vcl/outdev.hxx
@@ -1249,7 +1249,7 @@ private:
 
 public:
 
-    vcl::FontInfo               GetDevFont( int nDevFontIndex ) const;
+    FontMetric               GetDevFont( int nDevFontIndex ) const;
     int                         GetDevFontCount() const;
 
     bool                        IsFontAvailable( const OUString& rFontName ) const;
diff --git a/sc/source/filter/excel/xehelper.cxx b/sc/source/filter/excel/xehelper.cxx
index dba973b..a179192 100644
--- a/sc/source/filter/excel/xehelper.cxx
+++ b/sc/source/filter/excel/xehelper.cxx
@@ -740,7 +740,7 @@ void XclExpHFConverter::AppendPortion( const EditTextObject* pTextObj, sal_Unico
                     aParaText = "&\"" + OUString(aNewData.maName);
                     if( pFontList )
                     {
-                        vcl::FontInfo aFontInfo( pFontList->Get(
+                        FontMetric aFontInfo( pFontList->Get(
                             aNewData.maName,
                             (aNewData.mnWeight > EXC_FONTWGHT_NORMAL) ? WEIGHT_BOLD : WEIGHT_NORMAL,
                             aNewData.mbItalic ? ITALIC_NORMAL : ITALIC_NONE ) );
diff --git a/sc/source/filter/excel/xistyle.cxx b/sc/source/filter/excel/xistyle.cxx
index 00b1342..2bac326 100644
--- a/sc/source/filter/excel/xistyle.cxx
+++ b/sc/source/filter/excel/xistyle.cxx
@@ -207,7 +207,7 @@ void XclImpFont::SetFontData( const XclFontData& rFontData, bool bHasCharSet )
             {
                 if( const FontList* pFontList = pInfoItem->GetFontList() )
                 {
-                    vcl::FontInfo aFontInfo( pFontList->Get( maData.maName, maData.maStyle ) );
+                    FontMetric aFontInfo( pFontList->Get( maData.maName, maData.maStyle ) );
                     maData.SetScWeight( aFontInfo.GetWeight() );
                     maData.SetScPosture( aFontInfo.GetItalic() );
                 }
diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx
index e043179..8f5d53d 100644
--- a/starmath/source/dialog.cxx
+++ b/starmath/source/dialog.cxx
@@ -2327,7 +2327,7 @@ bool SmSymDefineDialog::SelectSymbol(ComboBox &rComboBox,
 void SmSymDefineDialog::SetFont(const OUString &rFontName, const OUString &rStyleName)
 {
     // get Font (FontInfo) matching name and style
-    vcl::FontInfo aFI;
+    FontMetric aFI;
     if (pFontList)
         aFI = pFontList->Get(rFontName, WEIGHT_NORMAL, ITALIC_NONE);
     SetFontStyle(rStyleName, aFI);
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index 69816b7..ee619c2 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -1037,16 +1037,16 @@ void FontNameBox::Fill( const FontList* pList )
     sal_uInt16 nFontCount = pList->GetFontNameCount();
     for ( sal_uInt16 i = 0; i < nFontCount; i++ )
     {
-        const vcl::FontInfo& rFontInfo = pList->GetFontName( i );
-        sal_uLong nIndex = InsertEntry( rFontInfo.GetName() );
+        const FontMetric& rFontMetric = pList->GetFontName( i );
+        sal_uLong nIndex = InsertEntry( rFontMetric.GetName() );
         if ( nIndex != LISTBOX_ERROR )
         {
             if ( nIndex < mpFontList->size() ) {
                 ImplFontList::iterator it = mpFontList->begin();
                 ::std::advance( it, nIndex );
-                mpFontList->insert( it, rFontInfo );
+                mpFontList->insert( it, rFontMetric );
             } else {
-                mpFontList->push_back( rFontInfo );
+                mpFontList->push_back( rFontMetric );
             }
         }
     }
@@ -1117,7 +1117,7 @@ void FontNameBox::UserDraw( const UserDrawEvent& rUDEvt )
 {
     assert( mpFontList );
 
-    vcl::FontInfo& rInfo = (*mpFontList)[ rUDEvt.GetItemId() ];
+    FontMetric& rInfo = (*mpFontList)[ rUDEvt.GetItemId() ];
     Point aTopLeft = rUDEvt.GetRect().TopLeft();
     long nX = aTopLeft.X();
     long nH = rUDEvt.GetRect().GetHeight();
@@ -1384,8 +1384,8 @@ void FontStyleBox::Fill( const OUString& rName, const FontList* pList )
     Clear();
 
     // does a font with this name already exist?
-    sal_Handle hFontInfo = pList->GetFirstFontInfo( rName );
-    if ( hFontInfo )
+    sal_Handle hFontMetric = pList->GetFirstFontMetric( rName );
+    if ( hFontMetric )
     {
         OUString aStyleText;
         FontWeight  eLastWeight = WEIGHT_DONTKNOW;
@@ -1396,10 +1396,10 @@ void FontStyleBox::Fill( const OUString& rName, const FontList* pList )
         bool        bBold = false;
         bool        bBoldItalic = false;
         bool        bInsert = false;
-        vcl::FontInfo    aInfo;
-        while ( hFontInfo )
+        FontMetric    aInfo;
+        while ( hFontMetric )
         {
-            aInfo = FontList::GetFontInfo( hFontInfo );
+            aInfo = FontList::GetFontMetric( hFontMetric );
 
             FontWeight  eWeight = aInfo.GetWeight();
             FontItalic  eItalic = aInfo.GetItalic();
@@ -1464,7 +1464,7 @@ void FontStyleBox::Fill( const OUString& rName, const FontList* pList )
             else if ( !bBoldItalic && (aStyleText == pList->GetBoldItalicStr()) )
                 bBoldItalic = true;
 
-            hFontInfo = FontList::GetNextFontInfo( hFontInfo );
+            hFontMetric = FontList::GetNextFontMetric( hFontMetric );
         }
 
         if ( bInsert )
@@ -1616,7 +1616,7 @@ void FontSizeBox::Modify()
     }
 }
 
-void FontSizeBox::Fill( const vcl::FontInfo* pInfo, const FontList* pList )
+void FontSizeBox::Fill( const FontMetric* pInfo, const FontList* pList )
 {
     // remember for relative mode
     pFontList = pList;
@@ -1631,7 +1631,7 @@ void FontSizeBox::Fill( const vcl::FontInfo* pInfo, const FontList* pList )
 
     if( pInfo )
     {
-        aFontInfo = *pInfo;
+        aFontMetric = *pInfo;
         pAry = pList->GetSizeAry( *pInfo );
     }
     else
@@ -1778,7 +1778,7 @@ void FontSizeBox::SetRelative( bool bNewRelative )
             SetMax( 9999 );
             SetUnit( FUNIT_POINT );
             if ( pFontList )
-                Fill( &aFontInfo, pFontList );
+                Fill( &aFontMetric, pFontList );
         }
 
         SetText( aStr );
diff --git a/svtools/source/control/ctrltool.cxx b/svtools/source/control/ctrltool.cxx
index 70b30c1..a973ebd 100644
--- a/svtools/source/control/ctrltool.cxx
+++ b/svtools/source/control/ctrltool.cxx
@@ -69,18 +69,18 @@ const sal_IntPtr FontList::aStdSizeAry[] =
     0
 };
 
-class ImplFontListFontInfo : public vcl::FontInfo
+class ImplFontListFontMetric : public FontMetric
 {
     friend class FontList;
 
 private:
     VclPtr<OutputDevice>    mpDevice;
-    ImplFontListFontInfo*   mpNext;
+    ImplFontListFontMetric*   mpNext;
 
 public:
-                            ImplFontListFontInfo( const vcl::FontInfo& rInfo,
+                            ImplFontListFontMetric( const FontMetric& rInfo,
                                                   OutputDevice* pDev ) :
-                                vcl::FontInfo( rInfo ), mpNext(nullptr)
+                                FontMetric( rInfo ), mpNext(nullptr)
                             {
                                 mpDevice = pDev;
                             }
@@ -105,7 +105,7 @@ class ImplFontListNameInfo
 
 private:
     OUString                maSearchName;
-    ImplFontListFontInfo*   mpFirst;
+    ImplFontListFontMetric*   mpFirst;
     FontListFontNameType    mnType;
 
     explicit ImplFontListNameInfo(const OUString& rSearchName)
@@ -126,8 +126,8 @@ static int sortWeightValue(FontWeight eWeight)
     return 0; // eWeight == WEIGHT_NORMAL
 }
 
-static sal_Int32 ImplCompareFontInfo( ImplFontListFontInfo* pInfo1,
-                                          ImplFontListFontInfo* pInfo2 )
+static sal_Int32 ImplCompareFontMetric( ImplFontListFontMetric* pInfo1,
+                                          ImplFontListFontMetric* pInfo2 )
 {
     //Sort non italic before italics
     if ( pInfo1->GetItalic() < pInfo2->GetItalic() )
@@ -253,13 +253,13 @@ void FontList::ImplInsertFonts( OutputDevice* pDevice, bool bAll,
     sal_uInt16  i;
     for( i = 0; i < n; i++ )
     {
-        vcl::FontInfo aFontInfo = pDevice->GetDevFont( i );
+        FontMetric aFontMetric = pDevice->GetDevFont( i );
 
         // ignore raster-fonts if they are not to be displayed
-        if ( !bAll && (aFontInfo.GetType() == TYPE_RASTER) )
+        if ( !bAll && (aFontMetric.GetType() == TYPE_RASTER) )
             continue;
 
-        OUString aSearchName(aFontInfo.GetName());
+        OUString aSearchName(aFontMetric.GetName());
         ImplFontListNameInfo*   pData;
         sal_uLong                   nIndex;
         aSearchName = ImplMakeSearchString(aSearchName);
@@ -269,7 +269,7 @@ void FontList::ImplInsertFonts( OutputDevice* pDevice, bool bAll,
         {
             if ( bInsertData )
             {
-                ImplFontListFontInfo* pNewInfo = new ImplFontListFontInfo( aFontInfo, pDevice );
+                ImplFontListFontMetric* pNewInfo = new ImplFontListFontMetric( aFontMetric, pDevice );
                 pData = new ImplFontListNameInfo( aSearchName );
                 pData->mpFirst      = pNewInfo;
                 pNewInfo->mpNext    = nullptr;
@@ -286,12 +286,12 @@ void FontList::ImplInsertFonts( OutputDevice* pDevice, bool bAll,
             if ( bInsertData )
             {
                 bool                    bInsert = true;
-                ImplFontListFontInfo*   pPrev = nullptr;
-                ImplFontListFontInfo*   pTemp = pData->mpFirst;
-                ImplFontListFontInfo*   pNewInfo = new ImplFontListFontInfo( aFontInfo, pDevice );
+                ImplFontListFontMetric*   pPrev = nullptr;
+                ImplFontListFontMetric*   pTemp = pData->mpFirst;
+                ImplFontListFontMetric*   pNewInfo = new ImplFontListFontMetric( aFontMetric, pDevice );
                 while ( pTemp )
                 {
-                    sal_Int32 eComp = ImplCompareFontInfo( pNewInfo, pTemp );
+                    sal_Int32 eComp = ImplCompareFontMetric( pNewInfo, pTemp );
                     if ( eComp <= 0 )
                     {
                         if ( eComp == 0 )
@@ -301,8 +301,8 @@ void FontList::ImplInsertFonts( OutputDevice* pDevice, bool bAll,
                             if ( (pTemp->GetCharSet() != eSystemEncoding) &&
                                  (pNewInfo->GetCharSet() == eSystemEncoding) )
                             {
-                                ImplFontListFontInfo* pTemp2 = pTemp->mpNext;
-                                *static_cast<vcl::FontInfo*>(pTemp) = *static_cast<vcl::FontInfo*>(pNewInfo);
+                                ImplFontListFontMetric* pTemp2 = pTemp->mpNext;
+                                *static_cast<FontMetric*>(pTemp) = *static_cast<FontMetric*>(pNewInfo);
                                 pTemp->mpNext = pTemp2;
                             }
                             delete pNewInfo;
@@ -370,8 +370,8 @@ FontList::~FontList()
     // delete SizeArray if required
     delete[] mpSizeAry;
 
-    // delete FontInfos
-    ImplFontListFontInfo *pTemp, *pInfo;
+    // delete FontMetrics
+    ImplFontListFontMetric *pTemp, *pInfo;
     for (auto const& it : m_Entries)
     {
         pInfo = it->mpFirst;
@@ -430,7 +430,7 @@ const OUString& FontList::GetStyleName(FontWeight eWeight, FontItalic eItalic) c
     }
 }
 
-OUString FontList::GetStyleName(const vcl::FontInfo& rInfo) const
+OUString FontList::GetStyleName(const FontMetric& rInfo) const
 {
     OUString aStyleName = rInfo.GetStyleName();
     FontWeight eWeight = rInfo.GetWeight();
@@ -481,7 +481,7 @@ OUString FontList::GetStyleName(const vcl::FontInfo& rInfo) const
     return aStyleName;
 }
 
-OUString FontList::GetFontMapText( const vcl::FontInfo& rInfo ) const
+OUString FontList::GetFontMapText( const FontMetric& rInfo ) const
 {
     if ( rInfo.GetName().isEmpty() )
     {
@@ -505,17 +505,17 @@ OUString FontList::GetFontMapText( const vcl::FontInfo& rInfo ) const
         bool                    bNotSynthetic = false;
         FontWeight              eWeight = rInfo.GetWeight();
         FontItalic              eItalic = rInfo.GetItalic();
-        ImplFontListFontInfo*   pFontInfo = pData->mpFirst;
-        while ( pFontInfo )
+        ImplFontListFontMetric*   pFontMetric = pData->mpFirst;
+        while ( pFontMetric )
         {
-            if ( (eWeight == pFontInfo->GetWeight()) &&
-                 (eItalic == pFontInfo->GetItalic()) )
+            if ( (eWeight == pFontMetric->GetWeight()) &&
+                 (eItalic == pFontMetric->GetItalic()) )
             {
                 bNotSynthetic = true;
                 break;
             }
 
-            pFontInfo = pFontInfo->mpNext;
+            pFontMetric = pFontMetric->mpNext;
         }
 
         if ( !bNotSynthetic )
@@ -551,10 +551,10 @@ OUString FontList::GetFontMapText( const vcl::FontInfo& rInfo ) const
 
 namespace
 {
-    vcl::FontInfo makeMissing(ImplFontListFontInfo* pFontNameInfo, const OUString &rName,
+    FontMetric makeMissing(ImplFontListFontMetric* pFontNameInfo, const OUString &rName,
         FontWeight eWeight, FontItalic eItalic)
     {
-        vcl::FontInfo aInfo;
+        FontMetric aInfo;
         // if the fontname matches, we copy as much as possible
         if (pFontNameInfo)
         {
@@ -574,21 +574,21 @@ namespace
     }
 }
 
-vcl::FontInfo FontList::Get(const OUString& rName, const OUString& rStyleName) const
+FontMetric FontList::Get(const OUString& rName, const OUString& rStyleName) const
 {
     ImplFontListNameInfo* pData = ImplFindByName( rName );
-    ImplFontListFontInfo* pFontInfo = nullptr;
-    ImplFontListFontInfo* pFontNameInfo = nullptr;
+    ImplFontListFontMetric* pFontMetric = nullptr;
+    ImplFontListFontMetric* pFontNameInfo = nullptr;
     if ( pData )
     {
-        ImplFontListFontInfo* pSearchInfo = pData->mpFirst;
+        ImplFontListFontMetric* pSearchInfo = pData->mpFirst;
         pFontNameInfo = pSearchInfo;
         pSearchInfo = pData->mpFirst;
         while ( pSearchInfo )
         {
             if (rStyleName.equalsIgnoreAsciiCase(GetStyleName(*pSearchInfo)))
             {
-                pFontInfo = pSearchInfo;
+                pFontMetric = pSearchInfo;
                 break;
             }
 
@@ -597,8 +597,8 @@ vcl::FontInfo FontList::Get(const OUString& rName, const OUString& rStyleName) c
     }
 
     // reproduce attributes if data could not be found
-    vcl::FontInfo aInfo;
-    if ( !pFontInfo )
+    FontMetric aInfo;
+    if ( !pFontMetric )
     {
         FontWeight eWeight = WEIGHT_DONTKNOW;
         FontItalic eItalic = ITALIC_NONE;
@@ -646,7 +646,7 @@ vcl::FontInfo FontList::Get(const OUString& rName, const OUString& rStyleName) c
         aInfo = makeMissing(pFontNameInfo, rName, eWeight, eItalic);
     }
     else
-        aInfo = *pFontInfo;
+        aInfo = *pFontMetric;
 
     // set Fontname to keep FontAlias
     aInfo.SetName( rName );
@@ -655,22 +655,22 @@ vcl::FontInfo FontList::Get(const OUString& rName, const OUString& rStyleName) c
     return aInfo;
 }
 
-vcl::FontInfo FontList::Get(const OUString& rName,
+FontMetric FontList::Get(const OUString& rName,
                         FontWeight eWeight, FontItalic eItalic) const
 {
     ImplFontListNameInfo* pData = ImplFindByName( rName );
-    ImplFontListFontInfo* pFontInfo = nullptr;
-    ImplFontListFontInfo* pFontNameInfo = nullptr;
+    ImplFontListFontMetric* pFontMetric = nullptr;
+    ImplFontListFontMetric* pFontNameInfo = nullptr;
     if ( pData )
     {
-        ImplFontListFontInfo* pSearchInfo = pData->mpFirst;
+        ImplFontListFontMetric* pSearchInfo = pData->mpFirst;
         pFontNameInfo = pSearchInfo;
         while ( pSearchInfo )
         {
             if ( (eWeight == pSearchInfo->GetWeight()) &&
                  (eItalic == pSearchInfo->GetItalic()) )
             {
-                pFontInfo = pSearchInfo;
+                pFontMetric = pSearchInfo;
                 break;
             }
 
@@ -679,11 +679,11 @@ vcl::FontInfo FontList::Get(const OUString& rName,
     }
 
     // reproduce attributes if data could not be found
-    vcl::FontInfo aInfo;
-    if ( !pFontInfo )
+    FontMetric aInfo;
+    if ( !pFontMetric )
         aInfo = makeMissing(pFontNameInfo, rName, eWeight, eItalic);
     else
-        aInfo = *pFontInfo;
+        aInfo = *pFontMetric;
 
     // set Fontname to keep FontAlias
     aInfo.SetName( rName );
@@ -696,14 +696,14 @@ bool FontList::IsAvailable(const OUString& rName) const
     return (ImplFindByName( rName ) != nullptr);
 }
 
-const vcl::FontInfo& FontList::GetFontName( sal_uInt16 nFont ) const
+const FontMetric& FontList::GetFontName( sal_uInt16 nFont ) const
 {
     DBG_ASSERT( nFont < GetFontNameCount(), "FontList::GetFontName(): nFont >= Count" );
 
     return *(m_Entries[nFont]->mpFirst);
 }
 
-sal_Handle FontList::GetFirstFontInfo(const OUString& rName) const
+sal_Handle FontList::GetFirstFontMetric(const OUString& rName) const
 {
     ImplFontListNameInfo* pData = ImplFindByName( rName );
     if ( !pData )
@@ -712,19 +712,19 @@ sal_Handle FontList::GetFirstFontInfo(const OUString& rName) const
         return static_cast<sal_Handle>(pData->mpFirst);
 }
 
-sal_Handle FontList::GetNextFontInfo( sal_Handle hFontInfo )
+sal_Handle FontList::GetNextFontMetric( sal_Handle hFontMetric )
 {
-    ImplFontListFontInfo* pInfo = static_cast<ImplFontListFontInfo*>(hFontInfo);
+    ImplFontListFontMetric* pInfo = static_cast<ImplFontListFontMetric*>(hFontMetric);
     return static_cast<sal_Handle>(pInfo->mpNext);
 }
 
-const vcl::FontInfo& FontList::GetFontInfo( sal_Handle hFontInfo )
+const FontMetric& FontList::GetFontMetric( sal_Handle hFontMetric )
 {
-    ImplFontListFontInfo* pInfo = static_cast<ImplFontListFontInfo*>(hFontInfo);
+    ImplFontListFontMetric* pInfo = static_cast<ImplFontListFontMetric*>(hFontMetric);
     return *pInfo;
 }
 
-const sal_IntPtr* FontList::GetSizeAry( const vcl::FontInfo& rInfo ) const
+const sal_IntPtr* FontList::GetSizeAry( const FontMetric& rInfo ) const
 {
     // first delete Size-Array
     if ( mpSizeAry )
diff --git a/svtools/source/control/stdmenu.cxx b/svtools/source/control/stdmenu.cxx
index 4296dbb..770dc57 100644
--- a/svtools/source/control/stdmenu.cxx
+++ b/svtools/source/control/stdmenu.cxx
@@ -125,7 +125,7 @@ void FontSizeMenu::Highlight()
 {
 }
 
-void FontSizeMenu::Fill( const vcl::FontInfo& rInfo, const FontList* pList )
+void FontSizeMenu::Fill( const FontMetric& rInfo, const FontList* pList )
 {
     Clear();
 
diff --git a/svx/source/mnuctrls/fntszctl.cxx b/svx/source/mnuctrls/fntszctl.cxx
index d6a0c1d..5dfff7a 100644
--- a/svx/source/mnuctrls/fntszctl.cxx
+++ b/svx/source/mnuctrls/fntszctl.cxx
@@ -122,7 +122,7 @@ void SvxFontSizeMenuControl::StateChanged(
 
                     if ( pList )
                     {
-                        vcl::FontInfo aFntInf = pList->Get( pItem->GetFamilyName(),
+                        FontMetric aFntInf = pList->Get( pItem->GetFamilyName(),
                                                        pItem->GetStyleName() );
                         pMenu->Fill( aFntInf, pList );
                     }
diff --git a/svx/source/sidebar/nbdtmg.cxx b/svx/source/sidebar/nbdtmg.cxx
index 78d4a7c..dff849c 100644
--- a/svx/source/sidebar/nbdtmg.cxx
+++ b/svx/source/sidebar/nbdtmg.cxx
@@ -1736,7 +1736,7 @@ bool OutlineTypeMgr::ApplyNumRule(SvxNumRule& aNum, sal_uInt16 nIndex, sal_uInt1
                 }
                 if(pList && pList->IsAvailable( pLevelSettings->sBulletFont ) )
                 {
-                    vcl::FontInfo aInfo = pList->Get(pLevelSettings->sBulletFont,WEIGHT_NORMAL, ITALIC_NONE);
+                    FontMetric aInfo = pList->Get(pLevelSettings->sBulletFont,WEIGHT_NORMAL, ITALIC_NONE);
                     vcl::Font aFont(aInfo);
                     aFmt.SetBulletFont(&aFont);
                 }
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index ae696ae..340bd84 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -1140,7 +1140,7 @@ void SvxFontNameBox_Impl::UserDraw( const UserDrawEvent& rUDEvt )
              fontName = GetEntry(rUDEvt.GetItemId());
         }
         Sequence< PropertyValue > aArgs( 1 );
-        vcl::FontInfo aInfo( pFontList->Get( fontName,
+        FontMetric aInfo( pFontList->Get( fontName,
             aCurFont.GetWeight(),
             aCurFont.GetItalic() ) );
 
@@ -1166,7 +1166,7 @@ void SvxFontNameBox_Impl::Select()
     std::unique_ptr<SvxFontItem> pFontItem;
     if ( pFontList )
     {
-        vcl::FontInfo aInfo( pFontList->Get( GetText(),
+        FontMetric aInfo( pFontList->Get( GetText(),
             aCurFont.GetWeight(),
             aCurFont.GetItalic() ) );
         aCurFont = aInfo;
diff --git a/svx/source/tbxctrls/tbunocontroller.cxx b/svx/source/tbxctrls/tbunocontroller.cxx
index 306b89f..f749f31 100644
--- a/svx/source/tbxctrls/tbunocontroller.cxx
+++ b/svx/source/tbxctrls/tbunocontroller.cxx
@@ -195,7 +195,7 @@ void SvxFontSizeBox_Impl::UpdateFont( const css::awt::FontDescriptor& rCurrentFo
 
     if ( !rCurrentFont.Name.isEmpty() )
     {
-        vcl::FontInfo _aFontInfo;
+        FontMetric _aFontInfo;
         _aFontInfo.SetName( rCurrentFont.Name );
         _aFontInfo.SetStyleName( rCurrentFont.StyleName );
         _aFontInfo.SetHeight( rCurrentFont.Height );
diff --git a/sw/source/core/unocore/unocrsrhelper.cxx b/sw/source/core/unocore/unocrsrhelper.cxx
index 910317c..1bcb2fa 100644
--- a/sw/source/core/unocore/unocrsrhelper.cxx
+++ b/sw/source/core/unocore/unocrsrhelper.cxx
@@ -824,7 +824,7 @@ void setNumberingProperty(const Any& rValue, SwPaM& rPam)
                                                     ->GetItem( SID_ATTR_CHAR_FONTLIST ));
                         const FontList*  pList = pFontListItem->GetFontList();
 
-                        vcl::FontInfo aInfo = pList->Get(
+                        FontMetric aInfo = pList->Get(
                             pBulletFontNames[i],WEIGHT_NORMAL, ITALIC_NONE);
                         vcl::Font aFont(aInfo);
                         aFormat.SetBulletFont(&aFont);
diff --git a/sw/source/core/unocore/unosett.cxx b/sw/source/core/unocore/unosett.cxx
index 16c42bf..7f51bbc 100644
--- a/sw/source/core/unocore/unosett.cxx
+++ b/sw/source/core/unocore/unosett.cxx
@@ -1929,7 +1929,7 @@ void SwXNumberingRules::SetPropertiesToNumFormat(
                                 static_cast<const SvxFontListItem* >(pLclDocShell
                                                     ->GetItem( SID_ATTR_CHAR_FONTLIST ));
                         const FontList*  pList = pFontListItem->GetFontList();
-                        vcl::FontInfo aInfo = pList->Get(
+                        FontMetric aInfo = pList->Get(
                             sBulletFontName, WEIGHT_NORMAL, ITALIC_NONE);
                         vcl::Font aFont(aInfo);
                         aFormat.SetBulletFont(&aFont);
diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx
index 0bfb6b8..87da652 100644
--- a/sw/source/core/unocore/unostyle.cxx
+++ b/sw/source/core/unocore/unostyle.cxx
@@ -1657,7 +1657,7 @@ static void lcl_SetStyleProperty(const SfxItemPropertySimpleEntry& rEntry,
                                         static_cast<const SvxFontListItem*>(pDoc->GetDocShell()
                                                             ->GetItem( SID_ATTR_CHAR_FONTLIST ));
                                 const FontList*  pList = pFontListItem->GetFontList();
-                                vcl::FontInfo aInfo = pList->Get(
+                                FontMetric aInfo = pList->Get(
                                     pBulletFontNames[i],WEIGHT_NORMAL, ITALIC_NONE);
                                 vcl::Font aFont(aInfo);
                                 aFormat.SetBulletFont(&aFont);
diff --git a/sw/source/filter/html/svxcss1.cxx b/sw/source/filter/html/svxcss1.cxx
index 7cfe02d..3113fcc 100644
--- a/sw/source/filter/html/svxcss1.cxx
+++ b/sw/source/filter/html/svxcss1.cxx
@@ -1088,10 +1088,10 @@ static void ParseCSS1_font_family( const CSS1Expression *pExpr,
             {
                 if( !bFound && pFList )
                 {
-                    sal_Handle hFont = pFList->GetFirstFontInfo( aIdent );
+                    sal_Handle hFont = pFList->GetFirstFontMetric( aIdent );
                     if( nullptr != hFont )
                     {
-                        const vcl::FontInfo& rFInfo = FontList::GetFontInfo( hFont );
+                        const FontMetric& rFInfo = FontList::GetFontMetric( hFont );
                         if( RTL_TEXTENCODING_DONTKNOW != rFInfo.GetCharSet() )
                         {
                             bFound = true;
diff --git a/sw/source/filter/html/swhtml.cxx b/sw/source/filter/html/swhtml.cxx
index 7c61701..14c0616 100644
--- a/sw/source/filter/html/swhtml.cxx
+++ b/sw/source/filter/html/swhtml.cxx
@@ -3790,10 +3790,10 @@ void SwHTMLParser::NewFontAttr( int nToken )
             {
                 if( !bFound && pFList )
                 {
-                    sal_Handle hFont = pFList->GetFirstFontInfo( aFName );
+                    sal_Handle hFont = pFList->GetFirstFontMetric( aFName );
                     if( nullptr != hFont )
                     {
-                        const vcl::FontInfo& rFInfo = FontList::GetFontInfo( hFont );
+                        const FontMetric& rFInfo = FontList::GetFontMetric( hFont );
                         if( RTL_TEXTENCODING_DONTKNOW != rFInfo.GetCharSet() )
                         {
                             bFound = true;
diff --git a/sw/source/ui/config/optpage.cxx b/sw/source/ui/config/optpage.cxx
index 2096b5e..6fb20a7 100644
--- a/sw/source/ui/config/optpage.cxx
+++ b/sw/source/ui/config/optpage.cxx
@@ -828,7 +828,7 @@ void SwStdFontTabPage::Reset( const SfxItemSet* rSet)
         int nFontNames = m_pPrt->GetDevFontCount();
         for( int i = 0; i < nFontNames; i++ )
         {
-            vcl::FontInfo aInf( m_pPrt->GetDevFont( i ) );
+            FontMetric aInf( m_pPrt->GetDevFont( i ) );
             aFontNames.insert( aInf.GetName() );
         }
 
@@ -944,7 +944,7 @@ void SwStdFontTabPage::Reset( const SfxItemSet* rSet)
     m_pLabelBox->SetText(sCapBackup );
     m_pIdxBox->SetText(sIdxBackup );
 
-    vcl::FontInfo aFontInfo( m_pFontList->Get(sStdBackup, sStdBackup) );
+    FontMetric aFontInfo( m_pFontList->Get(sStdBackup, sStdBackup) );
     m_pStandardHeightLB->Fill( &aFontInfo, m_pFontList );
     aFontInfo = m_pFontList->Get(sOutBackup, sOutBackup );
     m_pTitleHeightLB->Fill( &aFontInfo, m_pFontList );
@@ -1083,7 +1083,7 @@ IMPL_LINK_TYPED( SwStdFontTabPage, LoseFocusHdl, Control&, rControl, void )
     {
         pHeightLB = m_pIndexHeightLB;
     }
-    vcl::FontInfo aFontInfo( m_pFontList->Get(sEntry, sEntry) );
+    FontMetric aFontInfo( m_pFontList->Get(sEntry, sEntry) );
     pHeightLB->Fill( &aFontInfo, m_pFontList );
 }
 
diff --git a/sw/source/ui/dialog/ascfldlg.cxx b/sw/source/ui/dialog/ascfldlg.cxx
index e92a5c2..b7f8594 100644
--- a/sw/source/ui/dialog/ascfldlg.cxx
+++ b/sw/source/ui/dialog/ascfldlg.cxx
@@ -190,7 +190,7 @@ SwAsciiFilterDlg::SwAsciiFilterDlg( vcl::Window* pParent, SwDocShell& rDocSh,
             int nFontNames = pPrt->GetDevFontCount();
             for( int i = 0; i < nFontNames; i++ )
             {
-                vcl::FontInfo aInf( pPrt->GetDevFont( i ) );
+                FontMetric aInf( pPrt->GetDevFont( i ) );
                 aFontNames.insert( aInf.GetName() );
             }
 
diff --git a/sw/source/uibase/docvw/srcedtw.cxx b/sw/source/uibase/docvw/srcedtw.cxx
index 1c3937c..6f961c2 100644
--- a/sw/source/uibase/docvw/srcedtw.cxx
+++ b/sw/source/uibase/docvw/srcedtw.cxx
@@ -988,7 +988,7 @@ void SwSrcEditWindow::SetFont()
     const SvxFontListItem* pFontListItem =
         static_cast<const SvxFontListItem* >(pSrcView->GetDocShell()->GetItem( SID_ATTR_CHAR_FONTLIST ));
     const FontList*  pList = pFontListItem->GetFontList();
-    vcl::FontInfo aInfo = pList->Get(sFontName,WEIGHT_NORMAL, ITALIC_NONE);
+    FontMetric aInfo = pList->Get(sFontName,WEIGHT_NORMAL, ITALIC_NONE);
 
     const vcl::Font& rFont = GetTextEngine()->GetFont();
     vcl::Font aFont(aInfo);
diff --git a/vcl/source/gdi/metric.cxx b/vcl/source/gdi/metric.cxx
index bf671af..f5c9399 100644
--- a/vcl/source/gdi/metric.cxx
+++ b/vcl/source/gdi/metric.cxx
@@ -68,25 +68,23 @@ bool ImplFontMetric::operator==( const ImplFontMetric& r ) const
     return true;
 }
 
-namespace vcl {
-
-FontInfo::FontInfo()
+FontMetric::FontMetric()
 :   mpImplMetric( new ImplFontMetric )
 {}
 
-FontInfo::FontInfo( const FontInfo& rInfo )
+FontMetric::FontMetric( const FontMetric& rInfo )
 :  Font( rInfo )
 {
     mpImplMetric = rInfo.mpImplMetric;
     mpImplMetric->AddReference();
 }
 
-FontInfo::~FontInfo()
+FontMetric::~FontMetric()
 {
     mpImplMetric->DeReference();
 }
 
-FontInfo& FontInfo::operator=( const FontInfo& rInfo )
+FontMetric& FontMetric::operator=( const FontMetric& rInfo )
 {
     Font::operator=( rInfo );
 
@@ -100,7 +98,7 @@ FontInfo& FontInfo::operator=( const FontInfo& rInfo )
     return *this;
 }
 
-bool FontInfo::operator==( const FontInfo& rInfo ) const
+bool FontMetric::operator==( const FontMetric& rInfo ) const
 {
     if( !Font::operator==( rInfo ) )
         return false;
@@ -111,17 +109,11 @@ bool FontInfo::operator==( const FontInfo& rInfo ) const
     return false;
 }
 
-FontType FontInfo::GetType() const
+FontType FontMetric::GetType() const
 {
     return (mpImplMetric->IsScalable() ? TYPE_SCALABLE : TYPE_RASTER);
 }
 
-}
-
-FontMetric::FontMetric( const FontMetric& rMetric ):
-    vcl::FontInfo( rMetric )
-{}
-
 long FontMetric::GetAscent() const
 {
     return mpImplMetric->GetAscent();
@@ -162,15 +154,4 @@ long FontMetric::GetBulletOffset() const
     return mpImplMetric->GetBulletOffset();
 }
 
-FontMetric& FontMetric::operator =( const FontMetric& rMetric )
-{
-    vcl::FontInfo::operator=( rMetric );
-    return *this;
-}
-
-bool FontMetric::operator==( const FontMetric& rMetric ) const
-{
-    return vcl::FontInfo::operator==( rMetric );
-}
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/source/outdev/font.cxx b/vcl/source/outdev/font.cxx
index e3a44c3..a48926f 100644
--- a/vcl/source/outdev/font.cxx
+++ b/vcl/source/outdev/font.cxx
@@ -62,9 +62,9 @@ using namespace ::com::sun::star::uno;
 using namespace ::rtl;
 using namespace ::utl;
 
-vcl::FontInfo OutputDevice::GetDevFont( int nDevFontIndex ) const
+FontMetric OutputDevice::GetDevFont( int nDevFontIndex ) const
 {
-    vcl::FontInfo aFontInfo;
+    FontMetric aFontInfo;
 
     ImplInitFontList();
 
diff --git a/vcl/workben/svptest.cxx b/vcl/workben/svptest.cxx
index d0e070a..2303f23 100644
--- a/vcl/workben/svptest.cxx
+++ b/vcl/workben/svptest.cxx
@@ -256,7 +256,7 @@ void MyWin::Paint(vcl::RenderContext& rRenderContext, const Rectangle& rRect)
     for (int i = 0; i < nFontSamples; ++i)
     {
 
-        vcl::FontInfo aFont = rRenderContext.GetDevFont((i * nFontCount) / nFontSamples);
+        FontMetric aFont = rRenderContext.GetDevFont((i * nFontCount) / nFontSamples);
         aFont.SetHeight(400 + (i % 7) * 100);
         aFont.SetOrientation(i * (3600 / nFontSamples));
         rRenderContext.SetFont(aFont);


More information about the Libreoffice-commits mailing list