[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master a1aa9cb: Make overhangs in ftcrfont work on Haiku
From: |
Po Lu |
Subject: |
master a1aa9cb: Make overhangs in ftcrfont work on Haiku |
Date: |
Mon, 29 Nov 2021 02:13:46 -0500 (EST) |
branch: master
commit a1aa9cbf57a08f1c17b92b13a2bf07d504684fcc
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Make overhangs in ftcrfont work on Haiku
* src/ftcrfont.c (ftcrfont_draw): Dump left overhang clipping
on Haiku and always set `background_filled_p'.
---
src/ftcrfont.c | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/src/ftcrfont.c b/src/ftcrfont.c
index 5d75f18..820b3c0 100644
--- a/src/ftcrfont.c
+++ b/src/ftcrfont.c
@@ -539,13 +539,19 @@ ftcrfont_draw (struct glyph_string *s,
return 0;
}
BView_cr_dump_clipping (FRAME_HAIKU_VIEW (f), cr);
+
+ if (s->left_overhang && s->clip_head && !s->for_overlaps)
+ {
+ cairo_rectangle (cr, s->clip_head->x, 0,
+ FRAME_PIXEL_WIDTH (f), FRAME_PIXEL_HEIGHT (f));
+ cairo_clip (cr);
+ }
#endif
if (with_background)
{
#ifndef USE_BE_CAIRO
x_set_cr_source_with_gc_background (f, s->gc);
- s->background_filled_p = 1;
#else
struct face *face = s->face;
@@ -556,6 +562,7 @@ ftcrfont_draw (struct glyph_string *s,
GREEN_FROM_ULONG (col) / 255.0,
BLUE_FROM_ULONG (col) / 255.0);
#endif
+ s->background_filled_p = 1;
cairo_rectangle (cr, x, y - FONT_BASE (face->font),
s->width, FONT_HEIGHT (face->font));
cairo_fill (cr);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master a1aa9cb: Make overhangs in ftcrfont work on Haiku,
Po Lu <=