-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
191 lines (190 loc) · 5.44 KB
/
index.html
File metadata and controls
191 lines (190 loc) · 5.44 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
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
<!DOCTYPE html>
<html>
<head>
<title>
Gvbvdxx Paint - A free, better version of MS Paint, with a working
transparent canvas.
</title>
<link rel="icon" href="favicon.png" />
<link rel="manifest" href="manifest.webmanifest" />
</head>
<body style="background: #8c8c8c; font-family: arial">
<style>
#menu-bar {
background: #adadad;
top: 0;
left: 0;
position: fixed;
width: 100vw;
height: 32px;
}
#paint-options {
background: #a3a3a3;
top: 32px;
left: 0;
position: fixed;
width: 200px;
height: calc(100vh);
overflow: scroll;
}
#paint-canvas {
image-rendering: pixelated;
background-size: 32px 32px;
background: white;
}
#paint-area {
position: fixed;
top: 32px;
left: 200px;
overflow: scroll;
width: calc(100vw - 200px);
height: calc(100vh - 30px);
}
.paint-button-1 {
background: #cccccc;
border: none;
border-radius: 5px;
cursor: pointer;
}
.paint-button-1:hover {
background: #b8b6b6;
}
.paint-input-1 {
background: #cccccc;
border: none;
border-radius: 5px;
outline: none;
}
.paint-input-1:focus {
background: #b8b6b6;
}
.menu-button {
height: 32px;
cursor: pointer;
background: #adadad;
border: none;
}
.menu-button:hover {
color: white;
font-weight: bold;
}
#realtimeCursors {
position: absolute;
transform-origin: top left;
pointer-events: none;
overflow: hidden;
}
.realtimeCursorContainer {
position: relative;
opacity: 0.5;
color: black;
height: 20px;
width: fit-content;
top: 50px;
left: 0;
font-weight: bold;
font-size: 20px;
display: flex;
pointer-events: none;
}
.realtimeCursorImage {
height: 20px;
width: 20px;
margin-right: 4px;
}
</style>
<div id="menu-bar" style="display: flex; line-height: 32px">
<button class="menu-button" id="save">Download</button>
</div>
<div id="paint-options">
<button class="paint-button-1" onclick="changeMode('brush')">
<img width="32" height="32" src="src/brush.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('rect')">
<img width="32" height="32" src="src/rectangle.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('circle')">
<img width="32" height="32" src="src/circle.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('outline-rect')">
<img width="32" height="32" src="src/outline-rectangle.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('line')">
<img width="32" height="32" src="src/line.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('text')">
<img width="32" height="32" src="src/text.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('fill')">
<img width="32" height="32" src="src/fill.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('spray')">
<img width="32" height="32" src="src/spray.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('erase')">
<img width="32" height="32" src="src/eraser.svg?n=1" />
</button>
<button class="paint-button-1" onclick="changeMode('get color')">
<img width="32" height="32" src="src/takecolor.svg?n=1" />
</button>
<hr />
<span id="MODE"></span>
<hr />
<h3>Drawing properties</h3>
<small id="selectInfo"></small>
<!--<div hidden>-->
<label>Zoom:</label
><input
id="zoom"
type="range"
min="0"
max="500"
value="100"
class="paint-input-1"
/><br />
<!--</div>-->
<label>Size:</label
><input
id="thickness"
type="range"
min="1"
max="100"
value="5"
class="paint-input-1"
/><br />
<label hidden>Circle resolution:</label
><input
id="circleResolution"
type="range"
min="5"
max="360"
value="90"
class="paint-input-1"
hidden
/><br hidden />
<label>Color:</label
><input id="color" type="color" class="paint-input-1" /><br />
<label>Transparent Fill Color:</label
><input id="transparent" type="checkbox" class="paint-input-1" /><br />
<label>Dot brush:</label
><input id="dot" type="checkbox" class="paint-input-1" /><br />
<label>Text (value):</label
><input
id="textValue"
type="text"
style="width: 90px"
class="paint-input-1"
/>
<hr />
<h3>Other</h3>
<button class="paint-button-1" id="erase">Erase all</button>
<button class="paint-button-1" id="undoButton">Undo</button>
</div>
<div id="paint-area">
<div id="realtimeCursors" style="width: 3000px; height: 600px"></div>
<canvas id="paint-canvas" width="3000" height="600"></canvas>
</div>
<script src="index.js?n=1"></script>
<script src="online.js?n=1"></script>
</body>
</html>