Make WordPress Core

Opened 4 years ago

Closed 4 years ago

#17927 closed defect (bug) (fixed)

DFW improperly increasing TinyMCE iframe body height on WebKit browsers w/ zoom !=100%

Reported by: zekeweeks Owned by: azaozz
Milestone: 3.2 Priority: normal
Severity: normal Version: 3.2
Component: Editor Keywords: has-patch commit
Focuses: Cc:


When entering DFW from a WebKit browser with zoom set to something other than 100%, the MCE iframe's <body> element increases its height with some wildly exaggerated math. With zoom set to 120%, a post with containing, "Don't forget to bring a towel!" increases the iframe <body> - and thus its container and the overall page vertical scroll - to 85,058px height.

Steps to reproduce:

  1. Launch Chrome/Safari
  2. Set browser zoom to something higher than 100%.
  3. Edit a new/existing post with DFW enabled and write just a sentence or so worth of characters. Note that the TinyMCE body and entire page height will increase with some disproportionate math as you add each character.
  4. Change your browser zoom to something lower than 100% and note that the same thing occurs until you've hit the TinyMCE container's minimum height.

Suspected issue: The math auto-adjusting TinyMCE body/container height as character increases conflicts with WebKit's zooming metrics.

Occurs on:

  • 3.2-RC2-18370
  • wordpress.com as of this filing
  • Chrome 12 (Mac, Windows)
  • Safari 5 (Mac)
  • Doesn't occur on Firefox/IE.

Attachments (1)

17927.patch (6.4 KB) - added by azaozz 4 years ago.

Download all attachments as: .zip

Change History (6)

comment:1 @nacin4 years ago

  • Milestone changed from Awaiting Review to 3.2
  • Owner set to azaozz
  • Status changed from new to reviewing

Thanks for the report - this sounds like it might result in memory/performance issues so I'm going to move to 3.2 for proper review.

comment:2 @azaozz4 years ago

This is a known bug in WebKit. On top of that it doesn't report the body height properly, i.e. if the body element is made taller and then the content is deleted, it still reports the previous size.

Don't think there are any performance issues but it looks pretty bad and can make DFW unusable when zoom != 100% in WebKit.

@azaozz4 years ago

comment:3 @azaozz4 years ago

  • Keywords has-patch added

comment:4 @westi4 years ago

  • Keywords commit added

Looks good.

comment:5 @azaozz4 years ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In [18379]:

Fix DFW autoresizing in WebKit when zoom != 100%, fixes #17927

Note: See TracTickets for help on using tickets.