[Libreoffice-commits] core.git: Branch 'libreoffice-5-4' - vcl/win

Tomaž Vajngerl tomaz.vajngerl at collabora.co.uk
Tue Jul 25 20:16:01 UTC 2017


 vcl/win/gdi/winlayout.cxx |    5 +++++
 1 file changed, 5 insertions(+)

New commits:
commit b75ffa19c102d8485bc3b3c6c3a438058aca5dc5
Author: Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
Date:   Tue Jul 25 12:16:34 2017 +0200

    tdf#109281 add fallback to GDI back when we can't bind a DC
    
    Change-Id: Ideae3a5bcacfaadd2cb9d6b014a449d423d332dc
    Reviewed-on: https://gerrit.libreoffice.org/40395
    Reviewed-by: Jan Holesovsky <kendy at collabora.com>
    Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>
    Tested-by: Christian Lohmaier <lohmaier+LibreOffice at googlemail.com>

diff --git a/vcl/win/gdi/winlayout.cxx b/vcl/win/gdi/winlayout.cxx
index 15c4b9730808..aa2992b9cbe0 100644
--- a/vcl/win/gdi/winlayout.cxx
+++ b/vcl/win/gdi/winlayout.cxx
@@ -481,6 +481,11 @@ bool D2DWriteTextOutRenderer::performRender(CommonSalLayout const & rLayout, Sal
         bRetry = true;
         return false;
     }
+    if (FAILED(hr))
+    {
+        // If for any reason we can't bind fallback to legacy APIs.
+        return ExTextOutRenderer()(rLayout, rGraphics, hDC);
+    }
 
     mlfEmHeight = 0;
     if (!GetDWriteFaceFromHDC(hDC, &mpFontFace, &mlfEmHeight))


More information about the Libreoffice-commits mailing list