all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Markus Triska <triska@metalevel.at>
Cc: 34038@debbugs.gnu.org, acm@muc.de
Subject: bug#34038: 26.1; set-window-start sometimes fails to set window start
Date: Thu, 28 Mar 2019 18:21:53 +0200	[thread overview]
Message-ID: <83pnqbj7fi.fsf@gnu.org> (raw)
In-Reply-To: <874l7sxczx.fsf@metalevel.at> (message from Markus Triska on Sun,  24 Mar 2019 20:56:34 +0100)

> From: Markus Triska <triska@metalevel.at>
> Cc: rudalics@gmx.at,  acm@muc.de,  34038@debbugs.gnu.org
> Date: Sun, 24 Mar 2019 20:56:34 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > describing what you thought should have happened here, step by step,
> 
> My expectation is that, when the snippet terminates with the message
> that window-start is unexpectedly at a position different from 1, and I
> *then* do:
> 
>     M-: (set-window-start nil 1) RET
> 
> that the window-start is set to 1. However, in such cases, at least on
> my machine and in the cases I found, the window start is *not* set to 1,
> but unexpectedly retained at a position different from 1.

This is actually quite expected: you cannot rely on set-window-start
to always produce what you want, if the start position doesn't
guarantee that point will be on a fully visible line.  If with the
start point you set point is not fully visible, redisplay is free not
to obey that start point.  It does make an attempt to use the start
point you provide and move point into the view-port, but the attempt
is half-hearted, and is likely to fail when the size of the default
face's font is different from the frame's default font, because the
last screen line of the window is then typically only partially
visible.

Can you describe what you are trying to achieve by using
set-window-start?  It's somewhat unusual to use that API without also
moving point accordingly.





  reply	other threads:[~2019-03-28 16:21 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-10 19:57 bug#34038: 26.1; set-window-start sometimes fails to set window start Markus Triska
2019-01-11  7:03 ` Eli Zaretskii
2019-01-11 12:20   ` Markus Triska
2019-01-11 13:36     ` Eli Zaretskii
2019-01-11 14:31       ` Markus Triska
2019-01-11 15:10         ` martin rudalics
2019-01-11 17:45           ` Markus Triska
2019-01-11 19:07             ` Eli Zaretskii
2019-01-12  8:12             ` martin rudalics
2019-01-12 13:25               ` Markus Triska
2019-01-12 13:53                 ` Eli Zaretskii
2019-01-12 14:12                 ` martin rudalics
2019-01-12 19:08                   ` Markus Triska
2019-01-12 20:28                     ` Eli Zaretskii
2019-01-11 21:23     ` Alan Mackenzie
2019-01-12  8:13       ` martin rudalics
2019-01-12 18:22         ` Alan Mackenzie
2019-01-12 20:29           ` Eli Zaretskii
2019-01-12 20:42             ` Alan Mackenzie
2019-01-13  3:30               ` Eli Zaretskii
2019-01-13  7:32       ` Markus Triska
2019-01-13  8:40         ` martin rudalics
2019-01-13 11:32           ` Eli Zaretskii
2019-01-13 13:40             ` martin rudalics
2019-01-13 15:21               ` Eli Zaretskii
2019-03-24 10:35                 ` Markus Triska
2019-03-24 17:28                   ` Eli Zaretskii
2019-03-24 19:56                     ` Markus Triska
2019-03-28 16:21                       ` Eli Zaretskii [this message]
2019-03-29  7:16                         ` Markus Triska
2019-03-29  8:29                           ` Eli Zaretskii
2019-04-06  8:23                             ` Eli Zaretskii
     [not found] <<m2ftu05lqv.fsf@metalevel.at>
     [not found] ` <<83sgxzhe04.fsf@gnu.org>
2019-01-11 16:37   ` Drew Adams
2019-01-11 16:49     ` 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=83pnqbj7fi.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=34038@debbugs.gnu.org \
    --cc=acm@muc.de \
    --cc=triska@metalevel.at \
    /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.