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

Side by Side Diff: third_party/WebKit/LayoutTests/svg/hittest/text-multiple-dx-values.svg

Issue 1454623002: Hit test SVG line boxes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add forgotten test. Sorry, test! Created 5 years, 1 month 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
OLDNEW
(Empty)
1 <svg onload="runTest()" width="500" height="150" viewBox="0 0 1000 300" xmlns="h ttp://www.w3.org/2000/svg">
2 <script src="../../resources/ahem.js"></script>
3 <rect id="background" width="100%" height="100%" fill="blue" />
4 <text id="text" x="10" y="1em" dx="0 50 100">Foo</text>
5 <defs>
6 <style type="text/css">
7 <![CDATA[
8 text {
9 font-family: Ahem;
10 font-size: 40px;
11 }
12 ]]>
13 </style>
14 <script type="text/javascript">
15 <![CDATA[
16 function runTest() {
17 if (window.testRunner)
18 testRunner.dumpAsText();
19
20 // (15,15) is within a glyph cell of #text, (35,15) is not.
21 var text = document.getElementById("text");
22 var background = document.getElementById("background");
23 if (document.elementFromPoint(15, 15) === text && document.eleme ntFromPoint(35, 15) === background)
24 text.textContent = "PASS";
25 else
26 text.textContent = "FAIL";
27 }
28 ]]>
29 </script>
30 </defs>
31 </svg>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698