Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark dissapear in dropdown at search of multiple words #7

Closed
Ransche opened this issue Oct 13, 2023 · 2 comments
Closed

Mark dissapear in dropdown at search of multiple words #7

Ransche opened this issue Oct 13, 2023 · 2 comments

Comments

@Ransche
Copy link

Ransche commented Oct 13, 2023

Hi,

thank you for the fantastic app. It works great. But it seems there is one bug. Why the blue mark in the drop down list disappears if the search contains more than two words?

grafik

grafik

@Ransche Ransche changed the title Mark dissapear in dropdown at searched of multiple words Mark dissapear in dropdown at search of multiple words Oct 13, 2023
@wenhoujx
Copy link
Owner

wenhoujx commented Oct 17, 2023

hello @Ransche thanks for using this plugin.

this "bug" is a limitation of vscode quick-pick only match and highlight exact words. and it's, afaik, impossible to get the highlighting right, due to the lack of vscode API.

if you search a b c d, and a line of a b c d matches each single word in exact order, all 4 words are highlighted.
image

The quick-pick matching and highlighting is very limited, it doesn't support the rich search syntax of this plugin.
To force quick-pick dropdown match, the trick i pulled was to do the custom match line by line, then append the user-input search string, e.g. a b c d, to the end of the matched line.

This is why if you have a line aa bb cc dd and you search for a b c d, this plugin still match, but there is no highlight (it's actually highlighting on the appended user-input search string)

more info on quick-pick highlighting limitation in this issue.

@wenhoujx
Copy link
Owner

wenhoujx commented Nov 2, 2023

close b/c impossible with current vscode quickpick api. :(

@wenhoujx wenhoujx closed this as completed Nov 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants