Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: completion grouping



On Nov 3,  2:41pm, Sven Wischnowsky wrote:
} Subject: completion grouping
}
} Completion functions should call the function `_tags' with the
} tag-names of the types of matches they generate. Then they call
} `_tags' repeatedly without arguments. This will set the parameter
} `tags' to a colon-separated list of tags then should now be
} tried. E.g. if a functions generates jobs (`%...') and pids, it should 
} do something like:
} 
}   local prios tags

Can I first suggest that we spell out "priorities"? It's not like it's
going to be typed very often, is it?

I'm also never sure what to expect from "sorted by priority."  In this
case a smaller number is a higher priority, right?  But a negative
number is treated as bigger than any positive one?  That's a bit weird.
Or am I misunderstanding?

} The need to declare `prios' and `tags' as locals is very ugly, but
} currently I don't see a really satisfying solution.

I've been thinking about something for that, but so far it's too nebulous
to tell if it's going to work.

}   comptag option+='*dvi*=1'
} 
}     the `+=' means that the definition is prepended to the already
}     existing definition

Hrm.  I would have expected += to *append* rather than *prepend* (my
C++ is showing).

Otherwise, this looks pretty good.

Perhaps more on the other questions later; I have a cramp in my neck this
morning which is making it difficult to type.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



Messages sorted by: Reverse Date, Date, Thread, Author