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

Pastes to RTF/ANSI Escape Codes? #1

Closed
sparty02 opened this issue Sep 26, 2016 · 7 comments
Closed

Pastes to RTF/ANSI Escape Codes? #1

sparty02 opened this issue Sep 26, 2016 · 7 comments

Comments

@sparty02
Copy link

This doesn't seem to work at all for me. I copied the following:

image

And pasted it into several different programs, all consistently showing the following:

image

...which looks like some kind of RTF/ANSI escape codes maybe? FWIW, I'm on Windows 7.

@atian25
Copy link
Owner

atian25 commented Sep 26, 2016

yes, it convert code to RTF.

sorry I don't have windows now, I will try to find one tomorrow.

@atian25
Copy link
Owner

atian25 commented Sep 26, 2016

maybe it's the problem of copy-paste module

@atian25
Copy link
Owner

atian25 commented Sep 27, 2016

@sparty02 had try at windows.

  • pygmentize convert code to rtf work fine.
  • the rtf string can be save to test.rtf file, then open it with word, can found is highlighted.
  • the problem is copy-paste can't set clipboard with rtf format
  • so I raise an issue, https://github.com/xavi-/node-copy-paste/issues/52

@brightloudnoise
Copy link

I don't think it's an issue with the node-copy-paste.

Based on what I've read on how Windows clipboard works. You need to specify RTF or a custom format as part of the copy action.

node-copy-paste relies on clip.exe, which is provided with Windows, and only passes pure text.

@brightloudnoise
Copy link

I commented on https://github.com/xavi-/node-copy-paste/issues/52 with an experiment that may provide us a path forward.

@atian25
Copy link
Owner

atian25 commented Jan 11, 2017

@brightloudnoise great~ so could you raise a PR for it ? or just fork to publish another lib (cause node-copy-paste seams to be not maintenance)

@shivan
Copy link

shivan commented Mar 3, 2017

same as #6
Now with vscode 1.10 it supports copy syntax without extra plugin.

@atian25 atian25 closed this as completed Mar 4, 2017
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

4 participants