emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 71de48494e: Set GC line width on more GCs


From: Po Lu
Subject: master 71de48494e: Set GC line width on more GCs
Date: Thu, 5 May 2022 09:05:36 -0400 (EDT)

branch: master
commit 71de48494e9024243d4c8b8847c50c0b5c0ac16f
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>

    Set GC line width on more GCs
    
    * src/xterm.c (x_set_cursor_gc, x_set_mouse_face_gc)
    (x_draw_bar_cursor): Make created scratch GCs have a line-width
    of 1.
---
 src/xterm.c | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/src/xterm.c b/src/xterm.c
index 285b1d625e..80d34c114d 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -6044,7 +6044,10 @@ x_set_cursor_gc (struct glyph_string *s)
 
       IF_DEBUG (x_check_font (s->f, s->font));
       xgcv.graphics_exposures = False;
-      mask = GCForeground | GCBackground | GCGraphicsExposures;
+      xgcv.line_width = 1;
+      mask = (GCForeground | GCBackground
+             | GCGraphicsExposures
+             | GCLineWidth);
 
       if (FRAME_DISPLAY_INFO (s->f)->scratch_cursor_gc)
        XChangeGC (display, FRAME_DISPLAY_INFO (s->f)->scratch_cursor_gc,
@@ -6076,7 +6079,11 @@ x_set_mouse_face_gc (struct glyph_string *s)
       xgcv.background = s->face->background;
       xgcv.foreground = s->face->foreground;
       xgcv.graphics_exposures = False;
-      mask = GCForeground | GCBackground | GCGraphicsExposures;
+      xgcv.line_width = 1;
+
+      mask = (GCForeground | GCBackground
+             | GCGraphicsExposures
+             | GCLineWidth);
 
       if (FRAME_DISPLAY_INFO (s->f)->scratch_cursor_gc)
        XChangeGC (display, FRAME_DISPLAY_INFO (s->f)->scratch_cursor_gc,
@@ -19832,6 +19839,9 @@ x_draw_bar_cursor (struct window *w, struct glyph_row 
*row, int width, enum text
       else
        xgcv.background = xgcv.foreground = f->output_data.x->cursor_pixel;
       xgcv.graphics_exposures = False;
+      xgcv.line_width = 1;
+
+      mask |= GCLineWidth;
 
       if (gc)
        XChangeGC (dpy, gc, mask, &xgcv);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]