ZTree.com  | ZEN  | About...  

 Index   Back

[ZEP] A general approach - non-destructive fetch   [Q]

By: Ben Kent       
Date: Feb 11,2006 at 23:14
In Response to: [ZEP] A general approach - non-destructive fetch (Slobodan Vujnovic)

> This sounds like adding artificial intelligence to the history fetching
> operation -- Kim will have to check if what is expected is a filename, a
> date, a
> command line, a Rename mask, a batch line mask, etc. Each one would have
> to be
> treated somewhat differently. Too much work that would never end, IMO.

> How about a generic action that gets coded once and lets the user use it
> creatively.

> Today, whatever is fetched from history OVERWRITES the current input
> unconditionally. This happens with both Ctrl+% or Alt+%. I propose the
> following:

> 1. The user hits Insert (the cursor shape will change as usual)
> 2. The subsequent Ctrl+% or Alt+% INSERTS the history entry into the
> prompt, at cursor point. It's a regular PASTE operation we all understand
> and love, but it's not coming from the system Clipboard, but rather from
> ZTree's (40 or so *per* history) clipboards!

> In our example, this would make supplying a batch filename named test.bat
> to a
> prompt work like this:

> The user types:

> test[Insert][Alt+B]

> appending bookmark B (".bat") to "test".

> This would work in ALL histories, making it possible to insert bits
> and pieces as needed. This will give us a new way of building, say, the
> tricky
> Rename patters and line masks (in Batch).

> (Michael, I really have real-life examples ready :-))

> The standard Shift+Ins would continue to work, of course, as well as case
> conversions. ZTree would certainly have one of the most advanced
> line-editing
> functions.

> I use Insert sometimes when editing, so there could be a slight risk if
> the user forgets that Insert is on and end up with a minor mess to clean
> up.
> So, another key could be used, although Insert is so very logical here...
>

If the history pane was moved so that it did not obscure the input prompt, then the | Append history command would be easer to use.

I can see value in what you are proposing, but I can see a couple of issues.

o. There is a danger that as the as there would be no place to put the history Ctrl/Alt-% mode on most of the input prompts, which could cause damage if Alt-% is used and the wrong mode is in effect, because of this I have reservations of implementing Alt-% in insert mode.

o. ZTree by default uses insert mode on the input prompts, what you are suggesting would use the Insert key to toggle the text overwriting mode to overwrite and the Ctrl/Alt-% mode to insert, which is inconsistent, because of this I think that if it is implemented the a different key should be used to activate it.

Ben

1,038 views      
Thread locked
 

Messages in this Thread

 
96,656 Postings in 12,233 Threads, 350 registered users, 70 users online (0 registered, 70 guests)
Index | Admin contact |   Forum Time: May 14, 2024 - 4:31 am UTC  |  Hits:63,451,370  (7,095 Today )
RSS Feed