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

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

Re: Interactively edit a list of strings


From: Ben Bacarisse
Subject: Re: Interactively edit a list of strings
Date: Mon, 23 Jul 2018 02:05:57 +0100

Joe Riel <joer@san.rr.com> writes:

> Am looking for a good way to interactively edit a list of strings,
> that is, to allow the user to selectively delete strings from the list.
> Any suggestions on how to implement this?  
>
> My first thought is to write each string on a separate line in a
> temporary buffer, allow the user to edit that, then reassemble the
> buffer into a list, however, that isn't ideal, it allows too much
> freedom to modify the content.  I could restrict the allowable
> commands to deleting lines, but am wondering if there is a better way.

You might consider using widgets:

https://www.gnu.org/software/emacs/manual/html_mono/widget.html

You could write the strings as an "editable-list" widget without the
[INS] buttons so only a [DEL] button available.

-- 
Ben.


reply via email to

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