[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master c7bd76a3f0: Set stipple flag on PGTK as well
From: |
Po Lu |
Subject: |
master c7bd76a3f0: Set stipple flag on PGTK as well |
Date: |
Sun, 8 May 2022 09:10:59 -0400 (EDT) |
branch: master
commit c7bd76a3f02d0a426c85035fd37b0d1a8b6ea5d9
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>
Set stipple flag on PGTK as well
* pgtkterm.c (pgtk_draw_glyph_string_background):
(pgtk_draw_glyph_string): Set stipple flag on string row.
(pgtk_draw_fringe_bitmap):
(pgtk_defined_color): Fix coding style.
---
src/pgtkterm.c | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)
diff --git a/src/pgtkterm.c b/src/pgtkterm.c
index c8c8bd0d85..4d6221d803 100644
--- a/src/pgtkterm.c
+++ b/src/pgtkterm.c
@@ -1333,9 +1333,7 @@ pgtk_draw_glyph_string_background (struct glyph_string
*s, bool force_p)
if (s->stippled_p)
{
/* Fill background with a stipple pattern. */
-
- fill_background (s,
- s->x, s->y + box_line_width,
+ fill_background (s, s->x, s->y + box_line_width,
s->background_width,
s->height - 2 * box_line_width);
s->background_filled_p = true;
@@ -2501,9 +2499,7 @@ pgtk_draw_glyph_string (struct glyph_string *s)
if (s->face->underline_defaulted_p)
pgtk_draw_underwave (s, s->xgcv.foreground);
else
- {
- pgtk_draw_underwave (s, s->face->underline_color);
- }
+ pgtk_draw_underwave (s, s->face->underline_color);
}
else if (s->face->underline == FACE_UNDER_LINE)
{
@@ -2670,6 +2666,11 @@ pgtk_draw_glyph_string (struct glyph_string *s)
}
}
+ /* TODO: figure out in which cases the stipple is actually drawn on
+ PGTK. */
+ if (!s->row->stipple_p)
+ s->row->stipple_p = s->face->stipple;
+
/* Reset clipping. */
pgtk_end_cr_clip (s->f);
s->num_clips = 0;
@@ -3505,9 +3506,7 @@ pgtk_draw_fringe_bitmap (struct window *w, struct
glyph_row *row,
mono-displays, the fill style may have been changed to
FillSolid in pgtk_draw_glyph_string_background. */
if (face->stipple)
- {
- fill_background_by_face (f, face, p->bx, p->by, p->nx, p->ny);
- }
+ fill_background_by_face (f, face, p->bx, p->by, p->nx, p->ny);
else
{
pgtk_set_cr_source_with_color (f, face->background, true);
@@ -6608,9 +6607,9 @@ pgtk_xlfd_to_fontname (const char *xlfd)
}
bool
-pgtk_defined_color (struct frame *f,
- const char *name,
- Emacs_Color * color_def, bool alloc, bool makeIndex)
+pgtk_defined_color (struct frame *f, const char *name,
+ Emacs_Color *color_def, bool alloc,
+ bool makeIndex)
/* --------------------------------------------------------------------------
Return true if named color found, and set color_def rgb accordingly.
If makeIndex and alloc are nonzero put the color in the color_table,
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master c7bd76a3f0: Set stipple flag on PGTK as well,
Po Lu <=