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

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

Re: change the background color of a single window


From: Dieter Wilhelm
Subject: Re: change the background color of a single window
Date: Tue, 19 Dec 2006 15:27:38 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux)

"Juanma Barranquero" <lekktu@gmail.com> writes:

> On 12/19/06, Dieter Wilhelm <dieter@duenenhof-wilhelm.de> wrote:
>
>> (I
>> wanted to show a helper window in the frame with another background to
>> distinguish the windows better while saving the mode line space);
>
> With a little elisp programming you could try using overlays. You can
> use one overlay over the whole buffer, and you could even limit the
> overlay to only being visible in a particular window (so other windows
> showing the same buffer would not display the overlay's effects).
>
> (let ((ov (make-overlay (point-min) (point-max) nil nil t)))
>   (overlay-put ov 'window (get-buffer-window MY-BUFFER))
>   (overlay-put ov 'face MY-BACKGROUND-FACE))
>
> Be sure to have a \n at the end of the last line, and it should work
> reasonably enough, I think.
>

Good idea, this might be the way to proceed. I'll try it, thanks.

-- 
    Best wishes

    H. Dieter Wilhelm
    Darmstadt, Germany




reply via email to

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