﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
9998	[Blink] In Chrome SPAN tags appear when merging paragraphs with delete/backspace.	lmeurs		"Occurs in Chrome v24.0.1312.56 / CKEditor 4.0.1 (revision d02739b) / CKEditor 4 DEV (Standard) (revision d02739b) (nightly build demo)

Did not occur in Firefox v17.0.1

When you have a paragraph with several lines of text, ie.:

{{{
<p>line1<br />
line2</p>
}}}

and want to create 2 separate paragraphs, you could go with your cursor to the end of line1, press ENTER to create a new paragraph and press DELETE to remove the whiteline caused by the BR tag. Then CKEditor puts some HTML in a SPAN tag with a line-height styling.

{{{
<p>line1</p>
<p><span style=""line-height: 1.6em;"">line2</span></p>
}}}

Other examples: It also happens when trying to create a single line out of the next cases:

{{{
<p><br />
line2</p>
}}}

and

{{{
<p>line1</p>
<p>line2</p>
}}}

== Edits ==

* **This happens when two paragraphs are joined with delete. Tag br has nothing to do here. **

* **Another TC: http://stackoverflow.com/questions/14952515/ckeditor-entermode-issue-in-chrome**

  Content: {{{<h1>^test</h1>}}} + enter + backspace creates awful mess.

* Browser issues:
    * http://code.google.com/p/chromium/issues/detail?id=226941
    * https://bugs.webkit.org/show_bug.cgi?id=114791

* Related issues: #8438, #8439, #8440, #10359, #10515, #11483, #11592.

----

== Cases ==

=== <span> created while joining two adjacent elements ===
Related issues: #9998

==== Example 1 ==== 

1. `<p>foo</p>`
2. `<p>^bar</p>`
3. Backspace.
4. `<p>line1<span style=""line-height:1.6"">line2</span></p>`

==== Example 2 ==== 

1. `<h1>foo</h1>`
2. `<p>^bar</p>`
3. Backspace.
4. `<h1>foo<span style=""font-size:13px; line-height:1.6"">bar</span></h1>`

=== Attempt to preserve the visual style of the contents -> i.e. <strong> becomes <b> === 

==== Backspace (unable to remove formatting) ====

Related issues: #8438, #11592, #11483

1. `<p>x<strong>y^</strong></p>`
2. Backspace.
3. Type “z”.
4. `<p>x<b>z^</b></p>`

====  Backspace (underlined link becomes `<u>`) ==== 

Related issues: #11592

1. `<p><a href=""http://foo"">[foo]</a>bar</p>`
2. Backspace.
3. Type ""foo"".
4. `<p><u>foo^</u>bar</p>`
5. ''Frown''
6. ''Grin''

'''Note''': This case uncovers the algorithm used in Webkit. 
The engine attempts to preserve the style no matter how ridiculous it would be – it uses `<u>` because it is the closest style, 
which corresponds visually with underlined link.

==== Del (unable to remove formatting) ==== 

Related issues: #8439, #8440

1. `<p>foo</p>`
2. CTRL+A.
3. Bold.
4. DEL.
5. Type “bar”.
6. `<p><b>bar^</b></p>`

=== <span> created while splitting elements (DnD), extra &nbsp; === 
  Related issues: #10515

1. Set the following HTML
 {{{
<p>
    <span style=""font-size:28px"">
        foo 
        <strong>[bar]</strong> 
        <em>bam</em> 
        bang
    </span>
</p>
}}}
2. Drag `[bar]` into `ba|m`
3. `editor.getData()`.
4. See the result.
 {{{
<p>
    <span style=""font-size:28px"">
        foo &nbsp;
        <em>ba</em>
    </span>
    <strong style=""font-size:28px; line-height:44.79999923706055px"">bar</strong>
    <em style=""font-size:28px; line-height:1.6"">m</em>
    <span style=""font-size:28px; line-height:1.6""> bang</span>
</p>
}}}
5. Then WYSIWYG->Source->WYSIWYG.
6. ACF brings the ultimate destruction.
 {{{
<p>
    <span style=""font-size:28px"">foo &nbsp;<em>ba</em></span>
    <strong>bar</strong>
    <em>m</em>
    <span style=""font-size:28px""> bang</span>
</p>
}}}"	Bug	confirmed	High		General	4.0		Chrome	laura@… ben@… matti.jarvinen@… ivanjh@… joel.peltonen@…
