- I hid "Ctrl+W" previously, but Ctrl+R is also destructive.
- And Alt+F4 closes the whole browser window, not just the (web) application.
- For File > New, Ctrl+Alt+N works as an alternative; list that.
- For Image > Clear Image, Ctrl+Shift+N works in Firefox, but opens an incognito window in chrome; add browser detection.
- Ctrl+R, Ctrl+L, Ctrl+T, Ctrl+PgDn, and Ctrl+PgUp are not actually implemented.
- Fix showing Ctrl+G (typo "shorcut")
- Instead of creating an OnCanvasTextbox or OnCanvasSelection object during selection, draw the preview in the tool
- Get it looking exactly like it does in mspaint (as far as I can tell)
- Fix how selection rect is determined
- Don't create textbox or selection if width or height would be 1
- Don't draw unless the pointer has moved
$ lebab --replace src/ --transform destruct-param
src/canvas-change.js:
23: warning 5 different props found, will not transform more than 4 (destruct-param)
Don't destructure events or elements, or (otherwise) lose important context from the variable name.
- Don't pretend like it's a class
- Split a variable definition (which would have been really bad practice if it was actually a class)
- Take args directly instead of in an array
$ lebab --replace src/ --transform for-of
src/extra-tools.js:
34: warning Unable to transform for loop (for-of)
89: warning Unable to transform for loop (for-of)
src/functions.js:
291: warning Unable to transform for loop (for-of)
796: warning Unable to transform for loop (for-of)
1095: warning Unable to transform for loop (for-of)
1123: warning Unable to transform for loop (for-of)
1128: warning Unable to transform for loop (for-of)
1138: warning Unable to transform for loop (for-of)
1190: warning Unable to transform for loop (for-of)
1221: warning Unable to transform for loop (for-of)
1222: warning Unable to transform for loop (for-of)
1245: warning Unable to transform for loop (for-of)
1249: warning Unable to transform for loop (for-of)
src/image-manipulation.js:
48: warning Unable to transform for loop (for-of)
74: warning Unable to transform for loop (for-of)
337: warning Unable to transform for loop (for-of)
558: warning Unable to transform for loop (for-of)
604: warning Unable to transform for loop (for-of)
672: warning Index variable used in for-loop body (for-of)
675: warning Unable to transform for loop (for-of)
831: warning Unable to transform for loop (for-of)
848: warning Unable to transform for loop (for-of)
877: warning Unable to transform for loop (for-of)
src/OnCanvasSelection.js:
132: warning Unable to transform for loop (for-of)
176: warning Unable to transform for loop (for-of)
src/OnCanvasTextBox.js:
134: warning Unable to transform for loop (for-of)
src/simulate-random-gestures.js:
94: warning Unable to transform for loop (for-of)
111: warning Unable to transform for loop (for-of)
src/storage.js:
22: warning Unable to transform for loop (for-of)
src/tool-options.js:
40: warning Unable to transform for loop (for-of)
58: warning Unable to transform for loop (for-of)
src/tools.js:
75: warning Unable to transform for loop (for-of)
251: warning Unable to transform for loop (for-of)
389: warning Unable to transform for loop (for-of)
393: warning Unable to transform for loop (for-of)
508: warning Unable to transform for loop (for-of)
$ lebab --replace src/ --transform let
src/$Component.js:
59: warning Unable to transform var (let)
60: warning Unable to transform var (let)
97: warning Unable to transform var (let)
138: warning Unable to transform var (let)
src/$Window.js:
74: warning Unable to transform var (let)
src/app.js:
662: warning Unable to transform var (let)
460: warning Unable to transform var (let)
612: warning Unable to transform var (let)
613: warning Unable to transform var (let)
614: warning Unable to transform var (let)
src/functions.js:
756: warning Unable to transform var (let)
src/image-manipulation.js:
245: warning Unable to transform var (let)
826: warning Unable to transform var (let)
src/imgur.js:
48: warning Unable to transform var (let)
173: warning Unable to transform var (let)
- Always use screen pixel scale for helper layer
- Move responsibility for non-integer handling into draw_grid (instead of using an integer scale for the whole helper layer)
- This allows the Magnifier viewport preview and Eraser preview to draw with a consistent line width
- TODO: Try applying sub-1px margin or padding or left/top or translate or something to canvas-area to get helper layer canvas to line up with screen pixels perfectly
Make the border go on top of the swatches so it blends with them and doesn't just create an ugly gray around them.
(It especially looked bad on the orange in the corner, which is around the same perceptive brightness as the gray.)
- Use modern sprites for tool icons and transparency options
- Use modern selection color for tool options
- Add a border around the canvas area to separate the canvas from the UI
- Slightly round the corners of the color wells and selected colors