php-x11/examples/select_and_grow.php

16 lines
365 B
PHP
Raw Normal View History

2016-12-26 19:54:28 +00:00
<?php
require_once __DIR__."/../vendor/autoload.php";
use NoccyLabs\X11\WindowSelector;
$selector = new WindowSelector();
2016-12-26 20:06:30 +00:00
// Select window
2016-12-26 19:54:28 +00:00
printf("Click a window to select it...\n");
$window = $selector->select();
$window->dump();
2016-12-26 20:06:30 +00:00
// Grow the window by 10 pixels
$size = $window->getWindowSize();
$window->setWindowSize($size->width + 10, $size->height + 10);