(measure)
| 1224 | |
| 1225 | var zwspSupported; |
| 1226 | function zeroWidthElement(measure) { |
| 1227 | if (zwspSupported == null) { |
| 1228 | var test = elt("span", "\u200b"); |
| 1229 | removeChildrenAndAdd(measure, elt("span", [test, document.createTextNode("x")])); |
| 1230 | if (measure.firstChild.offsetHeight != 0) |
| 1231 | { zwspSupported = test.offsetWidth <= 1 && test.offsetHeight > 2 && !(ie && ie_version < 8); } |
| 1232 | } |
| 1233 | var node = zwspSupported ? elt("span", "\u200b") : |
| 1234 | elt("span", "\u00a0", null, "display: inline-block; width: 1px; margin-right: -1px"); |
| 1235 | node.setAttribute("cm-text", ""); |
| 1236 | return node |
| 1237 | } |
| 1238 | |
| 1239 | // Feature-detect IE's crummy client rect reporting for bidi text |
| 1240 | var badBidiRects; |
no test coverage detected