nus-cs2103-AY1718S1 / forum

Discussion Forum
5 stars 0 forks source link

Autocomplete CLI - ControlFX import (Easy Solution) #122

Open justintkj opened 6 years ago

justintkj commented 6 years ago

I have managed to implement Autocomplete by using controlfx import. You can find my PR here : https://github.com/CS2103AUG2017-F09-B3/main/pull/3/files Compared to coding the entire suggestions using lists, using this API definitely is simpler and cleaner. A string array of possible suggestion can be used to hardcode sample lines that users can type. Next, all you have to do is to use the bindAutoComplete method to cause the CLI to have a drop-down menu of choosable autocomplete features. This is how it looks like! image

My next plan is to give this feature a "smart" component, where possible suggestion can be updated on the fly whenever users enter a valid command into the CLI, the string will be added into possibleSuggestion array.

Feel free to contact me if you have any queries if you want to implement it my way or if you want to share any possible enhancement to this issue!