forked from Robbbb/VectorRuler
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
134 lines (123 loc) · 5.81 KB
/
index.html
File metadata and controls
134 lines (123 loc) · 5.81 KB
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
<!DOCTYPE html>
<html>
<head>
<title>Vector Ruler SVG Generator</title>
<meta charset="UTF-8">
<meta name="description"
content="A web-based applet for the generation of downloadable vector rulers, suitable for laser etching">
<meta name="keywords" content="Ilustrator,Vector,Vector Ruler, SVG, SVG ruler, Javascript SVG">
<meta name="author" content="Robb Godshaw">
<link rel="stylesheet" type="text/css" href="style.css">
<script type='text/javascript' src='https://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js'></script>
<script type="text/javascript" src="paper-full.js"></script>
<script type="text/javascript" src="rulerGenerator.js"></script>
</head>
<body>
<div class="bootstrap-frm">
<div class="ribbon">
<a href="https://github.com/starnutoditopo/VectorRuler"><img loading="lazy" width="149" height="149"
src="https://github.blog/wp-content/uploads/2008/12/forkme_right_white_ffffff.png?resize=149%2C149"
class="attachment-full size-full" alt="Fork me on GitHub" data-recalc-dims="1"></a>
</div>
<div class="bootstrap-padded">
<h1>Vector Ruler Generator
<span>Download a laser cuttable ruler to etch into your belongings and belts.</span>
</h1>
<form id="rulerParameters" action="">
<label>
<span>Start:</span>
<input type="text" id="startNo" value="0" />
</label>
<label>
<span>Width:</span>
<input type="text" id="rulerWidth" value="20" />
</label>
<label>
<span>Height:</span>
<input type="text" id="rulerHeight" value="1" />
</label>
<label>
<span>Font size:</span>
<input type="text" id="fontSize" value="30" />
</label>
<label>
<span>Font family:</span>
<select id="fontFamily" name="fontFamily">
<option value="serif">serif</option>
<option value="sans-serif">sans-serif</option>
<option value="cursive">cursive</option>
<option value="fantasy">fantasy</option>
<option value="monospace" selected>monospace</option>
</select>
</label>
<label>
<span>Units:</span>
</label>
<Input type="radio" name="rulerUnits" value="inches">Inches</input>
<Input type="radio" name="rulerUnits" value="centimeters" checked>Centimeters</input>
<br>
<Input type="radio" name="subUnits" value="2">Fractional</input>
<Input type="radio" name="subUnits" value="10" checked>Decimal</input>
<br>
<label>
<span>Subdivisions: </span>
<select id="subUnitExponent" style="width:30%">
<option value="0">Zero</option>
<option value="1" selected>One</option>
<option value="2">Two</option>
<option value="3">Three</option>
<option value="4">Four</option>
<option value="5">Five</option>
<option value="6">Six </option>
</select>
</label>
<label>
<span>Smaller tick legnth:</span>
<select id="levelToLevelMultiplier" style="width:30%">
<option value="0.1">0.1</option>
<option value="0.2">0.2</option>
<option value="0.3">0.3</option>
<option value="0.4">0.4</option>
<option value="0.5" selected>0.5 - Default</option>
<option value="0.6">0.6</option>
<option value="0.7">0.7</option>
<option value="0.8">0.8 </option>
<option value="0.9">0.9 </option>
<option value="1">1.0 - All ticks same size </option>
</select>
</label>
<br>
<label>
<span>Other options</span>
</label>
<input type="checkbox" name="redundant" id="redundant">Draw redundant lines</input><br />
<label>
<span></span>
</label>
<input type="checkbox" name="absolute" id="absolute" checked>Display absolute values in labels</input><br />
<label>
<span>Multiply by:</span>
<input type="text" id="multiplyFactor" value="5" />
</label>
<br>
<label>
<span>Additional label:</span>
<input type="text" id="additionalLabel" value="Scale 1:500000 — 1 cm → 5 Km" />
</label>
</form>
<form id="svgexpform" method="post" action="http://download-data-uri.appspot.com/">
<b>Filename: </b>
<input type="text" name="filename" value="exportedRuler.svg">
<input id="svgexpdata" name="data" value="123" type="hidden">
<a href="#" id="downloadSVG">
<input type="button" class="button" value="Download ruler as .SVG" id="svgexpbutton">
</a>
</form>
<hr>
</div>
<div style="overflow-x:scroll;">
<canvas id="myCanvas" resize></canvas>
</div>
</div>
</body>
</html>