annotate src/events.nim @ 477:f226c99b5043

add: matrix multiplications, tests
author Sam <sam@basx.dev>
date Fri, 30 Dec 2022 15:56:17 +0700
parents 1dd9e2393a9e
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
466
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
1 type
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
2 EventType* = enum
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
3 Quit
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
4 ResizedWindow
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
5 KeyDown
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
6 KeyUp
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
7 Key* = enum
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
8 UNKNOWN
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
9 A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, Z
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
10 a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
11 `1`, `2`, `3`, `4`, `5`, `6`, `7`, `8`, `9`, `0`
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
12 Minus, Plus, Underscore, Equals, Space, Enter, Backspace, Tab
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
13 Comma, Period, Semicolon, Colon,
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
14 Escape, CtrlL, ShirtL, AltL, CtrlR, ShirtR, AltR
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
15 Event* = object
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
16 case eventType*: EventType
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
17 of KeyDown, KeyUp:
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
18 key*: Key
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
19 else:
1dd9e2393a9e add: structure code for crossplatform, add some input handling + bugfixes
Sam <sam@basx.dev>
parents:
diff changeset
20 discard