[pango] Win32: Fix background rect bounds
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pango] Win32: Fix background rect bounds
- Date: Sat, 8 Apr 2017 01:55:00 +0000 (UTC)
commit 8de443dd9f426c325673d029786618da9476f6a0
Author: Nicolas Hake <nh nosebud de>
Date: Mon Jul 11 13:27:31 2016 +0200
Win32: Fix background rect bounds
Rectangle() uses x1, y1, x2, y2 coordinates instead of x, y, w, h. Fix
the coordinates passed to the function so it draws the background in the
correct location.
https://bugzilla.gnome.org/show_bug.cgi?id=768679
pango/pangowin32.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/pango/pangowin32.c b/pango/pangowin32.c
index 1abe333..f25ceac 100644
--- a/pango/pangowin32.c
+++ b/pango/pangowin32.c
@@ -1059,8 +1059,8 @@ pango_win32_render_layout_line (HDC hdc,
old_pen = SelectObject (hdc, GetStockObject (NULL_PEN));
Rectangle (hdc, x + PANGO_PIXELS (x_off + logical_rect.x),
y + PANGO_PIXELS (overall_rect.y),
- PANGO_PIXELS (logical_rect.width),
- PANGO_PIXELS (overall_rect.height));
+ 1 + x + PANGO_PIXELS (x_off + logical_rect.x + logical_rect.width),
+ 1 + y + PANGO_PIXELS (overall_rect.y + overall_rect.height));
SelectObject (hdc, old_brush);
DeleteObject (bg_brush);
SelectObject (hdc, old_pen);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]