Open aarchiba opened 1 year ago
It looks like it's the TinyMCE 'paste' plugin that's doing this. The point of that plugin is to clean up HTML that comes from Microsoft Word. I can't see a configuration option that would let us disable it when pasting into a <pre>
tag. I'll keep looking around.
For now, you could paste the code into the raw HTML editor: click the icon labelled "Source code" at the end of the editor toolbar.
If I select and copy a block of Python code, then set up a preformatted-text section in a question statement or part prompt, when I paste the Python code into the pre block all indentation is lost. It doesn't matter where I copy it from. This makes it very difficult to include Python code in questions.
I am using Firefox on Linux.