bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#18793: 24.4; zero width rectangular selection displaces text


From: Eli Zaretskii
Subject: bug#18793: 24.4; zero width rectangular selection displaces text
Date: Fri, 06 May 2022 16:50:23 +0300

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: monnier@iro.umontreal.ca,  carlosjosepita@gmail.com,  
> 18793@debbugs.gnu.org
> Date: Fri, 06 May 2022 14:52:25 +0200
> 
> > Adding capabilities to the Emacs display that operate on
> > sub-character-cell resolution will mean serious complications.  For
> > example, what would we do when displaying color Emoji at that place?
> > Or what about images?  Or what if the character in question is
> > currently highlighted by mouse-face?
> >
> > IOW, I'm asking whether these marginal features are worth a serious
> > surgery and complications in the display engine, which currently has
> > the canvas-based design?
> 
> display-fill-column-indicator-mode was the only one that sprang
> immediately to mind, but I think it could be useful when displaying
> tabular data, and you want to mark boundaries without taking up extra
> space, for instance.

I think trying to display text in tables without taking space for the
borders will introduce significant complications into our display
code.  Text in a table and its borders need to be aligned separately.

> And speaking off the fill indicator -- bug#54598 talks a bit about the
> problems with the current implementation.

Sure, there are limitations to how we can stretch our current display
code.  But the solution is not to stretch it more, IMNSHO, it's to
replace it with a completely new and different design, which could
allow that much more easily.

> But that mode does show how a box cursor and a region could behave
> with these vertical lines.

It does?  AFAIK, we don't show the vertical line when there's a
character at that column, and consequently displaying the cursor
doesn't need to cope with any issues caused by that.

> And I don't think colour emojis or images would represent that much of a
> problem -- I think we'd draw the line on top of the glyph?

The line itself is not the problem; the problem is the color of that
line.  How do you draw a vertical line of a given color over images
and Emoji that have their inherent colors?  Do we just overwrite those
colors?  Won't that be ugly?

There will also be complications with characters whose glyphs "invade"
cells of neighboring characters: Emacs draws characters one by one, so
adding such vertical lines will need to come back after text was drawn
and draw the line, as opposed to doing that as part of drawing
individual glyphs that we do now.

Bottom line: it sounds like a lot of complications for a minor issue
with a minor feature.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]