On 9/16/06, Martin Bähr <[EMAIL PROTECTED]> wrote:
> On Sat, Sep 16, 2006 at 12:58:10AM +0200, Axel Liljencrantz wrote:
> > > could this be done in the background somehow?
> > Unfortunatly, the structure of the completions is that they are
> > calculated all at once. That's kind of hard to change. Consider, for
> > example, the fact that the basic Unix directory reading functions will
> > not give you the contents of the current directory in alphabetical
> > order.
>
> but the direcory order problem you have anyways, so that can't really be
> the issue.
>
> i tried to look at the source in complete.c in complete_cmd_desc()
>
> you are running __fish_describe_command with the completion token, and
> then you turn that into a hashmap and map descriptions to your
> previously built commandlist.
>
> that way you of course need to wait for __fish_describe_command before
> being able to display any completions.
>
> __fish_describe_command returns its output in alphabetical order.
> i am not familiar with c and i don't know how the following is possible:
>
> run __fish_describe_command in the background, and have it return its
> output with assyncronous I/O, hashing the result and updating your
> initial list line by line as new data comes in. and start writing output
> to the pager as soon as you have a screenful of input from
> __fish_describe_command.
>
> in other words, i do not think you need to wait for
> __fish_describe_command before being able to start producing output.

Unfortunatly, __fish_describe_command does not always return things in
alphabetical order, thoiugh it does so _most_ of the time. Apropos
entries may look like:

foo, bar, baz         (1) -  meaningless junk command

so if you want information on the bar command, it is not enough to
search through the list for bar. If that was the case,
__fish_describe_command could perform a search instead of a filter,
and would be a great deal faster. :(

>
> greetings, martin.
> --
> cooperative communication with sTeam      -     caudium, pike, roxen and unix
> offering: programming, training and administration   -  anywhere in the world
> --
> pike programmer   travelling and working in europe             open-steam.org
> unix system-      bahai.or.at                        iaeste.(tuwien.ac|or).at
> administrator     (caudium|gotpike).org                          is.schon.org
> Martin Bähr       http://www.iaeste.or.at/~mbaehr/
>


-- 
Axel

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to