Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

capture-window

0.1.3 • Public • Published

capture-window

Capture a desktop window to a png file. Simple and easy.

Installation

npm install --save capture-window

Usage

var captureWindow = require('capture-window');
 
captureWindow('Finder', 'Downloads', function (err, filePath) {
  if (err) { throw err; }
 
  // filePath is the path to a png file
});

API

captureWindow(bundle, title[, filePath], cb)

Captures the window with the title title of type bundle. bundle is usually the name of the application, e.g. Finder, Safari, Terminal.

The callback receives (err, filePath).

OS Support

Only Mac OS X at the time being. The source is well prepared for other systems, pull requests welcome.

License

MIT

Keywords

none

install

npm i capture-window

Downloadsweekly downloads

8

version

0.1.3

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability