[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Inhibiting read-only
From: |
Lars Magne Ingebrigtsen |
Subject: |
Re: Inhibiting read-only |
Date: |
Thu, 20 Jun 2013 10:44:25 +0200 |
User-agent: |
Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.3.50 (gnu/linux) |
Stefan Monnier <address@hidden> writes:
> LMI> I'd like to make the eww buffers read-only, but leave text input
> LMI> fields editable. (And then do processing of the alterations with
> LMI> `insert-behind-hooks' or `after-change-functions'.)
>> That sounds like how the Customize buffers work, yes?
>
> Exactly, they set buffer-read-only to nil but then use
> a before-change-function to signal an error when trying to modify
> a non-text-widget area.
I like `read-only' buffers -- they have an obvious interface. If the
user decides to switch read-only off (which I sometimes do in otherwise
non-editable buffers) to do some weird ad-hoc editing, there's a
standard, convenient key-stroke for that.
So if there were a `inhibit-read-only' text property, we could avoid
doing all these tricks with `before-change-function' and the like -- we
could just make the buffer read-only, put the text property on the bits
that aren't read-only, and we'd be done. And there would be less user
confusion.
I can have a go at implementing this if it sounds like a workable idea,
although that part of the code is completely unfamiliar to me...
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog http://lars.ingebrigtsen.no/
Re: Inhibiting read-only, Juanma Barranquero, 2013/06/19
Re: Inhibiting read-only, James Cloos, 2013/06/19
- Re: Inhibiting read-only, Lars Magne Ingebrigtsen, 2013/06/19
- Re: Inhibiting read-only, Stefan Monnier, 2013/06/19
- Re: Inhibiting read-only, Eli Zaretskii, 2013/06/20
- Re: Inhibiting read-only, Lars Magne Ingebrigtsen, 2013/06/20
- Re: Inhibiting read-only, Eli Zaretskii, 2013/06/20
- Re: Inhibiting read-only, Lars Magne Ingebrigtsen, 2013/06/20
- Re: Inhibiting read-only, Eli Zaretskii, 2013/06/20
- Re: Inhibiting read-only, Lars Magne Ingebrigtsen, 2013/06/20
- Re: Inhibiting read-only, Eli Zaretskii, 2013/06/20
Re: Inhibiting read-only, Stephen J. Turnbull, 2013/06/21