unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Robert Pluim <rpluim@gmail.com>
To: martin rudalics <rudalics@gmx.at>
Cc: Tjernlund <tjernlund@tjernlund.se>, 32975@debbugs.gnu.org
Subject: bug#32975: Emacs 26.1; GTK Warnings
Date: Thu, 11 Oct 2018 14:26:38 +0200	[thread overview]
Message-ID: <87efcw3c01.fsf@gmail.com> (raw)
In-Reply-To: <5BBF3BD1.4080204@gmx.at> (martin rudalics's message of "Thu, 11 Oct 2018 14:02:25 +0200")

martin rudalics <rudalics@gmx.at> writes:

>> There is only one call to xg_set_background_color, from xfns.c, which looks
>> like this with my patch applied:
>>
>> #ifdef USE_TOOLKIT_SCROLL_BARS
>> # ifdef USE_GTK
>>        xg_set_background_color (f, bg);
>> # endif
>> #else
>>
>> So it will only ever happen when the scrollbars are GTK widgets.
>
> But this effectively throws out the baby - painting the background of
> the frame widget proper via
>
>       xg_set_widget_bg (f, FRAME_GTK_WIDGET (f), FRAME_BACKGROUND_PIXEL (f));
>
> with the bathwater - painting the background of non-existent scroll
> bar widgets via
>
>           xg_set_widget_bg (f, webox, FRAME_BACKGROUND_PIXEL (f));
>
> for GTK builds with native Emacs scroll bars.

Iʼm being particularly dense today: youʼre right. How about moving the
check for USE_TOOLKIT_SCROLL_BARS down into xg_set_background_color
like so (which I think was your original suggestion):

diff --git i/src/gtkutil.c w/src/gtkutil.c
index 6b72671da9..5879ab683e 100644
--- i/src/gtkutil.c
+++ w/src/gtkutil.c
@@ -1498,6 +1498,7 @@ xg_set_background_color (struct frame *f, unsigned long bg)
       block_input ();
       xg_set_widget_bg (f, FRAME_GTK_WIDGET (f), FRAME_BACKGROUND_PIXEL (f));
 
+#ifdef USE_TOOLKIT_SCROLL_BARS
       Lisp_Object bar;
       for (bar = FRAME_SCROLL_BARS (f);
            !NILP (bar);
@@ -1508,7 +1509,7 @@ xg_set_background_color (struct frame *f, unsigned long bg)
           GtkWidget *webox = gtk_widget_get_parent (scrollbar);
           xg_set_widget_bg (f, webox, FRAME_BACKGROUND_PIXEL (f));
         }
-
+#endif
       unblock_input ();
     }
 }







  reply	other threads:[~2018-10-11 12:26 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-07 18:19 bug#32975: Emacs 26.1; GTK Warnings Tjernlund
2018-10-07 19:03 ` Eli Zaretskii
2018-10-08  5:27   ` Tjernlund
2018-10-09 15:10     ` Eli Zaretskii
2018-10-09 18:01       ` Tjernlund
2018-10-09 18:18         ` Eli Zaretskii
2018-10-09 18:33           ` Tjernlund
2018-10-09 19:13             ` Eli Zaretskii
2018-10-10  8:04               ` Robert Pluim
2018-10-10  8:46                 ` martin rudalics
2018-10-10 10:08                   ` Robert Pluim
2018-10-10 17:44                     ` Tjernlund
2018-10-11  6:27                       ` Robert Pluim
2018-10-11  7:35                         ` Robert Pluim
2018-10-11  8:24                           ` martin rudalics
2018-10-11  8:33                             ` Robert Pluim
2018-10-11  8:58                               ` martin rudalics
2018-10-11  9:22                                 ` Robert Pluim
2018-10-11  9:32                                   ` martin rudalics
2018-10-11  9:50                                     ` Robert Pluim
2018-10-11 12:02                                       ` martin rudalics
2018-10-11 12:26                                         ` Robert Pluim [this message]
2018-10-11 13:51                                           ` martin rudalics
2018-10-11 14:06                                             ` Robert Pluim
2018-10-11 14:25                                               ` Eli Zaretskii
2018-10-13  8:46                                                 ` Robert Pluim
2018-10-11 19:43                                               ` Tjernlund
2018-10-11 19:51                                                 ` Tjernlund
2018-10-11 21:04                                                   ` martin rudalics
2018-10-11 21:54                                                     ` Tjernlund
2018-10-12  4:28                                                       ` Eli Zaretskii
2018-10-12  5:31                                                         ` Tjernlund
2018-10-12  6:36                                                           ` Eli Zaretskii
     [not found]                                                             ` <1539444400.8755.38.camel@tjernlund.se>
2018-10-14  2:36                                                               ` Eli Zaretskii
     [not found]                                                                 ` <1539505906.8755.41.camel@tjernlund.se>
2018-10-14 14:57                                                                   ` Eli Zaretskii
2018-10-14 15:22                                                                     ` Tjernlund
2018-10-14 16:02                                                                       ` Eli Zaretskii
2018-10-14 20:00                                                                         ` Tjernlund
2018-10-12  8:44                                                       ` martin rudalics
2018-10-11 13:58                           ` Eli Zaretskii
2018-10-11 17:10                             ` martin rudalics

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87efcw3c01.fsf@gmail.com \
    --to=rpluim@gmail.com \
    --cc=32975@debbugs.gnu.org \
    --cc=rudalics@gmx.at \
    --cc=tjernlund@tjernlund.se \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).