diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-08-15 17:24:28 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-08-26 00:36:58 +0200 |
commit | 100fe8a3a1724f1a5f834da11e17d1641be20994 (patch) | |
tree | 2eabb9bb131e6f099d815bd7e9069c207f658603 /drawinglayer | |
parent | 33c6dcfaab35a70f8794a67d31fbec636cb485d5 (diff) |
automatically set TextRenderModeForResolutionIndependentLayout if we scale
Always render glyphs with a mode suitable for rendering of
resolution-independent layout positions if we scale the text positions.
The idea being to typically continue to use the system defaults for font
settings for UI elements, but where we are rendering into application
canvases where there's a mapmode set then automatically use a good mode
to render that.
Change-Id: I0e5857e377da72ae1a2ede1d88d6408819fc9200
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138324
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'drawinglayer')
-rw-r--r-- | drawinglayer/source/processor2d/vclpixelprocessor2d.cxx | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx b/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx index fe2f30cbf23a..5e0612f94a93 100644 --- a/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx +++ b/drawinglayer/source/processor2d/vclpixelprocessor2d.cxx @@ -75,12 +75,9 @@ namespace drawinglayer::processor2d struct VclPixelProcessor2D::Impl { AntialiasingFlags m_nOrigAntiAliasing; - bool m_bOrigTextRenderModeForResolutionIndependentLayout; explicit Impl(OutputDevice const& rOutDev) : m_nOrigAntiAliasing(rOutDev.GetAntialiasing()) - , m_bOrigTextRenderModeForResolutionIndependentLayout( - rOutDev.GetTextRenderModeForResolutionIndependentLayout()) { } }; @@ -107,9 +104,6 @@ VclPixelProcessor2D::VclPixelProcessor2D(const geometry::ViewInformation2D& rVie { mpOutputDevice->SetAntialiasing(m_pImpl->m_nOrigAntiAliasing & ~AntialiasingFlags::Enable); } - - // tdf#150462 set text render mode to suit use of resolution independent text layout - mpOutputDevice->SetTextRenderModeForResolutionIndependentLayout(true); } VclPixelProcessor2D::~VclPixelProcessor2D() @@ -119,9 +113,6 @@ VclPixelProcessor2D::~VclPixelProcessor2D() // restore AntiAliasing mpOutputDevice->SetAntialiasing(m_pImpl->m_nOrigAntiAliasing); - - mpOutputDevice->SetTextRenderModeForResolutionIndependentLayout( - m_pImpl->m_bOrigTextRenderModeForResolutionIndependentLayout); } void VclPixelProcessor2D::tryDrawPolyPolygonColorPrimitive2DDirect( |