mouse-event% vs get-mouse-state issues
Nobody has claimed this yet.
- Dominant language
- Racket
- Stars
- 68
- Forks
- 82
- PR merge metrics
- No merged PRs in 30d
Description
Following the results gathered from https://racket.discourse.group/t/help-me-gather-keystrokes-and-mouse-events-for-varied-platforms/307/7
On Mac, there are several issues:
-
controlisn't reported in themouse-event%, while it is reported byget-mouse-state. -
get-mouse-state reports
leftbutton instead ofrightormiddle
Example of such discrepancies:- mouse-event%:
right:shift:meta:right-down
get-mouse-state:(914 602 left shift meta control) - mouse-event%:
right:right-down
get-mouse-state:(614 435 left control)
- mouse-event%:
-
Some Mac users reported that modifiers are not picked at all with mouse events
On Windows, things are mostly ok except that meta or alt are not always reported in the mouse-event%. Otherwise, the event also reports meta while the state reports alt.
Example:
- mouse-event%:
control:shift:left-up
get-mouse-state:(1878 456 shift control alt)
On Unix, the only issue I found is that the mouse-event% reports meta while the state reports alt.
Unfortunately I don't own a Mac or a Windows machine (only a Linux) so I can't really attempt to debug this. However, one can easily try it out with this:
raco pkg install racket-paint
racket -l- racket-paint/event-listener --mouse-state
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running racket -l- racket-paint/event-listener --mouse-state after installing racket-paint, then compare mouse-event% reports with get-mouse-state on Mac, Windows, and Unix. Investigate the platform-specific modifier and mouse-button discrepancies described in the issue; done means the two APIs report consistent state across the tested platforms.
Written by the indexing model from the issue text.
Assessment
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100