tab-complete

Ajax autocomplete (or autosuggest) with TAB completion/autofill similar to shell command line completion?

I'm implementing a AJAX autocomplete/autosuggest feature, and not only do I want to do the usual show suggestions that are similar to what the user typed, but I'd like to let the user do partial completions to save typing. So, imagine my dictionary has these values in it: "green apple", "green pear", "green fruit", "blue sky", "blue wa...

How to enable tab completion from the terminal specific to the executable

In bash, I believe it is possible to enable tab completion on the terminal for terms that are specific to the executable being invoked. For example, given an executable "eat" with valid arguments {cake, carrot, banana}, typing 'eat car' should complete to 'eat carrot'. I believe this is possible because I have seen it with 'ant' tab-c...