vcl/win/gdi/salfont.cxx | 16 ---------------- 1 file changed, 16 deletions(-)
New commits: commit 1dc1729183ac2e8ba9abf067dac38f39a3a5454a Author: Mike Kaganski <mike.kagan...@collabora.com> AuthorDate: Wed Apr 10 22:47:57 2024 +0500 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Thu Apr 11 09:26:51 2024 +0200 Drop old Windows 95/98/ME problem workaround KB305290 (broken link https://support.microsoft.com/en-us/help/305290) was for these long-unsupported systems. Change-Id: Ie2e3814d24ceb5d014c0bff1a39b3d6675e3603c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/165981 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx index 51ddcce741b7..a98d82c6b8a4 100644 --- a/vcl/win/gdi/salfont.cxx +++ b/vcl/win/gdi/salfont.cxx @@ -753,19 +753,6 @@ std::tuple<HFONT,bool,sal_Int32> WinSalGraphics::ImplDoSetFont(HDC hDC, vcl::fon } hNewFont = ::CreateFontIndirectW( &aLogFont ); - - HDC hdcScreen = nullptr; - if( mbVirDev ) - // only required for virtual devices, see below for details - hdcScreen = GetDC(nullptr); - if( hdcScreen ) - { - // select font into screen hdc first to get an antialiased font - // and instantly restore the default font! - // see knowledge base article 305290: - // "PRB: Fonts Not Drawn Antialiased on Device Context for DirectDraw Surface" - SelectFont( hdcScreen, SelectFont( hdcScreen , hNewFont ) ); - } o_rOldFont = ::SelectFont(hDC, hNewFont); TEXTMETRICW aTextMetricW; @@ -782,9 +769,6 @@ std::tuple<HFONT,bool,sal_Int32> WinSalGraphics::ImplDoSetFont(HDC hDC, vcl::fon bIsCJKVerticalFont = false; } - if( hdcScreen ) - ::ReleaseDC( nullptr, hdcScreen ); - return std::make_tuple(hNewFont, bIsCJKVerticalFont, static_cast<sal_Int32>(aTextMetricW.tmDescent)); }