Freehand pen mode skips stroke if it starts within ? ms after previous stroke
See original GitHub issueBefore I start, I would like to mention that I’m really happy with the new pen mode with palm rejection. It’s a major improvement over the previous situation!
I tried hand writing in freehand mode with an Apple Pencil (i.e., “drawing” text, not using the Pencil as an alternative keyboard). I’m seeing this issue both in mobile Safari and in the mobile Obsidian app through the Excalidraw plugin for Obsidian (which I updated to the latest version before testing).
To reproduce, it might be sufficient to try hand-writing a sentence with the freehand draw tool using any hardware stylus.
When hand writing, I (and probably most people) make quick movements with the pen. Sometimes I write subsequent letters in a single stroke (ligatures), while other times, I lift the pen briefly between two letters in order to start the next letter with a new stroke (non-ligatures). When I write a non-ligature within a word, Excalidraw ignores the second stroke. After that it will pick up the next (i.e., third) stroke again. This has the overall effect of skipping every second stroke within a word.
Rather than an even-odd problem, it seems to be a timing issue (i’m guessing debounce
or throttle
, but I will refrain from interpreting the issue). If I intentionally wait a little between two strokes, both strokes will be picked up. The first stroke of a new word is also always picked up, which seems to suggest that the slightly longer break introduced by a space (which is typically when I shift my hand a bit) is just enough to prevent the next stroke from being ignored.
While the new pen mode works very well for me in general, this stroke-skipping issue is currently preventing me from using Excalidraw for the purpose I have in mind.
Issue Analytics
- State:
- Created 2 years ago
- Comments:5 (3 by maintainers)
Top GitHub Comments
Here’s an attempted fix for the Scribble missing strokes issue: https://excalidraw-git-fixscribble-excalidraw.vercel.app/ Lemme know if you can still reproduce!
In theory it should be fixable. I’ll try to take a look at it this weekend if we can do anything about it.
closing in favor of https://github.com/excalidraw/excalidraw/issues/3955