Allow minimumInputLength to be specified as a function

I needed modify minimumInputLength programmatically, based on which way the widget was activated.

This patch changes minimumInputLength so it can be either an integer or a function which returns an integer, similar to maximumSelectionSize.