Opened 14 years ago
Last modified 13 years ago
#8068 confirmed Bug
Issue with pasting subscript
Reported by: | Krzysztof Studnik | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | Core : Pasting | Version: | 3.1 |
Keywords: | Cc: |
Description
I have found some strange behaviour while pasting text marked as <sub>
, under IE's
TC
- open editor
- Enter some text
- enable Subscript and enter some text
- select and copy text with subscript enabled
- press right cursor key or "End" on keyboard
- paste text
- press "End" again and paste
Actual
Under IE8 quirks:
<p> test<sub>test<sub><font size="1">test<sub><font size="1">test<sub><font size="1">test<sub><font size="1">test</font></sub></font></sub></font></sub></font></sub></sub></p>
Under IE6/7
<p> test<sub>test<sub>test<sub>test</sub></sub></sub></p>
Under Opera
<p> test<sub>test</sub><sub>test</sub><sub>test</sub><sub>test</sub></p>
Expected
Cursor keys should not influence pasting, and pasted subscript should be in one line, as in Opera. Perhaps additional </sub><sub>
should also be removed?
Attachments (1)
Change History (3)
Changed 14 years ago by
Attachment: | zrzut_ekranu-3.png added |
---|
comment:1 Changed 14 years ago by
Status: | new → confirmed |
---|
comment:2 Changed 13 years ago by
Webkit: problems here may have more to do with Browser pasting problems than with CKEditor itself. This is at least when looking at chrome (E.g. #8070 is no longer reproducible in chrome 18). I think that in Safari we could do some fixing.
Chrome:
<p> test<sub>abc</sub><span style="font-size: 10px; ">abc</span></p>
Text in span gets pasted behind subscript.
Safari:
<p> test<sub>abcabc</sub>abcabcabcabcabc <body id="cke_pastebin" style="position: absolute; top: 17px; width: 1px; height: 1px; overflow-x: hidden; overflow-y: hidden; left: -1000px; "> </body>
First paste goes inside subscript, every other behind it.
- If you switch to source you will also see body element;
- then if you switch to WYSIWYG you will see nothing;
- if you switch to Source again - there will be correct code
- then if you switch to WYSIWYG there should be only
<p>test<sub>abcabc</sub>abcabcabcabcabc</p>
Result presented for IE8 Quirks can also be acquired using IE8 normal mode and IE9.
In FF it all depends whether you leave the sub element boundaries (text is pasted within p) or stay within (text pasted as new sub). But this is how FF works so it's fine here.