From: "Drew Adams" <drew.adams@oracle.com>
To: <emacs-pretest-bug@gnu.org>
Subject: bug#3602: 23.0.94; window-line-height problems
Date: Wed, 17 Jun 2009 22:39:55 -0700 [thread overview]
Message-ID: <1AF1CC9F5E1C4E168A7584390EEDC74D@us.oracle.com> (raw)
The behavior of this function seems broken, at least for LINE =
mode-line or header-line. And the doc is not good.
Doc string of `window-line-height' says this:
"Return height of current line if LINE is omitted or nil. Return
height of header or mode line if LINE is `header-line' and
`mode-line'."
That seems to say that if you have a header line, then you can get its
height in pixels this way (window-line-height 'header-line), and
similarly for mode-line. But that doesn't seem to work.
emacs -Q
(setq Info-use-header-line t)
C-h i
M-: (window-line-height 'header-line) returns nil
M-: (window-line-height 'mode-line) returns nil
This part of the doc string is incomprehensible to me:
"Return nil if window display is not up-to-date." What does that mean?
And then it says "In that case, use `pos-visible-in-window-p' to
obtain the information." How to do that? What args to use with
`pos-visible-in-window-p', to find out the `window-line-height' for
the header-line, for instance? This paragraph is quite unclear to me.
Also, the function is called *-height, and the first part of the doc
string says that it returns the "height in pixels". But later in the
doc string we learn that the value (returned, presumably) is a list
(HEIGHT VPOS YPOS OFFBOT). That's contradictory. If the height in
pixels is returned, that is presumably an integer, not a list.
The Elisp manual repeats all of the confusion and other defects of the
doc string. In fact, it is almost verbatim the same text.
In GNU Emacs 23.0.94.1 (i386-mingw-nt5.1.2600)
of 2009-05-24 on SOFT-MJASON
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4)'
next reply other threads:[~2009-06-18 5:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-18 5:39 Drew Adams [this message]
2014-02-10 3:33 ` bug#3602: 23.0.94; window-line-height problems Lars Ingebrigtsen
2014-02-10 8:14 ` martin rudalics
2014-02-10 8:18 ` Lars Ingebrigtsen
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1AF1CC9F5E1C4E168A7584390EEDC74D@us.oracle.com \
--to=drew.adams@oracle.com \
--cc=3602@emacsbugs.donarmstrong.com \
--cc=emacs-pretest-bug@gnu.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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.