emacs-devel
[Top][All Lists]
Advanced

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

Re: A widget-based version of find-cmd


From: Michael Heerdegen
Subject: Re: A widget-based version of find-cmd
Date: Tue, 04 Jun 2019 00:53:28 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Drew Adams <address@hidden> writes:

> One of the advantages of a dialog box in such contexts
> is setting it and reusing it for multiple search actions
> (interspersed with other, non-search actions).

Currently it's only planned to let the buffers stay alive.  I dunno if I
can save a buffer showing arbitrary widgets?  I guess I would have to
create the widget view from an internal representation, preferably in
the format of a "find" call or the s-exp format used by find-cmd.

What I want to have is an export to these formats so that you can save
the results in these forms.  I guess the reverse should not be too hard.

> In fact, that's about the only advantage I find for such a dialog box.

Another advantage is that it can help you to remember what you have
forgotten.  I for example repeatedly forget that e.g. for

       -ctime n File's status was last changed n*24 hours ago.  See the
              comments for -atime to underÔÇÉ stand how rounding affects
              the interpretation of file status change times.

what I want is

       -n     for less than n,

e.g. -ctime -1 for "status changed since last day" but I tend to try
with -ctime 1 and wonder why it fails until I remember that I need "-".
With the widget based version I can force the user to think about the
sign by making it mandatory (with a reasonable default).

> > I think you're looking for the `lazy` widget.
>
> Or maybe just split it up, having part of it use `repeat'?

`lazy' is perfect.  AFAIU `repeat' won't do since the syntax of "find"
is actually recursive, so there is no way to avoid recursive widgets.

Thanks,

Michael.



reply via email to

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