Commit Graph

1089 Commits (8dd671f143f267c8b96c6ff5a1b7e7f569cbb98d)

Author SHA1 Message Date
Isaiah Odhner ecb6b8003d Add support check for Edge
https://developer.mozilla.org/en-US/docs/Web/API/CanvasPattern/setTransform
2019-12-04 13:46:45 -05:00
Isaiah Odhner 0d09c24f19 Update TODO
- Underline works now!
- Re: "Keep an old OnCanvasTextBox while drawing a new one" - even tho this should be easy now that it's not using that object to represent in progress selections, I don't think I want to do this! I think the way it works now is better.
2019-12-04 13:19:34 -05:00
Isaiah Odhner 0d57b73e97 Fix handle updating when changing the zoom 2019-12-04 12:32:32 -05:00
Isaiah Odhner 48ee283708 Make resizing work 2019-12-04 11:42:45 -05:00
Isaiah Odhner 27df7e6b41 Make it work with magnification 2019-12-04 11:26:23 -05:00
Isaiah Odhner d3f1ce9fb6 WIP: make Text tool WYSIWYG! 2019-12-04 11:26:23 -05:00
Isaiah Odhner f24e0d2aa2 Allow Esc to cancel or finalize textbox
In mspaint it only cancels, but here it finalizes if there's any text, and otherwise cancels.
2019-12-03 15:02:27 -05:00
Isaiah Odhner 847d6fec68 Cancel polygon if first two points end up very close
- Cancel the polygon if you end up within the auto-finalization distance on the first gesture
- Regarding "Don't start making the polygon until you click and drag more than the auto-finalization distance" - I don't see evidence for this. I think this was just a misconception based on the canceling.
2019-12-03 14:48:44 -05:00
Isaiah Odhner 2d9a50161e Preview filled polygon invertily and finish with stealth stroke 2019-12-03 14:38:37 -05:00
Isaiah Odhner 77b3e35099 Use a preview canvas for Polygon
(in order to implement an inverty preview for the fill-only mode...)
2019-12-03 14:38:37 -05:00
Isaiah Odhner bc7c233e3a When switching tools, cancel curve, but complete polygon 2019-12-03 13:22:12 -05:00
Isaiah Odhner 0fe2ab2c0a Allow cancel of Polygon and Curve with Esc while pointer up 2019-12-03 13:02:20 -05:00
Isaiah Odhner 90493cf687 Make Curve tool passive until finalized 2019-12-03 12:54:46 -05:00
Isaiah Odhner bd432432de Make Polygon passive until it's finalized 2019-12-03 10:57:15 -05:00
Isaiah Odhner c9d26195c7 Don't log undefined 2019-12-02 23:39:11 -05:00
Isaiah Odhner 1b864e001e Stop Konami code Easter egg with Esc 2019-12-02 23:39:11 -05:00
Isaiah Odhner 5e4d5b1a75 Update object positions on zoom from menus or theme change 2019-12-02 23:39:11 -05:00
Isaiah Odhner 771223e15f Use specific zoom-in/zoom-out fallback cursor 2019-12-02 22:20:23 -05:00
Isaiah Odhner 339949b70a Fix increasing pencil size with numpad 2019-12-02 22:02:40 -05:00
Isaiah Odhner aeac89dd77 Invalidate the cache so failed images load later 2019-12-02 21:52:49 -05:00
Isaiah Odhner f3ba32b1c3 Add safety for failed-to-load images
e.g. dev server killed, or loading the app on a flaky connection
2019-12-02 21:49:59 -05:00
Isaiah Odhner d39c070dc1 Clean up 2019-12-02 21:36:19 -05:00
Isaiah Odhner 385f278265 Free-Form Select + Select = XOR of regions 2019-12-02 21:28:56 -05:00
Isaiah Odhner 36d3852c34 WIP: Free-Form Select + Select = XOR 2019-12-02 20:54:39 -05:00
Isaiah Odhner 4fc114ed57 Configure VS Code 2019-12-02 19:57:31 -05:00
Isaiah Odhner d4241083b3 For multitools, filter and sort select-box tool previews
- Select plus Text tool previews would cancel each other out since they're identical and inverty. Filter to only show one of them, and thus, actually show one, effectively.
- Select plus Free-Form Select would only show the select box. Sort so it shows both previews. TODO: make it actually use both selection forms so that the preview isn't misleading.
2019-12-02 17:56:02 -05:00
Isaiah Odhner d0cd8217be Fix visibility of document canvas handles 2019-12-02 16:47:37 -05:00
Isaiah Odhner 00f522e7ae Fix selecting outside the canvas by a pixel (Select and Text tools) 2019-12-02 14:00:01 -05:00
Isaiah Odhner ea0429e3fa Simplify fix 2019-12-02 12:13:09 -05:00
Isaiah Odhner e53868e931 Fix behavior with both select tools selected
- Two selection objects were created, one to stay behind forever
- The preview-drawing code interfered, leading to a zoom in while making the selection
2019-12-02 12:13:09 -05:00
Isaiah Odhner 6e2ab89359 Fix extra undoable when cropping 2019-12-02 11:54:00 -05:00
Isaiah Odhner 37c0350678 Move instantiate to constructor
Regression: extra undoable for crop
2019-12-02 11:31:00 -05:00
Isaiah Odhner 377ddb6a2e WIP 2019-12-02 11:15:55 -05:00
Isaiah Odhner 03b971b822 // 2019-12-02 10:57:54 -05:00
Isaiah Odhner 935481019f Update readme 2019-11-10 11:38:44 -05:00
Isaiah Odhner 14ee97fb6a Gay es Paint 2019-11-10 10:36:21 -05:00
Isaiah Odhner edfefd2b3d Use smaller viewport for capturing screenshots 2019-11-10 10:36:21 -05:00
Isaiah Odhner cce6396d00 Document hacky \\\\\\\\ 2019-11-05 07:17:17 -05:00
Isaiah Odhner 599395be94 Reorder image-rendering values
It's generally better to have vendor prefixes earlier, and I specifically want pixelation.
2019-11-05 07:17:17 -05:00
Isaiah Odhner 9a143821e5 Set up cypress service
(along with CYPRESS_RECORD_KEY in Travis CI settings)
2019-11-04 23:38:25 -05:00
Isaiah Odhner fb5496d2a4 Add tolerance 2019-11-04 22:39:13 -05:00
Isaiah Odhner d3e38c2556 Prevent test failure cascade (and DRY) 2019-11-04 22:36:09 -05:00
Isaiah Odhner eedf42506c \\\\\\\\
On Linux (Travis CI) this should evaluate as a backslash, at least. (please.)
On Windows this will evaluate as two backslashes, but that should be fine since it's in a regexp character class.
:((((
2019-11-04 22:22:50 -05:00
Isaiah Odhner 2b7864f3b4 Ugh apparently spaces are mandatory
And so I just got "No builds for this repository" on Travis CI, and had to figure it out.
2019-11-04 22:08:11 -05:00
Isaiah Odhner b6d6570228 Set up Travis CI 2019-11-04 21:49:07 -05:00
Isaiah Odhner d52d022e1a Avoid layout shift in Stretch and Skew
Specify the width/height of the icon img elements so they don't change size.
2019-11-04 20:51:39 -05:00
Isaiah Odhner 1685a060af Use cypress for visual testing
- Ditch Casper.js / PhantomCSS
- Set up Cypress and cypress-image-snapshot
- Implement visual tests covering most of the same ground as what I had before (and more), but with some caveats
- Some tests are flaky right now due to resource loading, and some have areas blotched out in order to not depend on resource loading
- TODO: set up continuous integration, add more tests, etc.
2019-11-04 20:51:39 -05:00
Isaiah Odhner 5cb0b20854 Fix overzealous destructuring
Broken in 469f13ccc3
2019-11-03 13:18:00 -05:00
Isaiah Odhner 4fad173c2f Swap out HTTP server and parallel runner for tests
- Swap `http-server` for `serve` to fix an issue https://github.com/http-party/http-server/issues/525 (could downgrade instead alternatively)
- Swap `parallelshell` for `npm-run-all` to fix an issue https://github.com/darkguy2008/parallelshell/issues/69 (could downgrade instead alternatively)
- Switch from firefox (slimerjs) to the default (phantomjs) because my version of firefox is too new now
- This gets tests running, sorta, but not working.
2019-11-03 13:18:00 -05:00
Isaiah Odhner 593cddac09 Clean up
No more "var" declarations
2019-11-03 10:39:48 -05:00