Ihor Radchenko <[email protected]> writes:

> "J.D. Smith" <[email protected]> writes:
>
>>> 1. It would be nice to support pretty entities
>>
>> As I understand them, pretty entities use composition properties, so
>> unlike emphasized text and links, point can /never/ fall inside them —
>> it will always skip from one side to the other.  So there is no "point
>> ambiguity".  Really then only unhiding pretty entities would make sense,
>> but I don't anticipate making unhiding the default (note: we should
>> discuss the defaults).  Open to other thoughts.
>
> Right.
> I think of the problems with composition (and, similarly, with links and
> emphasis) is when point is just outside the hidden boundaries, and user
> attempts deleting forward/backward. The cursor shape is not quite enough
> then to understand what will, say, backward-kill-word will do.

But that ambiguity is only true for partially hidden text, where point
adjustment can present exactly the same apparent cursor position on
screen for two different buffer positions.  For composition, this is
impossible.  A cursor adjacent to an \alpha will always be "outside" it,
so editing will be predictable.  backward-kill-word will kill the hidden
entity (modulo your syntax table word entry).

>>> 2. There was a question whether there is much point
>>>    changing the cursor or revealing hidden markers when the text is
>>>    read-only. Might be a user option to consider
>>
>> I don't think it hurts to have it on, but it's easy to add things to a
>> buffer-local `read-only-mode-hook' if they'd like to disable some
>> features.
>
> I am not talking about read-only-mode, but about read-only regions of
> text. We may have situations when /some/ text is read-only. For example,
> in the WIP org-pending library.

I see.  I guess we could skip applying the `cursor-sensor-functions'
property to such text, but then there might be a font lock race.  Is the
idea that the /lack/ of appearance change would be a subtle signal of
its own: this text is not editable?  Let's revisit when it's an issue.

Reply via email to