about summary refs log tree commit diff stats
path: root/undo.lua
Commit message (Collapse)AuthorAgeFilesLines
* line.y -> line_cache.starty in a few more placesKartik K. Agaram2022-07-271-2/+2
| | | | | | Disquieting that none of my tests caught these. On the other hand, I also haven't noticed any issues in practice. Perhaps cache invalidation is often unnecessary.
* separate data structure for each line's cache dataKartik K. Agaram2022-07-171-0/+11
| | | | I have no idea what the performance implications of this are..
* add state arg to a few functionsKartik K. Agaram2022-07-121-24/+24
| | | | | | | - record_undo_event - undo_event - redo_event - snapshot
* group all editor globalsKartik K. Agaram2022-07-121-20/+20
| | | | We're still accessing them through a global. But we'll change that next.
* stop saving the entire file when modifying drawingsKartik K. Agaram2022-06-101-4/+2
| | | | Now we just disallow that entirely.
* undo creating new drawingsKartik K. Agaram2022-06-101-0/+5
|
* crisp font renderingKartik K. Agaram2022-06-021-1/+0
|
* more efficient undo/redoKartik K. Agaram2022-06-021-2/+35
| | | | | Now the bottleneck shifts to applying undo/redo in large files. But things should be snappy if you don't use the sluggish feature.
* renameKartik K. Agaram2022-06-021-1/+1
|
* after much struggle, a brute-force undoKartik K. Agaram2022-06-021-0/+78
Incredibly inefficient, but I don't yet know how to efficiently encode undo mutations that can span multiple lines. There seems to be one bug related to creating new drawings; they're not spawning events and undoing past drawing creation has some weird artifacts. Redo seems to consistently work, though.
pan class='oid'>a2c5233 ^
c38ddf8 ^






a2c5233 ^
c38ddf8 ^








a2c5233 ^

































































c38ddf8 ^




















a2c5233 ^
c38ddf8 ^

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