Closed
Bug 254748
Opened 20 years ago
Closed 20 years ago
Midas creates empty blocks as <></> when deleting text
Categories
(SeaMonkey :: Composer, defect)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 247276
People
(Reporter: santiagobz, Unassigned)
References
()
Details
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en) AppleWebKit/125.2 (KHTML, like Gecko) Safari/125.8
Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-0;en-US; rv:1.7) Gecko/20040614 Firefox/0.9
In a rich text editor, when deleting at the beginning or end of a block element, empty tags <></> are
created and the blocks are broken (at least, on Firefox 0.9 over MacOS X).
If you have two Ps, e.g.
<p>line 1</p><p>line 2</p>
and press backspace while in the beginning of line 2 (or forward-delete at the end of line 1), you get
something odd as:
<>line1<br> line2</>
instead of
<p>line 1 line 2</p>
Applying the following stylesheet to the document where designMode is "on":
BODY BODY{border:1px solid red;margin:2px;padding:2px}
reveals that the <></> above are actually <body></body> being filtered by midas when entering
"source mode" in the Editor, after being created by the delete behavior.
The aforementioned stylesheet also reveals that further typing and deleting inside this blocks results in
more <body></body> being created around the block.
Reproducible: Always
Steps to Reproduce:
1. You have two Ps: <p>line 1</p><p>line 2</p>
2a. Place the caret at the beginning of line 2 and press backspace, or
2b. place the caret at the end of line 1 and press forward delete.
Actual Results:
3. Getting to "source mode" in the rich text editor shows something odd as:
<>line1<br> line2</>
Expected Results:
The editor should have preserved the fist line P block:
<p>line 1 line 2</p>.
The problem seems to have its root in the way Midas deals with block elements.
No <></> or <body></body> should be inserted when editing/deleting text.
*** This bug has been marked as a duplicate of 247276 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
Updated•20 years ago
|
Product: Browser → Seamonkey
You need to log in
before you can comment on or make changes to this bug.
Description
•