New issue
Advanced search Search tips

Issue 603150 link

Starred by 3 users

Issue metadata

Status: Duplicate
Merged: issue 591793
Owner: ----
Closed: Apr 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug



Sign in to add a comment

white-space:pre-wrap causes browser to display information VERY slowly

Reported by henri.is...@gmail.com, Apr 13 2016

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.110 Safari/537.36

Example URL:
https://jsfiddle.net/edpq5qcy/3/

Steps to reproduce the problem:
1. See the full description here: http://stackoverflow.com/questions/35881860/white-space-pre-wrap-with-word-break-break-all-recently-became-very-slow-in-ch
2. Basically, any large text area that uses a style of "white-space: pre-wrap;" will cause the browser to "hang" for a long time.  "white-space:pre" works fine.

What is the expected behavior?
When using "white-space:pre-wrap" with a very large amount of text, it should display the data in the same speed as as "white-space:pre". Instead it takes browser 30 seconds or more to process the display and the browser appears as being hung.  Other browsers that took less than a second the display the data correctly.

What went wrong?
At that time, I was using "white-space:pre", but suddenly that stopped wrapping and we got very long horizontal scroll bars.  Switching to "white-space:pre-wrap" produced the correct display, but the browser would take 30 seconds or more to process it (compared to other browsers that took less than a second).  I tried this in the latest versions of Internet Explorer and FireFox and it works fine.  This behavior started about a month ago with an update to Chrome.

Does it occur on multiple sites: Yes

Is it a problem with a plugin? No 

Did this work before? Yes A month ago it worked with "white-space:pre" (but may not have worked correctly)

Does this work in other browsers? Yes 

Chrome version: 49.0.2623.110  Channel: stable
OS Version: 10.0
Flash Version: Shockwave Flash 21.0 r0
 
Cc: kojii@chromium.org e...@chromium.org
Components: -Blink Blink>Layout

Comment 2 by ylph...@gmail.com, Apr 15 2016

I think the issue is more specifically with "word-break: break-all;" - using just that and leaving white-space as default (normal) is already very slow.  

Specifying "white-space: pre-wrap;" and leaving word-break as default (also normal) is fast.

Here is a table of combinations I tried :

word-break  | white-space | result
normal      | *any*       | fast
keep-all    | *any*       | fast
break-all   | nowrap      | fast
break-all   | pre         | fast

break-all   | normal      | slow
break-all   | pre-line    | slow
break-all   | pre-wrap    | slow


Comment 3 by e...@chromium.org, Apr 18 2016

Mergedinto: 591793
Status: Duplicate (was: Unconfirmed)

Sign in to add a comment