Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(43)

Side by Side Diff: LayoutTests/fast/text/sub-pixel/text-scaling-vertical.html

Issue 25512005: Enable experimental support for sub-pixel font scaling (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 <!DOCTYPE>
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
5 <link rel="stylesheet" type="text/css" href="resources/text-scaling.css" >
6 <script src="resources/text-scaling.js"></script>
7 <script src="../../../resources/js-test.js"></script>
8 <style>
9 section > div {
10 -webkit-writing-mode: vertical-rl;
11 writing-mode: vertical-rl;
12 }
13 section > div > div.header {
14 border-width: 0 0 0 1px;
15 }
16 section > div > div > div {
17 width: auto;
18 height: 12ex;
19 padding: 0 0 1ex 0;
20 }
21 </style>
22 </head>
23 <body>
24 <section>
25 <h1>Font Size Scaling (vertical-rl, Latin)</h1>
26 <p>
27 Size of the text should scale smoothly.
28 Reported height (logical width) should be within 0.01px
29 of that of the highlighted reference row.
30 </p>
31 <div id="test"></div>
32 </section>
33 <script>
34 if (window.testRunner && window.testRunner.setTextSubpixelPositionin g)
35 window.testRunner.setTextSubpixelPositioning(true);
36
37 var PANGRAM = 'Flygande bäckasiner söka hwila på mjuka tuvor.';
38 var results = runTest(document.getElementById('test'), PANGRAM, 'ver tical');
39
40 if (results == PASS) {
41 testPassed('Size of text scales smoothly and logical width scale s with font size as expected.');
42
43 // Hide text if test passes as the actual numbers are
44 // different across platforms and would require platform
45 // specific baselines.
46 if (window.testRunner)
47 document.getElementById('test').style.display = 'none';
48 } else {
49 testFailed('Size of text does not scale smoothly, reported logic al widths highlighted in red do not match reference row.');
50 }
51 </script>
52 </body>
53 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698