[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Box cursor at EoL
From: |
Dr Rainer Woitok |
Subject: |
Re: Box cursor at EoL |
Date: |
Sun, 9 Oct 2022 17:31:55 +0200 |
Stefan,
On Saturday, 2022-10-08 09:18:03 -0400, you wrote:
> ...
> > Does that mean that even though there is a way to maintain a frame spe-
> > cific cursor appearance there is no way to maintain a window specific
> > one? :-(
>
> Exactly: both the `cursor-type` variable and the `cursor-type`
> frame-parameters are used by the redisplay code to decide how to draw
> the cursor. But the redisplay code does not look at any
> window-parameter for that, so you can't change the cursor-shape on
> a "per window" basis :-(
>
> Maybe it's time for `M-x report-emacs-bug` and request a new feature.
Well, before I request a feature more or less only benefitting me but
turning out to require a total redesign of Emacs I'd like to first con-
tinue this discussion here :-)
1. Am I correct in assuming that when I request to display a buffer in a
new frame this will also create a new window in that new frame?
If this were true, I could forget frames and just search for a way to
make use of the `cursor-type´ windows parameter, because this would
also solve the "same buffer in another frame" case.
2. Running `C-h v cursor-type´ returns
cursor-type is a variable defined in `C source code´.
Its value is t
Cursor to use when this buffer is in the selected window.
Values are interpreted as follows:
t use the cursor specified for the frame
nil don't display a cursor
box display a filled box cursor
(box . SIZE) display a filled box cursor, but make it
hollow if cursor is under masked image larger than
SIZE pixels in either dimension.
hollow display a hollow box cursor
bar display a vertical bar cursor with default width
(bar . WIDTH) display a vertical bar cursor with width WIDTH
hbar display a horizontal bar cursor with default height
(hbar . HEIGHT) display a horizontal bar cursor with height HEIGHT
ANYTHING ELSE display a hollow box cursor
WIDTH and HEIGHT can't exceed the frame’s canonical character size.
When the buffer is displayed in a non-selected window, the
cursor's appearance is instead controlled by the variable
`cursor-in-non-selected-windows´.
Automatically becomes buffer-local when set.
You can customize this variable.
Probably introduced at or before Emacs version 21.1.
That clearly states that this buffer local variable either allows to
use no cursor, a locally defined cursor specification or the cursor
specification for the frame, but nothing else.
So I'd suggest extending the above list of special values for buffer lo-
cal variable `cursor-type´ with
frame use the cursor specified for the frame (same as
t but with improved documentation value for hu-
man readers)
window use the cursor specified for the window
and to add these two additional alternatives for the value of buffer lo-
cal variable `cursor-type´ to every relevant evaluation of it.
But since buffer local variable `cursor-type´ is defined in `C source
code´, there is no easy way for me to receive an impression of how much
effort this change would require.
Comments anybody?
Sincerely,
Rainer
- Re: Box cursor at EoL, (continued)
- Re: Box cursor at EoL, Dr Rainer Woitok, 2022/10/07
- Re: Box cursor at EoL, Eli Zaretskii, 2022/10/07
- Re: Box cursor at EoL, Robert Pluim, 2022/10/07
- Re: Box cursor at EoL, Dr Rainer Woitok, 2022/10/07
- Re: Box cursor at EoL, Eli Zaretskii, 2022/10/07
- Re: Box cursor at EoL, Dr Rainer Woitok, 2022/10/08
- Re: Box cursor at EoL, Eli Zaretskii, 2022/10/08
- Re: Box cursor at EoL, Dr Rainer Woitok, 2022/10/08
- Re: Box cursor at EoL, Eli Zaretskii, 2022/10/08
- Re: Box cursor at EoL, Stefan Monnier, 2022/10/08
- Re: Box cursor at EoL,
Dr Rainer Woitok <=
Re: Box cursor at EoL, Eli Zaretskii, 2022/10/05
Re: Box cursor at EoL, Dr Rainer Woitok, 2022/10/06
Re: Box cursor at EoL, Emanuel Berg, 2022/10/06
Re: Box cursor at EoL, Anders Munch, 2022/10/18