Releases: 1j01/jspaint
Releases · 1j01/jspaint
v1.1.0
Embedding API
Changed
systemHooks.writeBlobToHandlepromise can resolve withtrueto indicate success, in which case File > Save will not prompt to save the file again.falseindicates failure or cancellation, whereasundefinedcan be used if it is unknown whether the file will be saved successfully, as is the case when using thedownloadattribute on an anchor element. If saving as a monochrome bitmap,undefinedwill cause the canvas to become monochrome, but it will still prompt to save the file again. This tradeoff is reasonable because the download attribute doesn't support saving over an already saved file anyways- Marked more parts of the API as optional (⟜)
Fixed
App
Added
- AppImage build for Linux (in addition to the existing .deb and .rpm builds)
- macOS menu bar integration (the menu bar in the app is now mirrored to the macOS menu bar)
- Extras > Draw Randomly (screensaver-like mode)
- Extras > Themes > Bubblegum
- Extras > Head Tracker powered by Tracky Mouse
- View > Text Toolbar to toggle the Fonts box
- Vertical text editing support (find the option in the Text Toolbar, AKA Fonts box)
Changed
- Split out "Eye Gaze Mode" into discrete features: "Enlarge UI", "Quick Undo Button", "Dwell Clicker"
- Restructured About window content (⟜, ⟜, ⟜, ⟜)
- (It's now much more compact while including more information)
- Improved Imgur upload error dialogs (⟜)
- Changed width/height separator to an 'x' in status bar (was a comma) (⟜)
- Implemented size status indicator for all tools (⟜)
- Added offset effect to pressed buttons in font box (⟜)
Fixed
- When printing, the canvas border and any in-progress polygons or curves are now hidden, and the size of the document is corrected (⟜, ⟜, ⟜)
- Fixed drawing position misalignment with cursor (⟜)
- Fixed Help Topics window iframe being blocked by CSP (not sure if this was actually broken in the last release) (⟜)
- Fixed prompt to save changes when clicking File > Exit (⟜)
- Fixed Shift+Insert, Ctrl+Insert, and Ctrl+Delete shortcuts (⟜)
- Fixed error handling for clipboard access (⟜)
- Fixed format selection when saving a palette in the Electron app (⟜)
- Fixed default file name when saving selection with Edit > Copy To or using File > Set As Wallpaper (⟜, ⟜)
- Fixed tiled checkboxes (a visual bug) in the Electron app in Enlarge UI mode (⟜)
- Menus are now scaled down as needed in Enlarge UI mode to fit all items
- An image dropped on news window will no longer open the image in the app (⟜)
- Added handling for smooth scrolling for zooming with mousewheel/trackpad (⟜)
- Updated electron to 20.3.12 (⟜)
- This brings in Chrome 104, which supports the Local Font Access API, allowing the Fonts box to list all installed fonts when using the Text tool.
- Fixed fonts dropdown closing immediately when clicked in Chrome (⟜)
- Fixed About window centering on small screens (⟜)
Internal
- Converted project almost entirely to ES Modules
- Split up several huge files
- Set up ESLint and improved code consistency
- Added typechecking all across the codebase
- Updated os-gui.js and tracky-mouse.js
- Automated the desktop app release process with GitHub Actions and scripts developed for the Tracky Mouse project (⟜)
External
- Added a Privacy Policy
- There's a friendly Discord server you can join to share your art!
v1.0.0-beta.1
Electron app features:
- Cross-platform (macOS, Windows, Linux)
- Native-like experience (no address bar, etc.)
- File > Save will save directly to the file (rather than downloading a copy)
- Files can be opened in various ways:
- File > Open
- Drag and drop onto window
- Drag and drop onto dock icon on macOS
- Drag and drop onto desktop shortcut
- Right Click > Open With in file manager (macOS and Linux)
- On Windows, you can set up a registry file to add this option... more or less. I've made it generate a registry file, but you have to manually apply it, and it only adds it to Show more options > Edit in Windows 11.
- Command line:
jspaint some/path/to/a/file.png
- File > Set As Wallpaper (Tiled) and File > Set As Wallpaper (Centered)
- On macOS, an icon representing the currently open file is shown in the titlebar. You can drag this icon into other applications, for example to include the image you're editing in an email. The icon is dimmed while there are unsaved changes.
Electron app limitations
- Basics:
- Execution is blocked by default on Mac and Windows
- On macOS you need to Ctrl+click the file and then say Open
- On Windows, you need to say "More info" and then "Run" (or "Run anyway"?)
- I would need to pay a fee for code signing to avoid this. It's basically security by extortion.
- There are no automatic updates. Apparently I would need to pay a fee for code signing to get this free service.
- That said, Help > About Paint can tell you if JS Paint is out of date, at least in terms of news updates.
- Electron is out of date. It may, for instance, contain image decoding vulnerabilities that have since been fixed. However, I've taken precautions to sandbox the app and restrict write access to a list of files explicitly opened in the app, the list being controlled by the main process, separate from the renderer process which would handle image decoding.
- Only a single editor window can be opened at once.
- The File menu's recent files list is not implemented, nor are OS-specific jump menus.
- Execution is blocked by default on Mac and Windows
- Minor details:
- The Windows registry (.reg) file generated points to a specific version of the app "C:\Users\Isaiah\AppData\Local\jspaint\app-1.0.0\jspaint.exe" instead of "C:\Users\Isaiah\AppData\Local\jspaint\jspaint.exe"
- I guess this wouldn't be a problem if it manages the registry on every update, but it's manual for now, so it will break on any update
- A very confusing message is shown if you edit a document before clicking an Open link in the Manage Storage dialog.
- WebGL error messages tell you to refresh without offering a way to reload; also, calling the app a web page feels unpolished
- The File > Open dialog does not have an All Files (*.*) option, and the list of file types supported is not exhaustive; for example, AVIF images can be loaded but only by drag and drop
- Drag and drop shows two "Save changes to X?" dialogs on top of each other?
- The Windows registry (.reg) file generated points to a specific version of the app "C:\Users\Isaiah\AppData\Local\jspaint\app-1.0.0\jspaint.exe" instead of "C:\Users\Isaiah\AppData\Local\jspaint\jspaint.exe"
- I'm not sure if all of these are still issues, need to retest them:
- Quit doesn't exit app completely, only closes the window if it's open... intended behavior? shouldn't right click > Quit really quit? https://stackoverflow.com/questions/44316306/how-to-quit-electron-app-on-mac
- Quit doesn't show/focus window when save changes prompt is shown on maybe mac/linux
- Ctrl+C doesn't exit on mac/linux electron/electron#5273
- this is because of mainWindow.on('close') preventDefault and may be a feature but needs to show/focus the window
- https://stackoverflow.com/questions/75362687/electron-js-processes-do-not-exit-on-app-quit
- Opening an SVG file also isn't working via command line argument (dragging onto the shortcut in File Explorer) even though dragging and dropping into the window works.
- Seems to load load SVG as a palette... Is this what I was running into?