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

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

Re: (apparently lost, so rewritten and reposted) Re: header-line-format


From: Thien-Thi Nguyen
Subject: Re: (apparently lost, so rewritten and reposted) Re: header-line-format hacking
Date: Mon, 31 Jan 2005 10:54:42 +0100
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/21.3.50 (gnu/linux)

ytrewq1 <ytrewq1@gmail.com> writes:

> Thanks for the explanation.

well, looks like the explanation did not cover this case...

> I think I understand how this approach could work for
> mode-line-format as it's default value is non-nil.  However,
> on my system, header-line-format has a default value of
> nil.  As far as I can tell, if a buffer's header-line-format 
> value is modified to be non-nil a header is displayed -- so
> if a buffer starts out w/ a header-line-format value of nil
> and minor mode code modifies it to be non-nil, deactivation
> of the minor mode will cause the buffer to have an empty
> header line ("baggage").
>
> Is there a way to avoid this "baggage" using the idiomatic
> approach?

i see in dispextern.h that the macro WINDOW_WANTS_HEADER_LINE_P
only checks that `header-line-format' is non-nil; there is no
provision to conditionally display the header line based on its
contents.

thus, there is no way to use the same idiom as in the mode line,
as you have correctly surmised.  thanks for motivating me to look
at the code more closely.  probably you can lop off my part of
the thread thus far and replace it simply w/ "yes" as a response
to your original question, w/o incident.

thi

reply via email to

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