Orange colored background when copying & pasting text

Dear Sutta Central

I was using your Tipiṭaka for copying & paste text from your website into a Word document for a research project about Buddhism.

I am not sure if it is my Word document setting or it is your website but when I copy & paste your Tripitaka text, there is an orange colored background to the text. This causes me to have to remove the background coloring from my Word document, which is an extremely tedious process. In fact, even when I started typing a new paragraph, an orange colored background text commences again and I must continue to remove the background coloring.

I have noticed this has also occurred with other websites before.

Is this orange background coloring of text an inherent feature of your website to discourage copying & pasting? Is there anything one can do to prevent this?

Thank you :pray:

2 Likes

I use google docs, but there’s a way to paste without formatting (ctrl - shift - v); not sure if it works on Word.

I don’t think there’s a deliberate effort to discourage copy pasting, as most of the content is open source (except for cases to train AI).

2 Likes

Hi Rabbit, I’m putting a link to your question in our bugs thread. I don’t know why it’s doing that. I always use dark mode so it doesn’t show up. But when I switch to normal reading mode (in Word) I see what you mean.

2 Likes

Well, that probably means it’s not a SC problem.

SuttaCentral does everything possible to encourage copping text. If it’s related to SC, then it’s not on purpose.

Ctrl Shift V is a universal “paste without formatting.” Always the best practice for pasting into any kind of word processor.

If you want help with this, please give lots of screen shots and report exactly all the platform information so we can try to recreate the problem, i.e. operating system, software versions, browser name, other sites that cause the same problem, etc.

Sharing a word doc that it happens in would be useful too.

3 Likes

I had the same issue yesterday. I know about paste without formatting. However, I wonder if there is a way to do the highlighting so that the browser default is used for selecting (and thus not pasted) and then the text is highlighted afterwards.

EDIT: It seems this is only a problem with Pali lookup is enabled

2 Likes

Screenshots and platforms would be really helpful. No one is giving that info so it’s hard to narrow down.

Are you saying in a situation like this (FF on Win11, btw):

That copying the selected (blue background) text would render with an orange background when pasted into MSWord?

I don’t have MSWord, so I can’t test. Pasting that into LibreOffice just gives me the text. Even pasting the highlighted “bhagavā” in the body of the page doesn’t give orange background.

Can someone with a color picker say if the orange background of the pasted text is identical to the orange background of “bhagavā”?

I’m not sure exactly what you mean by this. Are you talking about the :selection pseudo element? It doesn’t appear that SC is setting a custom value, however I’m not 100% sure. Looks like the default color to me.

1 Like

I’m in Mac 15.2, Safari 18.2 and actually pasting into Pages.

I think what the OP is saying is a problem with .spanFocused (in your screenshot ‘bhagavā’). Though I’m wondering if for them this class is applying to everything which is selected. This is not the case in Saf

2 Likes

Does the same happen when you use a different browser? Does it happen when you paste into google docs? If you have time to test.

1 Like

Pages (top pasted from Chrome, bottom pasted from Saf)

Pasted from Chrome into OfficeLibre Write (sorry didn’t do Saf)

Pasted from Chrome and Saf into Safari Gdocs (Google docs run in Chrome looks the same)

This provides an interesting variety. The orange-tan background in gDocs might be what OP means.

3 Likes

Thanks!

I’d say that the solution in all cases is to find whatever the app’s “paste without formatting” command is and use that on a regular basis. We really should be doing that every time we go from the web to a word processor. Otherwise there is no end to the junk you will end up migrating.

As a side note, the SC browser extension has a few features related to copy and paste from SuttaCentral. There is a key to copy all visible text just as text. And one to toggle selection of only one language (so you can just copy, for example, the English without selecting the Pali).

2 Likes

I always do that in MS Word. Strangely, this is the first time I’ve noticed the pale orange in the document. It is equivalent to Ven. Pasanna’s final screenshot above.

The last time I recall using day mode in Word and copying something over was about a year ago. It wasn’t carrying over the pale orange background.

3 Likes

Thank you all. I will work on the suggestions. Yes, the background can be both dark orange (which I sense is connected to the dictionary highlighting) and a very light orange/tan. I tried to post an example of the light orange but it is not visible when copying & pasting a screen dump.

I can actually see the light orange.

The solution is to use whatever is the “paste without formatting” option your word processor uses. On Windows it’s almost always ctrl + shift + v.

I don’t think there is anything that could be done on the suttacentral side. It’s just an inherent problem of copying from a webpage.

The only alternative would be to use the copy feature in the extension I mentioned above, but that copies the whole text. Or perhaps there is some browser extension that automatically only copies text and no formatting from a web page. Actually, here is one for Chrome. No idea if it works.

2 Likes

There is but it’d involve some javascript and probably not worth it.

2 Likes

Maybe another option for you is, you can change the default paste option for “Pasting from other programs” in MS Word from “Keep Source Formatting” to “Keep Text Only”

More info is here:

2 Likes

Thank you everyone. It finally worked. Yes, Ctrl + Alt + V and a box pops up. But you most press those three keys very accurately and simultaneously. :slightly_smiling_face:

1 Like

On Mac OS, it’s shift+option+command+v

1 Like

Oh my stars :face_with_spiral_eyes: staying fluent in PC and Mac is almost beyond reach for me anymore! Well, this thread has inspired me to keep plowing through MN2 in my Word document.