mirror of
https://github.com/danbulant/node-x11
synced 2026-05-22 13:59:11 +00:00
test wrapper, events, stress test - create grid of windows
This commit is contained in:
parent
7edcc0e5a7
commit
53dc53582e
1 changed files with 21 additions and 0 deletions
21
test/testwnd.js
Normal file
21
test/testwnd.js
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
var x11 = require('../lib/x11');
|
||||
var Window = require('./wndwrap');
|
||||
|
||||
var width = 700;
|
||||
var height = 500;
|
||||
|
||||
var xclient = x11.createClient();
|
||||
xclient.on('connect', function(display) {
|
||||
console.log(xclient.display.white_pixel);
|
||||
var mainwnd = new Window(xclient, 0, 0, width, height, xclient.display.white_pixel);
|
||||
/*
|
||||
for (var x = 0; x < width; x += 10) {
|
||||
for (var y = 0; y < width; y += 10) {
|
||||
var ch = new Window(mainwnd, x, y, 10, 10, 0);
|
||||
}
|
||||
}
|
||||
*/
|
||||
//mainwnd.on('mousemove', function(ev) {
|
||||
// console.log(ev.x, ev.y);
|
||||
//});
|
||||
});
|
||||
Loading…
Reference in a new issue