From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gatech.edu (gatech.edu [130.207.244.244]) by werple.mira.net.au (8.6.12/8.6.9) with SMTP id MAA10928 for ; Sun, 23 Jul 1995 12:05:31 +1000 Received: from math (math.skiles.gatech.edu) by gatech.edu with SMTP id AA00928 (5.65c/Gatech-10.0-IDA for ); Sat, 22 Jul 1995 22:06:53 -0400 Received: by math (5.x/SMI-SVR4) id AA27305; Sat, 22 Jul 1995 21:38:27 -0400 Resent-Date: Sat, 22 Jul 1995 19:13:21 +0100 (BST) Old-Return-Path: From: Zefram Message-Id: <10932.199507221813@stone.dcs.warwick.ac.uk> Subject: where-is et al: improved fix To: zsh-workers@math.gatech.edu (Z Shell workers mailing list) Date: Sat, 22 Jul 1995 19:13:21 +0100 (BST) X-Loop: zefram@dcs.warwick.ac.uk X-Stardate: [-31]6018.79 Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-Id: <"qBUgL1.0.Zg6.IWQ4m"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/259 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu -----BEGIN PGP SIGNED MESSAGE----- The patch below is an improvement on Zoltan's patch for where-is et al, making them work properly when a completion list is on the screen. It also fixes a potential problem with listing expansions, that probably couldn't happen in the code exactly as it was. (It only occurred in execute-named-command.) After this patch is applied, where-is and describe-key-briefly won't stop a menu completion, but will only remove the list from the screen. It can then be brought back with list-choices. Similarly execute-named-command, when completion is performed in the minibuffer. If you haven't applied Zoltan's patch, then this won't apply cleanly; just ignore the failures in zle_bindings.c and zle_misc.c. -zefram *** 1.6 1995/07/21 22:10:34 --- zle_bindings.c 1995/07/22 18:02:22 *************** *** 188,195 **** {"history-beginning-search-backward", historybeginningsearchbackward, ZLE_HISTSEARCH}, {"history-beginning-search-forward", historybeginningsearchforward, ZLE_HISTSEARCH}, {"expand-or-complete-prefix", expandorcompleteprefix, ZLE_MENUCMP}, ! {"describe-key-briefly", describekeybriefly, 0}, ! {"where-is", whereis, 0}, {"vi-kill-eol", vikilleol, ZLE_KILL}, {"vi-yank-whole-line", viyankwholeline, 0}, {"vi-put-before", viputbefore, ZLE_YANK}, --- 188,195 ---- {"history-beginning-search-backward", historybeginningsearchbackward, ZLE_HISTSEARCH}, {"history-beginning-search-forward", historybeginningsearchforward, ZLE_HISTSEARCH}, {"expand-or-complete-prefix", expandorcompleteprefix, ZLE_MENUCMP}, ! {"describe-key-briefly", describekeybriefly, ZLE_MENUCMP}, ! {"where-is", whereis, ZLE_MENUCMP}, {"vi-kill-eol", vikilleol, ZLE_KILL}, {"vi-yank-whole-line", viyankwholeline, 0}, {"vi-put-before", viputbefore, ZLE_YANK}, *** 1.5 1995/07/21 22:10:34 --- zle_main.c 1995/07/22 18:03:31 *************** *** 1073,1078 **** --- 1073,1079 ---- putc('\r', shout), tcmultout(TCUP, TCMULTUP, nlnct); else putc('\n', shout); + showinglist = 0; } static int func, funcfound; *************** *** 1125,1130 **** --- 1126,1132 ---- putc('\r', shout), tcmultout(TCUP, TCMULTUP, nlnct); else putc('\n', shout); + showinglist = 0; } /**/ *** 1.6 1995/07/21 22:12:29 --- zle_misc.c 1995/07/22 17:57:49 *************** *** 577,583 **** *ptr = '\0'; if ((cmd = getkeycmd()) < 0 || cmd == z_sendbreak) { statusline = NULL; - showinglist = 0; return z_undefinedkey; } switch (cmd) { --- 577,582 ---- *************** *** 604,610 **** if (t0 != ZLECMDCOUNT) { lastnamed = t0; statusline = NULL; - showinglist = 0; return t0; } /* fall through */ --- 603,608 ---- *** 1.16 1995/07/21 22:15:06 --- zle_tricky.c 1995/07/22 17:56:39 *************** *** 3705,3710 **** --- 3705,3711 ---- makearray(l); listmatches(); + showinglist = 0; expl = ex; amatches = am; -----BEGIN PGP SIGNATURE----- Version: 2.6.i iQBVAgUBMBE/f2WJ8JfKi+e9AQEVXQH/aoOFjtGYTcvZAHTbVrKdForDMUGU5zim kbagfOYSXwcdMeAwZi9JaxsuBxgx5I88CLfnqKM1JCA9F3deWEvxXA== =dkSG -----END PGP SIGNATURE-----