zsh-workers
 help / color / mirror / code / Atom feed
From: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
To: zsh-workers@sunsite.auc.dk
Subject: PATCH: Re: Selection won't start
Date: Wed, 5 Apr 2000 12:48:10 +0200 (MET DST)	[thread overview]
Message-ID: <200004051048.MAA02650@beta.informatik.hu-berlin.de> (raw)
In-Reply-To: Peter Stephenson's message of Wed, 05 Apr 2000 11:16:55 +0100


Peter Stephenson wrote:

> Running zsh -f and loading completion, then using these styles:
> 
>   zstyle ':completion:*' completer _oldlist _complete _approximate
>   zstyle ':completion:*' max-errors 2 numeric
>   zstyle ':completion:*' menu select=5
> 
> menu selection doesn't come into effect (with AUTOMENU) until I explicitly
> set SELECTMIN, after which it seems to be following the value of SELECTMIN,
> not the style.  I also need to load zsh/complist explicitly as well.  It
> doesn't seem to be dependent on the order of the initialization (I wouldn't
> expect it to be).  I can't see offhand how it's supposed to work, so I
> don't know if this is just me getting something wrong.  I tried with both
> filename completion and option completion.  I deliberately don't have
> list-colors set, but in any case it isn't necessary for SELECTMIN to work.

This was all caused by the wrong test in _main_complete. I must have
accidentally deleted the `sel' sometime. Dunno.

> (I just noticed how incomprehensible to beginners that is.  AUTOMENU is an
> option, SELECTMIN is a parameter, list-colors is a style, zsh/complist is a
> module... I suppose you just have to be here when it's happening.)

That's why I made it load complist automatically and so on. One only
needs to use the style.

There are still some other options that don't have equivalent styles, though.

> Also, _zmodload is now failing to remove the `.so' from the ends of
> modules.

A small thinko in _files.

Bye
 Sven

Index: Completion/Core/_files
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Core/_files,v
retrieving revision 1.3
diff -u -r1.3 _files
--- Completion/Core/_files	2000/04/03 15:27:14	1.3
+++ Completion/Core/_files	2000/04/05 10:44:48
@@ -6,7 +6,7 @@
     '/=tmp' 'f=tmp' 'g+:-=tmp' q n 1 2 P: S: r: R: W: X+: M+: F: J+: V+:
 
 type="${(@j::M)${(@)tmp#-}#?}"
-(( $tmp[(I)-g*] )) && glob="${(j: :)${(M)tmp:#-g*}#-g}"
+(( $tmp[(I)-g*] )) && glob="${(j: :)${(@M)tmp:#-g*}#-g}"
 ign=$opts[(I)-F]
 if (( ign )); then
   ign=( $=opts[ign+1] )
Index: Completion/Core/_main_complete
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Core/_main_complete,v
retrieving revision 1.3
diff -u -r1.3 _main_complete
--- Completion/Core/_main_complete	2000/04/03 13:13:02	1.3
+++ Completion/Core/_main_complete	2000/04/05 10:44:48
@@ -140,7 +140,7 @@
     else
       sel=( "${(@M)_menu_style:#select*}" )
 
-      if (( $# )); then
+      if (( $#sel )); then
         local min=9999999 i num
 
         for i in "$sel[@]"; do

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


                 reply	other threads:[~2000-04-05 10:48 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200004051048.MAA02650@beta.informatik.hu-berlin.de \
    --to=wischnow@informatik.hu-berlin.de \
    --cc=zsh-workers@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).