unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Keith David Bershatsky <esq@lawlist.com>
Cc: david.reitter@gmail.com, alan@idiocy.org, andlind@gmail.com,
	29233@debbugs.gnu.org
Subject: bug#29233: Enable fringe cursor when *almost* exact_window_width_line_p
Date: Sun, 12 Nov 2017 06:10:58 +0200	[thread overview]
Message-ID: <8360agnnl9.fsf@gnu.org> (raw)
In-Reply-To: <m2tvy0bg3x.wl%esq@lawlist.com> (message from Keith David Bershatsky on Sat, 11 Nov 2017 14:33:22 -0800)

> Date:  Sat, 11 Nov 2017 14:33:22 -0800
> From:  Keith David Bershatsky <esq@lawlist.com>
> Cc:  Alan Third <alan@idiocy.org>,Anders Lindgren <andlind@gmail.com>,David Reitter <david.reitter@gmail.com>,Martin Rudalics <rudalics@gmx.at>,29233@debbugs.gnu.org
> 
> The crux of the issue raised with #29233 is whether users might wish to see a fringe bitmap instead of a partial width cursor when point is slightly less than the exact window width.  Whereas the patches relating to #16856 reduce the width of the cursor so that it does not overflow into the fringe (creating unwanted artifacts), there was nothing done to permit a fringe bitmap to be placed there instead.
> 
> I had not given any consideration to the possibility that a partial width cursor is "a feature".  I.e., I erroneously assumed that a partial width cursor was merely an attempt to avoid unwanted artifacts being drawn on the fringe.
> 
> I personally like to see fringe bitmaps when points is slightly less than the exact widow width; however, I am uncertain how to reconcile that proposed feature with the desire by others to see a partial width cursor without a fringe bitmap.

The part of the display code that deals with the cursor on the fringes
is insanely complicated.  It's part of the code which deals with the
following features:

 . "normal" display of the cursor at the end of a line
 . showing the cursor on the right (or left, for RTL lines) fringe
   when a line fits in the window exactly
 . showing the continuation/truncation bitmaps on the fringes
 . showing the continuation/truncation glyphs in the text area when
   the fringes are disabled
 . displaying a TAB or any other stretch of white space that extends
   beyond the window edge
 . all of the above, when lines are wrapped (word-wrap is non-nil)
 . most of the above on TTY frames

(I could be forgetting some use cases.)  Each one of these needs
special considerations in the move_it_* functions, because those
functions need to support all of those correctly.

Adding any more complexity to what we already have on our hands is IMO
only justified for some significant features.  The proposed one seems
to be only of aesthetic value, so I don't think we should complicate
the display code more than it already is on this behalf.

> If the consensus is that a user who has a window-width that is not an integral multiple of frame's character width must give up the ability to see a fringe bitmap, then that resolves #29233.

It's not just the window being the integral multiple, it's _any_
situation where some space is available between the right edge of the
last glyph and the window edge.  Don't forget that Emacs supports
variable-pitch fonts and can display glyphs from different fonts on
the same line, which will almost always leave some fractional space at
the end of the line.

I don't know if this is the consensus, but I just don't think we
should go there.





  reply	other threads:[~2017-11-12  4:10 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-23 21:39 bug#16856: 24.3.50; Cursor leaves garbage in fringe (and a request: width of fringes + scroll bar should be full characters) Anders Lindgren
2014-02-24  3:44 ` Eli Zaretskii
2014-02-24  7:41 ` martin rudalics
2014-02-24 10:12   ` Anders Lindgren
2014-02-24 10:53     ` martin rudalics
2014-02-24 15:12       ` Anders Lindgren
2014-02-26 10:15         ` martin rudalics
2014-02-26 12:51           ` Anders Lindgren
2016-05-17 18:30       ` Alan Third
2016-05-17 19:06         ` Anders Lindgren
2016-05-17 21:14           ` bug#16856: [PATCH] Prevent cursor from over-drawing the fringe Alan Third
2016-05-20 19:33             ` Anders Lindgren
2016-05-21  7:35               ` Alan Third
2016-05-21 19:07                 ` Anders Lindgren
2016-07-17  6:57 ` bug#16856: 24.3.50; Cursor leaves garbage in fringe David Reitter
2017-11-09 18:50 ` bug#16856: Enable fringe cursor when *almost* exact_window_width_line_p Keith David Bershatsky
2017-11-09 18:58   ` bug#29233: " Keith David Bershatsky
2017-11-09 22:11   ` Alan Third
2017-11-10  7:53     ` bug#16856: " Eli Zaretskii
2017-11-11 16:34       ` Anders Lindgren
2017-11-11 17:25         ` Eli Zaretskii
2017-11-11 17:49           ` Anders Lindgren
2017-11-11 18:46             ` Alan Third
2017-11-11 20:36               ` Anders Lindgren
2017-11-10  0:31   ` bug#29233: " Keith David Bershatsky
2017-11-11 22:33   ` Keith David Bershatsky
2017-11-12  4:10     ` Eli Zaretskii [this message]
2017-12-12 23:24       ` Noam Postavsky
2017-11-09 19:00 ` bug#16856: Cursor leaves garbage in fringe Keith David Bershatsky

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=8360agnnl9.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=29233@debbugs.gnu.org \
    --cc=alan@idiocy.org \
    --cc=andlind@gmail.com \
    --cc=david.reitter@gmail.com \
    --cc=esq@lawlist.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).