Closed Bug 719360 Opened 14 years ago Closed 14 years ago

Assigning white space to text node nodeValue breaks layout

Categories

(Core :: Layout: Block and Inline, defect)

11 Branch
x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 713856

People

(Reporter: nottheoilrig, Unassigned)

Details

User Agent: Mozilla/5.0 (X11; Linux i686; rv:11.0a2) Gecko/20120116 Firefox/11.0a2 Build ID: 20120116042010 Steps to reproduce: I have a text node whose nodeValue property contains only white space (space and carriage return). If I reassign the same value to the property (textNode.nodeValue = textNode.nodeValue) then the page layout changes: vertical white space appears. If I assign only white space that doesn't contain carriage return to the property, vertical white space disappears. But if I assign only white space that does contain carriage return, vertical white space appears Test case: http://nottheoilrig.com/nodevalue/ Actual results: If I reassign the same value to nodeValue property (textNode.nodeValue = textNode.nodeValue) then the page layout changes: vertical white space appears. If I assign only white space that does contain carriage return to the property, vertical white space appears Expected results: I expect the page layout of two text nodes with identical nodeValue properties to be identical, whether the property was assigned to (with identical value) or not. A text node whose nodeValue property contains only white space and carriage return doesn't normally cause vertical white space to appear in page layout, so if I assign only white space and carriage return to the property, then I likewise expect vertical white space not to appear
Testcase worksforme in a trunk build. I seem to recall Ehsan recently fixing a bug about this... Ehsan, do we need to backport that fix to 11?
Whiteboard: DUPEME
Ah, bug 713856. Looks like it wasn't a new problem in 11, so probably not needing a backport. Jack, Firefox 12 will have this fixed.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → DUPLICATE
Whiteboard: DUPEME
Thank you!
You need to log in before you can comment on or make changes to this bug.