unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Thien-Thi Nguyen <ttn@glug.org>
Subject: Re: (apparently lost, so rewritten and reposted) Re: header-line-format hacking
Date: Mon, 31 Jan 2005 10:54:42 +0100	[thread overview]
Message-ID: <7ek6ptordp.fsf@ada2.unipv.it> (raw)
In-Reply-To: mailman.70.1107140500.2841.help-gnu-emacs@gnu.org

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

  parent reply	other threads:[~2005-01-31  9:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <mailman.15144.1106647267.27204.help-gnu-emacs@gnu.org>
2005-01-25 10:50 ` header-line-format hacking David Hansen
2005-01-25 13:05   ` ytrewq1
     [not found]   ` <mailman.15179.1106660077.27204.help-gnu-emacs@gnu.org>
2005-01-25 18:49     ` Kevin Rodgers
2005-01-26  2:25       ` ytrewq1
     [not found]       ` <mailman.15337.1106708876.27204.help-gnu-emacs@gnu.org>
2005-01-26 11:04         ` Thien-Thi Nguyen
2005-01-26 13:09           ` ytrewq1
     [not found]           ` <mailman.15408.1106746330.27204.help-gnu-emacs@gnu.org>
2005-01-26 14:12             ` Thien-Thi Nguyen
2005-01-31  2:36               ` (apparently lost, so rewritten and reposted) " ytrewq1
     [not found]               ` <mailman.70.1107140500.2841.help-gnu-emacs@gnu.org>
2005-01-31  9:54                 ` Thien-Thi Nguyen [this message]
2005-01-26 23:37             ` Kevin Rodgers
2005-01-30 23:32               ` ytrewq1
2005-01-31 16:18 ` Stefan Monnier
2005-01-31 23:43   ` ytrewq1
     [not found]   ` <mailman.233.1107215940.2841.help-gnu-emacs@gnu.org>
2005-02-01 19:08     ` Stefan Monnier

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=7ek6ptordp.fsf@ada2.unipv.it \
    --to=ttn@glug.org \
    /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.
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).