marijnh/CodeMirror — pull request #2021 by hitsthings (2013-12-02 00:01:30+00:00)
Title: Fix IE showing empty with 0 padding and resize-to-content

Fixes #2011 in at least IE8+.

When the resize-to-content styles are applied along with a removal of vertical padding on .CodeMirror-lines, IE would not display any content. Using `offsetWidth` instead of `clientWidth` fixes this for modern-ish IE.

A more complex solution is needed to solve it for older browsers.

Working example based on this PR is at http://jsbin.com/IWaCobaR/5/edit
Tests passed in Travis: https://travis-ci.org/hitsthings/CodeMirror (just merged this branch into my master)