Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Setting the cursor position upon completion



Thanks for the answer, Max.
I should have mentioned that I don't want to give up on the MENU_COMPLETE option. I like having a match inserted immediately after the first TAB hit. It's just where the cursor is set on this match that bothers me.

Here is an example:
Let's say the current directory contains three files called "fileone", "filetwo" and "thirdfile".
The '^' character marks the cursor position I'm looking for.

cat ./[TAB] would become
cat ./fileone
      ^

cat ./fi[TAB] would become
cat ./fileone
          ^

cat ./file[TAB] would become
cat ./fileone
          ^

cat ./fileo[TAB] would become
cat ./fileone
             ^

The default behaviour always moves the cursor to the end of the match, like the last case.

Best regards,
Julien


      _____________________________________________________________________________ 
Envoyez avec Yahoo! Mail. Une boite mail plus intelligente http://mail.yahoo.fr



Messages sorted by: Reverse Date, Date, Thread, Author