BookmarkSubscribe

Text Edit Box() <<Set AutoCompleter List()

I think it would be awesome if texteditbox() had the ability to have a list of values that it would search from and give a listbox (without messing up layouts) below where you could select possible options. I'm thinking like google or whatever. 

 

something like this

Names default to here(1);
new window("Test", 
	teb = texteditbox("")
);
teb << Set AutoCompleter List({"face", "John", "Denver", "head", "heat"});
// I imagine it would have other flags like
teb << Set AutoCompleter Match("All"|"Start");

Where if the match were all it would look like

autocompleter all.png

And if it were start it would look like

autocompleter start.png

 

 

Tracking Number:

Defect ID:

2 Comments

@vince_faller, There is an "editable" option for Combo Box that gets you a different kind of auto complete.

New Window( "Example",
	cb = Combo Box(
		{"face", "John", "Denver", "head", "heat"},
		editable,
		Show( cb << Get() )
	)
);

Here's a gif of how it works:

2019-03-22_13-20-43.gif

I will also pass your suggestion for an auto complete list to development.

Super User

@Justin_Chilton , you are tricky.  I like this but yeah. I think I still would like it to create a filtered list on typing that doesn't mess with layout. Also, if there was an option to not allow typing that wasn't part of the list.  For instance it wouldn't allow me to type a z in your example.