From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#73401: [PATCH] Make window dividers and internal border respect alpha background Date: Sat, 28 Sep 2024 13:20:21 +0300 Message-ID: <864j606pwa.fsf@gnu.org> References: Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="12034"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 73401@debbugs.gnu.org To: Garklein , Po Lu Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Sep 28 12:22:07 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1suUaU-0002yT-1V for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 28 Sep 2024 12:22:06 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1suUa0-0003SY-19; Sat, 28 Sep 2024 06:21:36 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1suUZx-0003RE-F3 for bug-gnu-emacs@gnu.org; Sat, 28 Sep 2024 06:21:33 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1suUZx-00066L-6C for bug-gnu-emacs@gnu.org; Sat, 28 Sep 2024 06:21:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=References:In-Reply-To:From:Date:To:Subject; bh=rh2ljKX786hCssdjlCEzwZt6XkxHuXddfzx3mTqphaA=; b=GVYkdAQ+pOd6t3zEeU5Xg81Jd73bqgaU/gtGLhaFAdVUuTyq4kG3ToPIT8aq2diloTzBaxGJAvW0w427fETKoQZUNCYgAkdlY/yRYhVMA+hjeNNWs8v3LJrW8l2OVJeDqkUdwi1x525YPiXdFQr8PYFJCO0ITyBr29JCUTT8vyAoKeQd/IPPy6Mg9G6oidrY66fF5IqLJ8cX/A90i1sRZNAHscQ/NnMYiM2XOU6o4mjyLnBLVT3GYiqqSJwatXFOD8ZrCHc1xz0PHZ71IH83A/ZETBfGdTnKeJQjeHlH0GkzQvVyE+1l5nL2AvYQziisc0oRSlKc59hnOfPd/TyMmQ==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1suUaQ-0002P9-Lr for bug-gnu-emacs@gnu.org; Sat, 28 Sep 2024 06:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 28 Sep 2024 10:22:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73401 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 73401-submit@debbugs.gnu.org id=B73401.17275188639092 (code B ref 73401); Sat, 28 Sep 2024 10:22:02 +0000 Original-Received: (at 73401) by debbugs.gnu.org; 28 Sep 2024 10:21:03 +0000 Original-Received: from localhost ([127.0.0.1]:51889 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1suUZT-0002Ma-0n for submit@debbugs.gnu.org; Sat, 28 Sep 2024 06:21:03 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:50674) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1suUZQ-0002Lw-MN for 73401@debbugs.gnu.org; Sat, 28 Sep 2024 06:21:01 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1suUYr-00061n-Dy; Sat, 28 Sep 2024 06:20:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=rh2ljKX786hCssdjlCEzwZt6XkxHuXddfzx3mTqphaA=; b=XMWkW324Zogi E8d43GIhdtkJRdXmFeRhqfOi2PJQfm0sKTl/rCxESV790WsJwPp1+y/+ptnzlpwDNxLFY/7j7NIgH TlMERNGDLZHsKKES3Z1kjIB9ZolsMZQbiYQ3BZXTWH47e9d47u5DUNMGh08xBWIG6Fp6aXHTvNuOx 6Oa+s3lPupZh5r3k+dpASktONJY6TWKsr2I7+6KvQiMBd2c5x/wNa1uxMElrU98SdRSmH/GwiFewa nYYxUOJ0JtHQtrdlwjfmCFA9EZu9He8Irn3DuhDiK8Npn8DIkFuxDp3lsoaAzRwlhjYgbLR2emk1t zHYB9cm3zWAr1RFkQ24cRg==; In-Reply-To: (message from Garklein on Fri, 20 Sep 2024 14:25:14 -0400) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:292563 Archived-At: > From: Garklein > Date: Fri, 20 Sep 2024 14:25:14 -0400 > > I'm using EXWM with thick window dividers and internal borders. These > areas currently aren't affected by the alpha-background frame > parameter, which looks very ugly. I can't think of any reasons why > anyone would want this, so I think it's just an oversight. This patch > just makes them respect it. Thanks. Po Lu, any comments? > diff --git a/src/xterm.c b/src/xterm.c > index 0c20d38..7f665d8 100644 > --- a/src/xterm.c > +++ b/src/xterm.c > @@ -7497,13 +7497,13 @@ x_draw_window_divider (struct window *w, int x0, int x1, int y0, int y1) > { > XSetForeground (display, f->output_data.x->normal_gc, color_first); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0, y0, 1, y1 - y0, false); > + x0, y0, 1, y1 - y0, true); > XSetForeground (display, f->output_data.x->normal_gc, color); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0 + 1, y0, x1 - x0 - 2, y1 - y0, false); > + x0 + 1, y0, x1 - x0 - 2, y1 - y0, true); > XSetForeground (display, f->output_data.x->normal_gc, color_last); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x1 - 1, y0, 1, y1 - y0, false); > + x1 - 1, y0, 1, y1 - y0, true); > } > else if ((x1 - x0 > y1 - y0) && (y1 - y0 >= 3)) > /* A horizontal divider, at least three pixels high: Draw first and > @@ -7511,13 +7511,13 @@ x_draw_window_divider (struct window *w, int x0, int x1, int y0, int y1) > { > XSetForeground (display, f->output_data.x->normal_gc, color_first); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0, y0, x1 - x0, 1, false); > + x0, y0, x1 - x0, 1, true); > XSetForeground (display, f->output_data.x->normal_gc, color); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0, y0 + 1, x1 - x0, y1 - y0 - 2, false); > + x0, y0 + 1, x1 - x0, y1 - y0 - 2, true); > XSetForeground (display, f->output_data.x->normal_gc, color_last); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0, y1 - 1, x1 - x0, 1, false); > + x0, y1 - 1, x1 - x0, 1, true); > } > else > { > @@ -7525,7 +7525,7 @@ x_draw_window_divider (struct window *w, int x0, int x1, int y0, int y1) > differently. */ > XSetForeground (display, f->output_data.x->normal_gc, color); > x_fill_rectangle (f, f->output_data.x->normal_gc, > - x0, y0, x1 - x0, y1 - y0, false); > + x0, y0, x1 - x0, y1 - y0, true); > } > } > > @@ -7732,11 +7732,11 @@ x_clear_under_internal_border (struct frame *f) > GC gc = f->output_data.x->normal_gc; > > XSetForeground (display, gc, color); > - x_fill_rectangle (f, gc, 0, margin, width, border, false); > - x_fill_rectangle (f, gc, 0, 0, border, height, false); > - x_fill_rectangle (f, gc, width - border, 0, border, height, false); > + x_fill_rectangle (f, gc, 0, margin, width, border, true); > + x_fill_rectangle (f, gc, 0, 0, border, height, true); > + x_fill_rectangle (f, gc, width - border, 0, border, height, true); > x_fill_rectangle (f, gc, 0, height - bottom_margin - border, > - width, border, false); > + width, border, true); > XSetForeground (display, gc, FRAME_FOREGROUND_PIXEL (f)); > } > else