In Visual Studio Code version 1.10 Copy with syntax highlighting has been introduced.
I don't want to use it most of the time but I can't find a way to turn it off.
Even though I have no keybinding set for editor.action.clipboardCopyWithSyntaxHighlightingAction
VSCode always copies with Syntax highlighting.
How can I turn it off so that I copy plain text only?
Select the portion of code you'd like to copy, then go the Edit menu and select Copy Special -> Copy as RTF. Your code, complete with syntax highlighting colors, is now stored on the clipboard. Simply press Ctrl + V in your other application to paste the code with syntax highlighting. It's that simple!
You can enable / disable semantic highlighting in the VS Code settings. Press F1 to open the command window, and then enter "Open Settings (UI)". Search "semantic" to find the Editor>Semantic Highlighting item . Set the value to true to enable semantic highlighting; otherwise set it to false .
To configure syntax highlighting, click on “Language” in the top bar, then click the letter the language starts with, and then the language. If you want to define your own language, click on “Language” again, then click on “User Defined Language”, third from the bottom, and then click “Define your language”.
You can copy the code and paste it in VS Code search box (shows when you press Ctrl+F). Then copy it again from there. Then you can paste unformatted text anywhere you want.
Go to settings.json
file and add
"editor.copyWithSyntaxHighlighting":false
https://github.com/microsoft/vscode/issues/20837
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With