Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat (Whiteboards): Pen mode (palm rejection) #10222

Merged
merged 4 commits into from
Sep 28, 2023
Merged

Feat (Whiteboards): Pen mode (palm rejection) #10222

merged 4 commits into from
Sep 28, 2023

Conversation

sprocketc
Copy link
Collaborator

@sprocketc sprocketc commented Sep 15, 2023

A simplified approach to pen mode. When this mode is enabled, non 'pen' type pointer events will be rejected.
Although this feature needs to be explicitly enabled, it would be nice if we could test this on multiple different devices before release. It seems to work fine on my wacom tablet on linux. I also made some minor style adjustments to our bottom toolbars for mobile.

Resolves #9863

Also see
https://discuss.logseq.com/t/whiteboards-could-really-do-with-palm-rejection-for-use-on-tablets/16769
https://discuss.logseq.com/t/whiteboard-ipad-apple-pencil-support/17526

Screenshot from 2023-09-15 10-59-59

@github-actions github-actions bot added the :type/feature New feature label Sep 15, 2023
@sprocketc sprocketc changed the title [WIP] Feat (Whiteboards): Pen mode (aka palm rejection) [WIP] Feat (Whiteboards): Pen mode (palm rejection) Sep 15, 2023
@sprocketc sprocketc changed the title [WIP] Feat (Whiteboards): Pen mode (palm rejection) [WIP] Feat (Whiteboards): Pen mode for palm rejection Sep 15, 2023
@sprocketc sprocketc changed the title [WIP] Feat (Whiteboards): Pen mode for palm rejection [WIP] Feat (Whiteboards): Pen mode (palm rejection) Sep 15, 2023
@sprocketc sprocketc changed the title [WIP] Feat (Whiteboards): Pen mode (palm rejection) Feat (Whiteboards): Pen mode (palm rejection) Sep 18, 2023
@sprocketc sprocketc marked this pull request as ready for review September 18, 2023 14:18
Copy link
Collaborator

@andelf andelf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On Galaxy Tab S7+ with S Pen:

when "Pen mode" is on, even the tip of the pen is not touching the screen, a line will be drawn. It also connects directly to the tail of the last line.

S Pen has a special mode, when the tip is close to the screen (about 2cm), a transparent cursor will be shown on the screen.

@sprocketc
Copy link
Collaborator Author

@andelf Sorry for the late reply.

S Pen has a special mode, when the tip is close to the screen (about 2cm), a transparent cursor will be shown on the screen.

I don't have a samsung device to test this, but I tried to fix this blindly using this piece of information. I assume that this is a secondary pointer, so checking for isPrimary might fix this. Let me know if that improved the situation.

Copy link
Collaborator

@andelf andelf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested on Galaxy Tab S7+. LGTM

@andelf andelf merged commit bdba1ff into master Sep 28, 2023
6 checks passed
@andelf andelf deleted the feature/pen-mode branch September 28, 2023 07:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:type/feature New feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Palm rejection support on touch devices
2 participants