zsh-workers
 help / color / mirror / code / Atom feed
From: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
To: zsh-workers@sunsite.dk
Subject: Re: About the new long/short options changes
Date: Wed, 25 Jul 2001 12:43:50 +0200 (MET DST)	[thread overview]
Message-ID: <200107251043.MAA18601@beta.informatik.hu-berlin.de> (raw)
In-Reply-To: <Tc0a88d0154f6391fb8@mailsweeper01.cambridgesiliconradio.com>

Peter Stephenson wrote:

> Borsenkow Andrej wrote:
> > > 
> > > The result is the patch below, which is already quite satisfying, I
> > > think.
> > 
> > It looks a bit strange to me (no change in setup):
> 
> I don't get this, even with the complete set of styles and options.  Are
> you sure you've installed the new libraries?

It doesn't happen for all commands -- I used `-1' instead of `-2', which
removed consecutive dummy matches.  Ahem.  And then I found a possible
problem in the code that calculates the width needed for the options
(which didn't happen in this case, though).

> The format looks extremely impressive.  The only point I'd make is the
> utterly trivial one that using `--' to introduce the description is a bit
> confusing when there are lots of --'s around introducing options.  How
> about `#'?

Yes, I was slightly worried, too.  I'm not too sure about `#', I'd
prefer something less `bold' (I hope you understand what I mean, the `#'
is so `dark', err... ;-).  And the `--' is used elsewhere, but what
about making it configurable, it's just a little style, after all -- and
then we can use `#' or `--' as the default.


Bye
  Sven

Index: Doc/Zsh/compwid.yo
===================================================================
RCS file: /cvsroot/zsh/zsh/Doc/Zsh/compwid.yo,v
retrieving revision 1.31
diff -u -r1.31 compwid.yo
--- Doc/Zsh/compwid.yo	2001/07/25 08:52:34	1.31
+++ Doc/Zsh/compwid.yo	2001/07/25 10:38:26
@@ -673,7 +673,7 @@
 format completion lists and to make explanatory string be shown in
 completion lists (since empty matches can be given display strings
 with the tt(-d) option).  And because all but one empty string would
-otherwise be removed, this option implies the tt(-V) and tt(-1)
+otherwise be removed, this option implies the tt(-V) and tt(-2)
 options (even if an explicit tt(-J) option is given).
 )
 xitem(tt(-))
Index: Src/Zle/compcore.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/compcore.c,v
retrieving revision 1.47
diff -u -r1.47 compcore.c
--- Src/Zle/compcore.c	2001/07/25 08:52:34	1.47
+++ Src/Zle/compcore.c	2001/07/25 10:38:27
@@ -1637,7 +1637,7 @@
 	return 1;
     }
     if (dat->dummies)
-        dat->aflags = dat->aflags | CAF_NOSORT | CAF_UNIQALL;
+        dat->aflags = (dat->aflags | CAF_NOSORT | CAF_UNIQCON) & ~CAF_UNIQALL;
     for (bp = brbeg; bp; bp = bp->next)
 	bp->curpos = ((dat->aflags & CAF_QUOTE) ? bp->pos : bp->qpos);
     for (bp = brend; bp; bp = bp->next)
Index: Src/Zle/computil.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/computil.c,v
retrieving revision 1.67
diff -u -r1.67 computil.c
--- Src/Zle/computil.c	2001/07/25 08:52:34	1.67
+++ Src/Zle/computil.c	2001/07/25 10:38:47
@@ -208,6 +208,8 @@
             for (str = set->strs; str; str = str->next) {
                 if (str->kind != 1) {
                     if (!str->kind && str->desc) {
+                        if (str->len > wids[0])
+                            wids[0] = str->len;
                         str->other = NULL;
                         *strp++ = str;
                     }
@@ -536,7 +538,7 @@
                 if (dp[0][0] == '-' && dp[0][1] == 'J')
                     break;
             if (*dp) {
-                char *s = tricat("-1V", "", dp[0] + 2);
+                char *s = tricat("-2V", "", dp[0] + 2);
 
                 zsfree(*dp);
                 *dp = s;
@@ -545,7 +547,7 @@
                         (arrlen(opts + 1) + 1) * sizeof(char *));
                 
             } else
-                opts[0] = ztrdup("-1V-default-");
+                opts[0] = ztrdup("-2V-default-");
             csl = "packed rows";
             break;
 

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


  reply	other threads:[~2001-07-25 10:44 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-07-20  5:01 Bart Schaefer
2001-07-20  7:38 ` Sven Wischnowsky
2001-07-20  9:26   ` Bart Schaefer
2001-07-20  9:43     ` Andrej Borsenkow
2001-07-25  8:49     ` Sven Wischnowsky
2001-07-25  9:15       ` Borsenkow Andrej
2001-07-25  9:20         ` Sven Wischnowsky
2001-07-25  9:24           ` Borsenkow Andrej
2001-07-25 10:13         ` Peter Stephenson
2001-07-25 10:43           ` Sven Wischnowsky [this message]
2001-07-25 11:36             ` Borsenkow Andrej
2001-07-25 12:16               ` Sven Wischnowsky
2001-07-25 12:35                 ` Sven Wischnowsky
2001-07-25 17:49             ` Bart Schaefer
2001-07-27 12:53               ` Sven Wischnowsky
2001-07-30  8:22                 ` Sven Wischnowsky
2001-07-30  8:38                   ` Sven Wischnowsky

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=200107251043.MAA18601@beta.informatik.hu-berlin.de \
    --to=wischnow@informatik.hu-berlin.de \
    --cc=zsh-workers@sunsite.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).