zsh-users
 help / color / mirror / code / Atom feed
* does COMPLETE_IN_WORD work at all?
@ 2003-09-14  0:21 dominik.vogt
  2003-09-14  9:25 ` Bart Schaefer
  0 siblings, 1 reply; 2+ messages in thread
From: dominik.vogt @ 2003-09-14  0:21 UTC (permalink / raw)
  To: Zsh Users

I have wondered what the COMPLETE_IN_WORD option actually does for
years.  The man page says:

  If  unset, the cursor is set to the end of the word
  if completion is started. Otherwise it stays  there
  and completion is done from both ends.
 
And the zsh tutorial states in section 6.2.4:

  For example if you typed 'Mafile', went back over the 'f' and
  hit tab, the shell would complete 'Makefile'.

But it never works when I try it:

  $ zsh --version
  zsh 4.0.4 (i686-pc-linux-gnu)

  $ emulate -R zsh
  $ setopt completeinword

  $ mkdir test
  $ cd test
  $ touch Mail Makefile
  $ ls Mafile<Crsr-Left><Crsr-Left><Crsr-Left><Crsr-Left>

Now I have the cursor over the 'f'.  When I press <tab> once, zsh
presents me a menu of possible completions for 'Ma', i.e. 'Mail'
and 'Makefile'.  After pressing tab again, it prepends 'Mail' to
'file' and after pressing tab again I get 'Mailfilefile'.

So, does the COMPLETE_IN_WORD option work at all?  It might be
something in my config, but then the 'emulate -R zsh' should have
reset all options to the default.

Bye

Dominik ^_^  ^_^

 --
Dominik Vogt, dominik.vogt@gmx.de
Reply-To: dominik.vogt@gmx.de


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: does COMPLETE_IN_WORD work at all?
  2003-09-14  0:21 does COMPLETE_IN_WORD work at all? dominik.vogt
@ 2003-09-14  9:25 ` Bart Schaefer
  0 siblings, 0 replies; 2+ messages in thread
From: Bart Schaefer @ 2003-09-14  9:25 UTC (permalink / raw)
  To: Zsh Users

On Sep 14,  2:21am, dominik.vogt@gmx.de wrote:
} Subject: does COMPLETE_IN_WORD work at all?
}
} I have wondered what the COMPLETE_IN_WORD option actually does for
} years.
} 
} But it never works when I try it:

That's probably because you have TAB bound to expand-or-complete-prefix.
The examples assume you have it bound to either expand-or-complete or
simply complete-word.

Using expand-or-complete-prefix explicitly neutralizes COMPLETE_IN_WORD,
because it forces completion to ignore everything after the cursor.

Only setopts are reset by "emulate -R", not keybindings or variables.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-09-14  9:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-09-14  0:21 does COMPLETE_IN_WORD work at all? dominik.vogt
2003-09-14  9:25 ` Bart Schaefer

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).