all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Noam Postavsky <npostavs@gmail.com>
To: Andrea Cardaci <cyrus.and@gmail.com>
Cc: Juanma Barranquero <lekktu@gmail.com>,
	36421@debbugs.gnu.org, Pip Cet <pipcet@gmail.com>
Subject: bug#36421: Having some text with face height > 1.0 causes scroll-step to be ignored
Date: Thu, 04 Jul 2019 16:11:18 -0400	[thread overview]
Message-ID: <85lfxdef15.fsf@gmail.com> (raw)
In-Reply-To: <CACMsj9NC4c3SswVqOjjzjgGeKz2TMX5Dyo1w0jWUbjx-ZpA7tQ@mail.gmail.com> (Andrea Cardaci's message of "Sun, 30 Jun 2019 00:43:07 +0200")

Andrea Cardaci <cyrus.and@gmail.com> writes:

>> If you have a lot of higher-than-default lines, and you don't like the
>> effect of scroll-conservatively, then my suggestion is to set
>> scroll-conservatively to 2 or 3.
>
> It's much better this way (set to 2), there are still some
> *unpleasant* moments where the point is not exactly on the bottom (by
> a fraction of line height) and some others where the point is scrolled
> up by one entire line. But I guess this unavoidable, maybe I should
> just stop worrying and love the recentering...

It looks like scroll-down-line does the right thing, maybe a wrapping
command like this would work for you:

    (defun previous-and-maybe-scroll-line (&optional arg)
      (interactive "^p")
      (when (< (line-beginning-position 0) (window-start))
        (condition-case ()
            (scroll-down-line arg)
          (beginning-of-buffer nil))) 
      (previous-line arg))

    (define-key global-map [up] 'previous-and-maybe-scroll-line)

    ;; Corresponding [down] command left as exercise for reader





  reply	other threads:[~2019-07-04 20:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-28 16:19 bug#36421: Having some text with face height > 1.0 causes scroll-step to be ignored Andrea Cardaci
2019-06-28 21:11 ` Pip Cet
2019-06-28 23:29   ` Andrea Cardaci
2019-06-29  7:35     ` Eli Zaretskii
2019-06-29 19:55       ` Juanma Barranquero
2019-06-29 22:43         ` Andrea Cardaci
2019-07-04 20:11           ` Noam Postavsky [this message]
2019-06-30 14:55         ` Eli Zaretskii
2019-06-30 17:07           ` Juanma Barranquero
2019-09-16  3:08       ` Stefan Kangas

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=85lfxdef15.fsf@gmail.com \
    --to=npostavs@gmail.com \
    --cc=36421@debbugs.gnu.org \
    --cc=cyrus.and@gmail.com \
    --cc=lekktu@gmail.com \
    --cc=pipcet@gmail.com \
    /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.