/
d3_peter10_2.html
74 lines (74 loc) · 2.52 KB
/
d3_peter10_2.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<body translate="no">
<table border="0">
<tbody>
<tr>
<td></td>
<td>SVG</td>
<td>DIV <sup>1</sup></td>
</tr>
<tr>
<td>stroke-width 1rem</td>
<td>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40">
<path style="stroke:#000; stroke-width:1rem;" d="M0 20L40 20"></path>
</svg>
</td>
<td>
<div></div>
</td>
</tr>
<tr>
<td>stroke-width 1em</td>
<td>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40">
<path style="stroke:#000; stroke-width:1em;" d="M0 20L40 20"></path>
</svg>
</td>
<td>
<div></div>
</td>
</tr>
<tr>
<td>stroke-width 25%</td>
<td>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40">
<path style="stroke:#000; stroke-width:25%;" d="M0 20L40 20"></path>
</svg>
</td>
<td>
<div></div>
</td>
</tr>
<tr>
<td>stroke-width 10px <sup>2</sup></td>
<td>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40">
<path style="stroke:#000; stroke-width:10px;" d="M0 20L40 20"></path>
</svg>
</td>
<td>
<div></div>
</td>
</tr>
<tr>
<td>stroke-width 10px <sup>3</sup></td>
<td>
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 40 40">
<path vector-effect="non-scaling-stroke" style="stroke:#000; stroke-width:10px;" d="M0 20L40 20"></path>
</svg>
</td>
<td>
<div></div>
</td>
</tr>
</tbody>
</table>
<p>
<sup>1</sup> DIV height is 1rem<br>
<sup>2</sup> Without <em>vector-effect="non-scaling-stroke"</em><br>
<sup>3</sup> With <em>vector-effect="non-scaling-stroke"</em>
</p>
<p>
Compare zooming in Firefox (with <em>"only text"</em> option) and Chrome
</p>
</body>