Bash completion dynamic behavior

I would like to have 2 different behavior of "tab" depending of the usage context.
I would like to have the default behavior of bind '"\t":complete' any time except when users are trying to complete arguments of the "mybashfunction" command. In this case I call a special function to generate the completion, but I would like "tab" to work like if bind '"\t":menu-complete' was set.


Solution 1:

I believe that its readline library will only support one kind of tab-completion behaviour at a time.