Community
Participate
Working Groups
We now search based on word rather than whole phrase for the preference dialog. But that has broken the case where the word that you type in the search dialog contains a space. For instance: "code tem" doesn't match "Code Templates".
Fix is to add code to FilteredPreferenceDialog#createTreeViewer. The first block of code already exists and checks for a match by splitting the search widget's text field based on space. The second block of code is new and basically says if we had a phrase with a space in it, then try and do a match on the whole phrase. (which would match, for instance, "code templates") ------------------ String[] words = node.getLabelText().split("\\W"); //$NON-NLS-1$ for (int i = 0; i < words.length; i++){ if( match(words[i])) return true; } -> // if the text contained spaces, we already tried matching on each individual -> // word but now try and match on the whole phrase. -> if (words.length > 1 && match(node.getLabelText())) -> return true; ---------------- Re-assigning to Tod for review/release.
*** Bug 85513 has been marked as a duplicate of this bug. ***
*** Bug 85617 has been marked as a duplicate of this bug. ***
Fixed in build >20050222
Verified in 20050330