We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
on('event', ...)
I ran some code from #69 to debug why my events weren't firing. When I run the below code, NO events show up on my system.
var x11 = require('x11'); x11.createClient(function(err, display) { var X = display.client; var root = display.screen[0].root; X.ChangeWindowAttributes(root, { eventMask: x11.eventMask.PointerMotion|x11.eventMask.KeyPress }); X.on('event', function(ev) { console.log(ev); }); });
I also tried the below code to see all possible events I could get
var x11 = require('../../lib'); x11.createClient(function(err, display) { var X = display.client; var root = display.screen[0].root; const mask = Object.entries(x11.eventMask) .filter(([k,v])=>k !== "SubstructureRedirect") .map(([k,v])=>v) .reduce((acc,i)=>acc|i,0x0); X.ChangeWindowAttributes(root, { eventMask: mask }); const uniq = []; X.on('event', function(ev) { const name = ev.name || ev.type; if (!uniq.includes(name)) { console.log(name); uniq.push(name); } }); });
and I was able to see
ConfigureNotify PropertyNotify 32 ClientMessage MapNotify UnmapNotify CreateNotify DestroyNotify 21
Lastly, I tried the Tetris game and I can get key presses and pointer motion when it's on a window I create, but I can't target a different window?
Any ideas why PointerMotion and KeyPress won't show up on my system?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I ran some code from #69 to debug why my events weren't firing. When I run the below code, NO events show up on my system.
I also tried the below code to see all possible events I could get
and I was able to see
Lastly, I tried the Tetris game and I can get key presses and pointer motion when it's on a window I create, but I can't target a different window?
Any ideas why PointerMotion and KeyPress won't show up on my system?
The text was updated successfully, but these errors were encountered: