Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Alignment issue with multiple describes
- X-seq: zsh-workers 31304
- From: Felipe Contreras <felipe.contreras@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: Re: Alignment issue with multiple describes
- Date: Sat, 20 Apr 2013 22:03:59 -0500
- Cc: Felipe Contreras <felipe.contreras@xxxxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=fAhAUZrjp7pBBiEChH9Wkb/ISeePars11/7e6Z3A0y8=; b=Da7TZet/WnQMEocoAJIhDKxYeeEHHiVpR9sEbhUvJrBRocNoGNuBIvhtmaaaIjMLZr VvZI3HqpBhR0mMJjUS0PEUlZ8jiNc4x01WQZc3y6VzIgHOrDrCR1SPtHXGUnoHc3FPyW 5N3Na6NStC3jMuH0J+QmeqhV9LQNJb85ijqHPU14y+A51o+A5NYlKrO+W1nJeQiWj9iU rHh3YRAoh5md3GpL5UG94BAoLKocgCKqswKTOkzARdOv+ti6qPF7V8V85lKCdnVrM301 MAQ1vTGfPxUI8x7egGZbokeiJtTmYT6lnlf+pUt0CZ4XbeUYSMC6xOHJc7RhQnW5r8G9 74cQ==
- In-reply-to: <CAMP44s1WDkUiwsj1dzW6icUVFq4-noqEDKRS0k3AePxo1Oj6nA@mail.gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CAMP44s1WDkUiwsj1dzW6icUVFq4-noqEDKRS0k3AePxo1Oj6nA@mail.gmail.com>
Please keep me in Cc.
On Sat, Apr 20, 2013 at 10:03 PM, Felipe Contreras
<felipe.contreras@xxxxxxxxx> wrote:
> I'm trying to write a completion script for many multiple subcommands,
> and I want to group them in different tags, which works more or less
> fine, however, I've noticed a problem when using more than one
> describe: the completion's description is aligned, but only to the
> same description, even if they are not grouped.
>
> For example, the script below throws this:
> ---
> extraone -- extra command one
> one -- command one
> two -- command two
> zbiggertoshowthealignissue -- extra command two
> ---
>
> If the tags are group together, the problem is less noticeable, but as
> soon as you enter the menu, the alignment changes again (to a proper
> one).
>
> You can even see this with zsh's official git completion.
>
> Any ideas?
>
> #compdef foobar
>
> _foobar ()
> {
> local -a commands extra
> commands=('one:command one' 'two:command two')
> _describe -t commands 'commands' commands
> extra=('extraone:extra command one' 'zbiggertoshowthealignissue:extra
> command two')
> _describe -t extra 'extra' extra
> }
--
Felipe Contreras
Messages sorted by:
Reverse Date,
Date,
Thread,
Author