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

Suggestion preview: not working in json files? #126061

Closed
usernamehw opened this issue Jun 11, 2021 · 4 comments · Fixed by #128212
Closed

Suggestion preview: not working in json files? #126061

usernamehw opened this issue Jun 11, 2021 · 4 comments · Fixed by #128212
Assignees
Labels
feature-request Request for new features or functionality insiders-released Patch has been released in VS Code Insiders suggest IntelliSense, Auto Complete verification-needed Verification of issue is requested verified Verification succeeded
Milestone

Comments

@usernamehw
Copy link
Contributor

usernamehw commented Jun 11, 2021

"editor.suggest.preview": true,

Open suggest widget in package.json file:

@mkoeppen
Copy link

It isnt working for several file types. I miss the support in twig files. Is the filetyp-list somewhere configurable?

@jrieken jrieken assigned hediet and unassigned jrieken Jun 15, 2021
@hediet
Copy link
Member

hediet commented Jun 15, 2021

The problem is that the suggest item description wants to replace "desc" with "description" (and not just desc with description in which case desc is a simple prefix of description - "desc" is not a prefix of "description").
We are currently exploring to properly diff the strings or use the same character mapping logic that the suggest widget uses to support such scenarios.

@hediet hediet added this to the June 2021 milestone Jun 15, 2021
@hediet hediet added suggest IntelliSense, Auto Complete feature-request Request for new features or functionality labels Jun 15, 2021
@hediet
Copy link
Member

hediet commented Jun 29, 2021

In the current Insider build, you can set the preview mode to 'subwordDiff'

"editor.suggest.previewMode": "subwordDiff",

image

This is the default in todays build, but tomorrow the default will be prefix again.

Next milestone, I will explore a third preview mode that is more relaxed than prefix, but stricter than subwordDiff that should make the scenario in the screenshot work by default.

@hediet hediet modified the milestones: June 2021, July 2021 Jun 29, 2021
@hediet hediet mentioned this issue Jul 8, 2021
@hediet
Copy link
Member

hediet commented Jul 8, 2021

Instead of subwordDiff, there is now prefix, subword and subwordSmart. subwordSmart is the new default (previously prefix).

subwordSmart enables subword based diffing, but only if no ghost text would be shown before the cursor. This is already the default for inline suggestions.

@rzhao271 rzhao271 added verification-needed Verification of issue is requested verified Verification succeeded labels Jul 27, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Aug 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request Request for new features or functionality insiders-released Patch has been released in VS Code Insiders suggest IntelliSense, Auto Complete verification-needed Verification of issue is requested verified Verification succeeded
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants
@jrieken @hediet @rzhao271 @usernamehw @mkoeppen and others