-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hello,
We are using the chosenbox component with ListModelList(Rendering All) and when we filter we see that the filter uses the startsWith() method
Is there a way to change this method from startsWith() method to contains() method?
Thank you!
Hey there,
Simplest option for this is to use
ListModels#toListSubModel(ListModel<t> model, java.util.Comparator<t> comparator, int nRows)
The comparator has 2 arguments: the input string, and the model data object. When the user searches by entering text, the comparator is invoked on each data object in model. The comparator returns an integer. If you return 0, it means a match, so the item is shown in results. If you return "not zero", it means "not match", so the item is not shown in results
Asked: 2022-12-20 20:10:39 +0800
Seen: 5 times
Last updated: Dec 22 '22
How to let chexkbox horizontally arranged
Choosenbox : selectedObjects background color
extend the chosenbox component
radiogroup onCheck/onChange not calling to the binded command
Tooltips in chosenbox elements
Customize chosenbox emptymessage styling
Can't catch onSearch event when using SimpleListModel with chosenbox