@digitalattitude/getclickedcolor

GetClickedColor ===============

Stats

StarsIssuesVersionUpdatedCreatedSize
@digitalattitude/getclickedcolor
1.8.23 years ago4 years agoMinified + gzip package size for @digitalattitude/getclickedcolor in KB

Readme

GetClickedColor

ListenForClick

Calls the provided callback every time that the user clicks anywhere on the screen. The callback is called with the clicked color (RGB).

GetPixelColor

Gets the color of a pixel at a given position.

Testing

$ node-gyp rebuild $ node example.js

Tested with node 9 on Windows 10, 64 bit.

Usage

$ npm install @digitalattitude/getclickedcolor $ npm rebuild

const getClickedColor = require("@digitalattitude/getclickedcolor").eventProvider;
getClickedColor.on('click', ({ color, position }) => { /* ... */ })

Tested with node 9 on Windows 10, 64 bit.

Credits

Inspired by https://nodejs.org/api/addons.html#addons_callbacks Clicks to some windows, most notably the Task Manager, cannot be tracked (probably applies to all topmost windows).

License

MIT

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.