| <!DOCTYPE html> |
| <html> |
| <head> |
| |
| <meta name="viewport" content="width=800"> |
| <style> |
| html { font-size: 16px; } |
| body { width: 800px; margin: 0; overflow-y: hidden; } |
| </style> |
| |
| <script> |
| if (window.internals) { |
| window.internals.settings.setTextAutosizingEnabled(true); |
| window.internals.settings.setTextAutosizingWindowSizeOverride(320, 480); |
| } else if (window.console && console.warn) { |
| console.warn("This test depends on the Text Autosizing setting being true, so run it in DumpRenderTree, or manually enable Text Autosizing, and either use a mobile device with 320px device-width (like Nexus S or iPhone), or define HACK_FORCE_TEXT_AUTOSIZING_ON_DESKTOP."); |
| } |
| </script> |
| |
| </head> |
| <body> |
| |
| <div style="position: absolute; width: 400px"> |
| This text should be autosized to 20px computed font size (16 * 400/320), since the position:absolute causes this to be a new cluster. |
| </div> |
| |
| <div style="margin-top: 100px; float: left; width: 420px"> |
| This text should be autosized to 21px computed font size (16 * 420/320), since the float:left causes this to be a new cluster. |
| </div> |
| |
| <table> |
| <tr> |
| <td style="width: 380px"> |
| This text should be autosized to 19px computed font size (16 * 380/320), since being a table cell causes this to be a new cluster. |
| </td> |
| </tr> |
| </table> |
| |
| <div style="-webkit-writing-mode: vertical-rl; height: 440px"> |
| This text should be autosized to 22px computed font size (16 * 440/320), since the perpendicular writing-mode compared to its containing block causes this to be a new cluster. Unfortunately due to <a href="https://bugs.webkit.org/show_bug.cgi?id=96557">http://webkit.org/b/96557</a> the height:440px is incorrectly interpreted as constraining the logicalHeight, so it doesn't get autosized. |
| </div> |
| |
| </body> |
| </html> |