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

Java string paste not auto escape #3568

Closed
AYiXi opened this issue Apr 9, 2024 · 2 comments · Fixed by #3570
Closed

Java string paste not auto escape #3568

AYiXi opened this issue Apr 9, 2024 · 2 comments · Fixed by #3570
Assignees

Comments

@AYiXi
Copy link

AYiXi commented Apr 9, 2024

after update, paste auto escape funtion is not working

Before Update:
String s = "{\"a\": 1}";

After Update:
String s = "{"a": 1}";

// my settings.json
{
"editor.pasteAs.enabled": true,
"editor.pasteAs.showPasteSelector": "afterPaste",
}

@rgrunber
Copy link
Member

rgrunber commented Apr 9, 2024

I noticed that the language server is sending the correct, escaped content, but the client just isn't applying it.

async provideDocumentPasteEdits(document: TextDocument, ranges: readonly Range[], dataTransfer: DataTransfer, token: CancellationToken): Promise<VDocumentPasteEdit> {

microsoft/vscode@091987d#diff-b553efc31b13377c3b4765704b0e0a681d7489d1cb819194f327a589def055c8L40-R85

Looks like the API was updated for 1.88.0.

@rgrunber
Copy link
Member

rgrunber commented Apr 9, 2024

This should be fixed in the next pre-release. Thank-you for filing this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants