WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
51620
white-space:pre does not work on contenteditable elements
https://bugs.webkit.org/show_bug.cgi?id=51620
Summary
white-space:pre does not work on contenteditable elements
Nico Weber
Reported
2010-12-26 09:56:17 PST
Created
attachment 77460
[details]
repro case white-space:pre should not add any line breaks. This works fine with normal elements, but breaks when an element becomes contenteditable. See the attached repo case. Expected: Both elements in the repo case look the same. Actual: The contents of the contenteditable div get wrapped. Works fine in Ff3.6 and Ff4 beta.
Attachments
repro case
(615 bytes, text/html)
2010-12-26 09:56 PST
,
Nico Weber
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Patrick Gillespie
Comment 1
2012-05-19 15:23:20 PDT
Ran into this same issue. Firefox and IE behave differently than Safari and Chrome. Created another test case page:
http://patorjk.com/browser-issues/contentedibable-pre.htm
Ryosuke Niwa
Comment 2
2012-05-19 20:37:25 PDT
I suppose this is caused by applyEditingStyleToElement:
http://trac.webkit.org/browser/trunk/Source/WebCore/editing/Editor.cpp?rev=117590#L2695
holytrousers
Comment 3
2018-01-18 08:44:53 PST
this problems seems to be fixed in chromium but it is still present in webkit2gtk. Seems quite impotant to me as it also affects text-areas
Nico Weber
Comment 4
2023-08-17 06:12:38 PDT
Looks like this got fixed at some point.
Radar WebKit Bug Importer
Comment 5
2023-08-17 06:13:14 PDT
<
rdar://problem/114023429
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug