krassowski / Anki-Night-Mode

Enabling studying at night with Anki - without eye strain
https://ankiweb.net/shared/info/1496166067
GNU General Public License v3.0
72 stars 13 forks source link

Copy & Paste Includes Span From Browse Screen #4

Closed gr4nny closed 7 years ago

gr4nny commented 8 years ago

Sometimes I need to change cards from Front/Back to Cloze. If I am in night mode and copy and paste from browse to an add window, the <span color=... code is included. This results in the text color being permanently changed to the night mode color on the new card.

As a work around, you can open HTML view and paste in there, which does not include the HTML code. This loses other format modifications like bold or underline. Ultimately, the best option is not to use night mode for this operation.

krassowski commented 8 years ago

I'm not sure if there is a much filed for improvement. I'll investigate it in February. Thanks for your report.

gr4nny commented 8 years ago

This also happens on the edit screen when cutting and pasting from one field to another.

krassowski commented 7 years ago

I reported the issue upstream: Copy & paste in Anki editor causes copied text to include redundant tags, which is detrimental to UX when using Night Mode addon asking @dae for help as I did not find a solution for that for way too long time and it appears to be caused by the way Anki (or PyQt) handles copy/paste action. I wish we could fix that.

krassowski commented 7 years ago

Fixed in Anki 2.1 beta 21: https://github.com/dae/anki/commit/4dbb87e4c192811122d1cab5d1cf849731c5780e