Open Bug 528078 Opened 15 years ago Updated 3 years ago

MIDAS Rich Text Editor, backspace before the first char removes all empty lines in text

Categories

(Core :: DOM: Editor, defect, P5)

x86
Windows Server 2003
defect

Tracking

()

UNCONFIRMED

People

(Reporter: robplascencia, Unassigned)

Details

(Keywords: testcase)

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.0.15) Gecko/2009101601 Firefox/3.0.15 (.NET CLR 3.5.30729)
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.0.15) Gecko/2009101601 Firefox/3.0.15 (.NET CLR 3.5.30729)

after typing 3 lines each with an empty line in between (total of 5 lines), if there is a backspace at the start of the 3rd line, the expected behavior is to remove the second line (empty line), but instead both empty lines (2nd and 4th) are removed.

Reproducible: Always

Steps to Reproduce:
1.paste the following html to rich text editing enable page (it could be an Iframe)

<p style="" quad="L" br="false">t1</p>

<br /><p style="" quad="L" br="false">t2</p>

<br /><p style="" quad="L" br="false">t3</p>
2.Position the cursor before t2 
3.Then hit backspace (you will see that the 2nd and 4th line will be removed)
Actual Results:  
t1
t2
t3

Expected Results:  
t1
t2

t3

I suspect that there might be a Regular expression that needs a little adjustment, please let me know if you need any help debugging, I would like to contribute...
Attached file test case HTML file
this file can help track down the issue, simply use the top part to paste the following:

<p style="" quad="L" br="false">t1</p>

<br /><p style="" quad="L" br="false">t2</p>

<br /><p style="" quad="L" br="false">t3</p>

and go to bottom part and position the cursor before t2 then hit backspace,
Priority: -- → P2
Note: Priority should only be set by developers please. resetting to --
See https://bugzilla.mozilla.org/page.cgi?id=fields.html#priority
Component: General → Editor
Keywords: testcase
Priority: P2 → --
Product: Firefox → Core
QA Contact: general → editor

Bulk-downgrade of unassigned, >=5 years untouched DOM/Storage bugs' priority.

If you have reason to believe this is wrong (especially for the severity), please write a comment and ni :jstutte.

Severity: normal → S4
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: