unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Heime via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 58804@debbugs.gnu.org
Subject: bug#58804: Inconsistency between ruler-mode, fill-column and whitespace-mode
Date: Thu, 27 Oct 2022 06:15:23 +0000	[thread overview]
Message-ID: <Fo67b0hKd3jju8GD5SXivgchuhIMLnZ288IzfHAFdqoAVC7D_wOlA6jDVBAcOu5NKCISjKvC5cdy9chj--Iyy4Zx45hYBzKFuImSjatCfVU=@protonmail.com> (raw)
In-Reply-To: <83lep1n7w1.fsf@gnu.org>

------- Original Message -------
On Thursday, October 27th, 2022 at 5:38 AM, Eli Zaretskii <eliz@gnu.org> wrote:


> > Date: Wed, 26 Oct 2022 20:22:37 +0000
> > From: Heime via "Bug reports for GNU Emacs,
> > the Swiss army knife of text editors" bug-gnu-emacs@gnu.org
> > 
> > Having set both fill-column and whitespace-line-column to 72, I noticed the following.
> > 
> > ruler-mode has the left end marker at column 72
> 
> 
> Do you mean "right end marker"? I see no end marker at the left part
> of the display here, only the ¶ marker at the right.

Right End Marker actually.
 
> > but it should be at column 71 because column numbers start from 0.
> 
> 
> I don't follow: ruler-mode counts columns starting from zero, as
> everything in Emacs. If you move point to a column other than the
> leftmost one, you will see "0" at the left edge of the ruler display.
> So having the marker at column 72 is exactly right.

When one is using a box cursor, it is very confusing.  If one has 
whitespace-style with 'lines-char, the column with the Right Ruler Marker 
gets highlighted.  When users have a box cursor, it is convenient that
the Right Ruler Marker is placed on the last column where it is acceptable
to introduce a last character without exceeding line-column.  Don't have
users always having to remember to add or subtract 1 in their head, but 
have use visual reference for the last valid column.

Perhaps, you could introduce a new marker for that, and decide which one 
to use?  You could have an option to select the starting number, 0 or 1.

Or you might have something better in mind that would work well visually.
Particularly for those of us using box cursor.

> Are you seeing this in "emacs -Q"?
> 
> > Here an improvement would be appreciated. That is, having
> > the ability to show a ruler variant that starts from value 1. When one uses a block cursor,
> > the ruler left marker would then mark exactly column 72. The user will knew that if he inputs
> > the next character he would have reached the line limit and the ruler left marker would coincide
> > with that position.
 
> It sounds like you want column numbers that start from 1, not zero?
> That should be a session-wide mode (if we want such an enhancement),
> since otherwise there could be confusion. We currently support
> one-based column only in the mode-line display under
> column-number-mode. Maybe you have turned that on, which is why you
> think there's a mismatch in ruler-mode?

Yes, to start from 1, not zero - when one uses a "box cursor".  And yes,
I have both ruler-mode, whitespace-mode, and column-number-mode, all three
enabled.  I would appreciate if I could make the necessary customisations
for all three to match.






  reply	other threads:[~2022-10-27  6:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-26 20:22 bug#58804: Inconsistency between ruler-mode, fill-column and whitespace-mode Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-10-27  5:38 ` Eli Zaretskii
2022-10-27  6:15   ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
2022-10-27  6:34     ` Eli Zaretskii
2022-10-27  7:10       ` Heime via Bug reports for GNU Emacs, the Swiss army knife of text editors

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='Fo67b0hKd3jju8GD5SXivgchuhIMLnZ288IzfHAFdqoAVC7D_wOlA6jDVBAcOu5NKCISjKvC5cdy9chj--Iyy4Zx45hYBzKFuImSjatCfVU=@protonmail.com' \
    --to=bug-gnu-emacs@gnu.org \
    --cc=58804@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=heimeborgia@protonmail.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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).