bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#1032: foreground-color in default-frame-alist affects tooltips, whil


From: martin rudalics
Subject: bug#1032: foreground-color in default-frame-alist affects tooltips, while background-color does not
Date: Fri, 26 Sep 2008 17:14:28 +0200
User-agent: Thunderbird 2.0.0.16 (Windows/20080708)

With

(setq default-frame-alist
      '((background-mode  . dark)
        (background-color . "black")
        (foreground-color . "white")))

the tooltip text foreground is white, but the background is still the
default lightyellow, so the text is not visible.

Does the attached patch fix it?

martin

*** w32fns.c.~1.347.~   2008-09-19 23:24:49.062500000 +0200
--- w32fns.c    2008-09-26 17:10:10.953125000 +0200
***************
*** 5532,5546 ****
       attribute of the frame get's set, which let's the internal border
       of the tooltip frame appear in pink.  Prevent this.  */
    {
      Lisp_Object bg = Fframe_parameter (frame, Qbackground_color);
  
      /* Set tip_frame here, so that */
      tip_frame = frame;
      call2 (Qface_set_after_frame_default, frame, Qnil);
  
!     if (!EQ (bg, Fframe_parameter (frame, Qbackground_color)))
!       Fmodify_frame_parameters (frame, Fcons (Fcons (Qbackground_color, bg),
!                                             Qnil));
    }
  
    f->no_split = 1;
--- 5532,5549 ----
       attribute of the frame get's set, which let's the internal border
       of the tooltip frame appear in pink.  Prevent this.  */
    {
+     Lisp_Object fg = Fframe_parameter (frame, Qforeground_color);
      Lisp_Object bg = Fframe_parameter (frame, Qbackground_color);
  
      /* Set tip_frame here, so that */
      tip_frame = frame;
      call2 (Qface_set_after_frame_default, frame, Qnil);
  
!     if (!EQ (bg, Fframe_parameter (frame, Qbackground_color))
!       || !EQ (fg, Fframe_parameter (frame, Qforeground_color)))
!       Fmodify_frame_parameters (frame, (Fcons (Qforeground_color, fg),
!                                         (Fcons (Qbackground_color, bg),
!                                          Qnil)));
    }
  
    f->no_split = 1;

reply via email to

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