zsh-workers
 help / color / mirror / code / Atom feed
* $curcontext in _subscript
@ 2000-02-21 13:04 Oliver Kiddle
  0 siblings, 0 replies; 2+ messages in thread
From: Oliver Kiddle @ 2000-02-21 13:04 UTC (permalink / raw)
  To: Zsh workers

In my .zshrc, I have zstyle to define a tag-order of 'indexes parameters' for -subscript- because I don't want it to complete all variables after something like '$path['. This stopped working a while ago.

It seems that when _subscript is run, $curcontext is ':complete:-subscript-'. Why is 'completion' not in there as the first bit. As far as I can tell, 'complete' is put there by the complete completer.

What exactly should I be using as the parameters to zstyle to achieve this: it works with '*-subscript-*' but I'd prefer to use something more specific.

Oliver Kiddle


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

* Re: $curcontext in _subscript
@ 2000-02-21 13:12 Sven Wischnowsky
  0 siblings, 0 replies; 2+ messages in thread
From: Sven Wischnowsky @ 2000-02-21 13:12 UTC (permalink / raw)
  To: zsh-workers


Oliver Kiddle wrote:

> In my .zshrc, I have zstyle to define a tag-order of 'indexes parameters' for -subscript- because I don't want it to complete all variables after something like '$path['. This stopped working a while ago.

I hope you really mean `indexes' and -- in a separate word --
`parameters'. Otherwise this would mean they should both be tried
immediatly and together...

> It seems that when _subscript is run, $curcontext is ':complete:-subscript-'. Why is 'completion' not in there as the first bit. As far as I can tell, 'complete' is put there by the complete completer.

Because its given in the calls to zstyle.

> What exactly should I be using as the parameters to zstyle to achieve this: it works with '*-subscript-*' but I'd prefer to use something more specific.

Always remember that now the context names simply and cleanly always
have the fixed format: `:completion:<function>:<completer>:<command>:<arg>:<tag>'.
Where <command> may also be one of the special contexts. So, what you
want is:

  zstyle ':completion:*:*:-subscript-:*' tag-order indexes parameters


Bye
 Sven

P.S.: But just being able to define such things is fun, isn't it?

--
Sven Wischnowsky                         wischnow@informatik.hu-berlin.de


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

end of thread, other threads:[~2000-02-21 13:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-02-21 13:04 $curcontext in _subscript Oliver Kiddle
2000-02-21 13:12 Sven Wischnowsky

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).