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

CompletionItem.preselect seems to be ignore with MRu selection #54203

Closed
dbaeumer opened this issue Jul 12, 2018 · 5 comments
Closed

CompletionItem.preselect seems to be ignore with MRu selection #54203

dbaeumer opened this issue Jul 12, 2018 · 5 comments
Assignees
Labels
*as-designed Described behavior is as designed suggest IntelliSense, Auto Complete under-discussion Issue is under discussion for relevance, priority, approach

Comments

@dbaeumer
Copy link
Member

Steps to reproduce (pthyon code)

  • type os.
  • correctly preselects path
  • pick pipe
  • delelete pipe
  • open code complete

Observe: pipeis selected although path is preselected.

@dbaeumer
Copy link
Member Author

FYI @vivlimmsft

@jrieken
Copy link
Member

jrieken commented Jul 13, 2018

That's most likely because of "editor.suggestSelection": "recentlyUsed". Try first (which now actually means default).

@jrieken jrieken added suggest IntelliSense, Auto Complete under-discussion Issue is under discussion for relevance, priority, approach labels Jul 13, 2018
@vivlimmsft
Copy link

I didn't have editor.suggestSelection set at all, it seems to default to recentlyUsed.

It works fine with first (and in fact that's a workaround I'm using for development) but I was expecting preselect, when set, to take effect regardless of the value of editor.suggestSelection. I was hoping that preselect would mean that I wouldn't need to write "editor.suggestSelection": "first" into user settings for my feature to work.

@jrieken
Copy link
Member

jrieken commented Jul 13, 2018

Yeah, recentlyUsed is the default and it's a fair question about what should win preselect or recentlyUsed. I think that recentlyUsed should win because it's a recording of actual user-choice. However, given that we now have the preselect-feature we can think about changing the default to first... Tho, care must be taken because those changes often cause a big stir.

As a language extension author you can always contribute a default value for an existing setting, e.g you can say "for python the value is "editor.suggestSelection": "first"". See https://code.visualstudio.com/docs/extensionAPI/extension-points#_contributesconfigurationdefaults

@jrieken jrieken added the *as-designed Described behavior is as designed label Sep 11, 2018
@jrieken
Copy link
Member

jrieken commented Sep 11, 2018

Closing this as designed

@jrieken jrieken closed this as completed Sep 11, 2018
@vscodebot vscodebot bot locked and limited conversation to collaborators Oct 26, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*as-designed Described behavior is as designed suggest IntelliSense, Auto Complete under-discussion Issue is under discussion for relevance, priority, approach
Projects
None yet
Development

No branches or pull requests

3 participants