[Libreoffice-commits] core.git: vcl/win

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Tue Aug 21 19:35:55 UTC 2018


 vcl/win/gdi/salfont.cxx |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

New commits:
commit 99fc650d519f78e3866ce119c7d3640a070e88c5
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Aug 21 09:05:05 2018 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Aug 21 21:35:33 2018 +0200

    pass GetFontFace at call site
    
    Change-Id: Id2677cdc386e51ae1549c548c06d095ad0f43b40
    Reviewed-on: https://gerrit.libreoffice.org/59385
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx
index c4970b0ce9b4..a51a06a0d4c4 100644
--- a/vcl/win/gdi/salfont.cxx
+++ b/vcl/win/gdi/salfont.cxx
@@ -765,9 +765,6 @@ void ImplGetLogFontFromFontSelect( HDC hDC,
                                    LOGFONTW& rLogFont )
 {
     OUString aName;
-    if (!pFontFace && pFont->mpFontInstance)
-        pFontFace = pFont->mpFontInstance->GetFontFace();
-
     if (pFontFace)
         aName = pFontFace->GetFamilyName();
     else
@@ -942,7 +939,7 @@ void WinSalGraphics::SetFont(LogicalFontInstance* pFont, int nFallbackLevel)
     mpWinFontEntry[ nFallbackLevel ] = reinterpret_cast<WinFontInstance*>(pFont);
 
     HFONT hOldFont = nullptr;
-    HFONT hNewFont = ImplDoSetFont(pFont->GetFontSelectPattern(), nullptr, mfFontScale[ nFallbackLevel ], hOldFont);
+    HFONT hNewFont = ImplDoSetFont(pFont->GetFontSelectPattern(), pFont->GetFontFace(), mfFontScale[ nFallbackLevel ], hOldFont);
     mfCurrentFontScale = mfFontScale[nFallbackLevel];
 
     if( !mhDefFont )


More information about the Libreoffice-commits mailing list