diff options
author | Nicolas Hake <nh@nosebud.de> | 2016-07-11 13:22:05 +0200 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2017-04-07 21:54:29 -0400 |
commit | 72e16506d6bd43efe4db24ebc3f69537f7208b1a (patch) | |
tree | b1e8487e7fa7106eb47fa26e8dfc486fb9264030 /pango/pangowin32.c | |
parent | f7927ff53afb8bbfdf7cc8f7b621c811f53ac6c5 (diff) | |
download | pango-72e16506d6bd43efe4db24ebc3f69537f7208b1a.tar.gz |
Win32: Reset BkMode so ETO doesn't draw its own
If the DC's background mode is set to OPAQUE, ExtTextOut will draw its
own background boxes around glyph items. Since we don't place any
requirements on the DC, set the background mode to TRANSPARENT before
rendering any glyphs (and reset it to its original value afterwards).
https://bugzilla.gnome.org/show_bug.cgi?id=768679
Diffstat (limited to 'pango/pangowin32.c')
-rw-r--r-- | pango/pangowin32.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/pango/pangowin32.c b/pango/pangowin32.c index d39cf8b5..04e0d51e 100644 --- a/pango/pangowin32.c +++ b/pango/pangowin32.c @@ -1020,6 +1020,7 @@ pango_win32_render_layout_line (HDC hdc, PangoRectangle overall_rect; PangoRectangle logical_rect; PangoRectangle ink_rect; + int oldbkmode = SetBkMode (hdc, TRANSPARENT); int x_off = 0; @@ -1145,6 +1146,8 @@ pango_win32_render_layout_line (HDC hdc, x_off += logical_rect.width; } + + SetBkMode (hdc, oldbkmode); } /** |