all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Keith David Bershatsky <esq@lawlist.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Distinguishing: Temporary v. Semi-Permanent -- Horizontal Scrolling
Date: Mon, 02 Jul 2018 19:44:36 -0700	[thread overview]
Message-ID: <m2muv9vy0b.wl%esq@lawlist.com> (raw)

As far as I am aware, there are four (4) basic situations that I need to be aware of in terms of horizontal scrolling:

1a.  Temporary Horizontal Scrolling:  (scroll-left 1)
1b.  Current line is horizontally scrolled the same as all other lines.

2a.  Temporary Horizontal Scrolling:  (scroll-left 1)
2b.  Current line is horizontally scrolled _differently_ than all other lines.
2c.  Assumes (setq-local auto-hscroll-mode 'current-line)

3a.  Semi-permanent Horizontal Scrolling:  (scroll-left 1 t)
3b.  Current line is horizontally scrolled the same as all other lines.

4a.  Semi-permanent Horizontal Scrolling:  (scroll-left 1 t)
4b.  Current line is horizontally scrolled _differently_ than all other lines.
4c.  Assumes (setq-local auto-hscroll-mode 'current-line)

In a previous post, you taught me that (it->w->min_hscroll > 0) tells us that semi-permanent horizontal scrolling is in effect.

I have been using the following hscl test for the 2nd situation above:

  bool hscl = (!it->w->suspend_auto_hscroll
               && EQ (Fbuffer_local_value (Qauto_hscroll_mode, buf), Qcurrent_line)
               && it->w->hscroll > 0);

The hscl test is _true_ for the 2nd, 3rd and 4th situations above.  Thus, the hscl test does not help us distinguish between the 3rd and 4th situations above.

Q:  In addition to (it->w->min_hscroll > 0), what test will help us distinguish between the 3rd and 4th situations above?



             reply	other threads:[~2018-07-03  2:44 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-03  2:44 Keith David Bershatsky [this message]
2018-07-03 19:29 ` Distinguishing: Temporary v. Semi-Permanent -- Horizontal Scrolling Eli Zaretskii
  -- strict thread matches above, loose matches on Subject: below --
2018-07-04 13:56 Keith David Bershatsky
2018-07-03 20:20 Keith David Bershatsky
2018-07-04  2:33 ` Eli Zaretskii
2018-06-24 17:31 Keith David Bershatsky
2018-06-24 16:16 Keith David Bershatsky
2018-06-24 16:40 ` Eli Zaretskii
2018-06-24  3:49 Keith David Bershatsky
2018-06-24 14:26 ` 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=m2muv9vy0b.wl%esq@lawlist.com \
    --to=esq@lawlist.com \
    --cc=eliz@gnu.org \
    --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.