diff options
| author | Neil <nyamatongwe@gmail.com> | 2021-03-20 18:12:55 +1100 |
|---|---|---|
| committer | Neil <nyamatongwe@gmail.com> | 2021-03-20 18:12:55 +1100 |
| commit | a926652af980db3abcdef3e8ecb78a763327a1ae (patch) | |
| tree | 09cdcf8184842773069c697270cba15368771ecd /win32 | |
| parent | 2b8ea578dc6e59d11384d3253b7d06ce55330182 (diff) | |
| download | scintilla-mirror-a926652af980db3abcdef3e8ecb78a763327a1ae.tar.gz | |
Replace FillRectangle with FillRectangleAligned as FillRectangle will stop
aligning to pixel boundaries.
Use Surface::SetMode as simpler and its predecessors will be removed.
Diffstat (limited to 'win32')
| -rw-r--r-- | win32/PlatWin.cxx | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx index 34f4faa49..1e6dd06b4 100644 --- a/win32/PlatWin.cxx +++ b/win32/PlatWin.cxx @@ -2676,7 +2676,7 @@ void SurfaceD2D::DrawTextCommon(PRectangle rc, const Font *font_, XYPOSITION yba void SurfaceD2D::DrawTextNoClip(PRectangle rc, const Font *font_, XYPOSITION ybase, std::string_view text, ColourAlpha fore, ColourAlpha back) { if (pRenderTarget) { - FillRectangle(rc, back); + FillRectangleAligned(rc, back); D2DPenColourAlpha(fore); DrawTextCommon(rc, font_, ybase, text, codePageText, ETO_OPAQUE); } @@ -2685,7 +2685,7 @@ void SurfaceD2D::DrawTextNoClip(PRectangle rc, const Font *font_, XYPOSITION yba void SurfaceD2D::DrawTextClipped(PRectangle rc, const Font *font_, XYPOSITION ybase, std::string_view text, ColourAlpha fore, ColourAlpha back) { if (pRenderTarget) { - FillRectangle(rc, back); + FillRectangleAligned(rc, back); D2DPenColourAlpha(fore); DrawTextCommon(rc, font_, ybase, text, codePageText, ETO_OPAQUE | ETO_CLIPPED); } @@ -2807,7 +2807,7 @@ XYPOSITION SurfaceD2D::WidthText(const Font *font_, std::string_view text) { void SurfaceD2D::DrawTextNoClipUTF8(PRectangle rc, const Font *font_, XYPOSITION ybase, std::string_view text, ColourAlpha fore, ColourAlpha back) { if (pRenderTarget) { - FillRectangle(rc, back); + FillRectangleAligned(rc, back); D2DPenColourAlpha(fore); DrawTextCommon(rc, font_, ybase, text, SC_CP_UTF8, ETO_OPAQUE); } @@ -2816,7 +2816,7 @@ void SurfaceD2D::DrawTextNoClipUTF8(PRectangle rc, const Font *font_, XYPOSITION void SurfaceD2D::DrawTextClippedUTF8(PRectangle rc, const Font *font_, XYPOSITION ybase, std::string_view text, ColourAlpha fore, ColourAlpha back) { if (pRenderTarget) { - FillRectangle(rc, back); + FillRectangleAligned(rc, back); D2DPenColourAlpha(fore); DrawTextCommon(rc, font_, ybase, text, SC_CP_UTF8, ETO_OPAQUE | ETO_CLIPPED); } |
