all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Alan Mackenzie <acm@muc.de>
To: emacs-devel@gnu.org
Subject: (pos-visible-in-window-p t nil t) returns wrong position/is suboptimally documented.
Date: Sun, 27 Sep 2015 10:40:41 +0000	[thread overview]
Message-ID: <20150927104041.GA2401@acm.fritz.box> (raw)

Hello Emacs.

In emacs -Q, with a buffer in a window such that there is text in the
window's last line, I run

    M-: (pos-visible-in-window-p t nil t)

.  (Those parameters are in order POS, WINDOW, and PARTIALLY)

The return value is, e.g., (0 64), the X and Y coordinates of the
_beginning_ of the last line.  (On an X window, the result is (0 920).)

With PARTIALLY non-nil, and POS set to t, the function should return the
coordinates of "the last visible position in WINDOW", according to elisp
page "Window Start and End".

I would expect the "last visible position" to mean the _end_ of the last
line, not the beginning.

Which is correct?  The function or the documentation?

-- 
Alan Mackenzie (Nuremberg, Germany).



             reply	other threads:[~2015-09-27 10:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-27 10:40 Alan Mackenzie [this message]
2015-09-27 11:06 ` (pos-visible-in-window-p t nil t) returns wrong position/is suboptimally documented Eli Zaretskii
2015-09-30  7:21   ` Eli Zaretskii
2015-09-30  8:56     ` Alan Mackenzie
2015-09-30  9:32       ` Eli Zaretskii
2015-09-30 10:22         ` Alan Mackenzie
2015-09-30 13:52           ` Eli Zaretskii
2015-09-30 14:05             ` Alan Mackenzie
2015-10-01  7:36           ` Eli Zaretskii

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=20150927104041.GA2401@acm.fritz.box \
    --to=acm@muc.de \
    --cc=emacs-devel@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.