(all this is for SmartClient only) In case the system uses virtual coordinates, the following code will print to console the virtual values for screen bounds - and it should also work with moving/auto restoring saved bounds for windows on other screens in Servoy. (some configuration bounds will not start at 0, 0 in this case - when using multiple screens)
- Code: Select all
var ge = java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment();
var gs = ge.getScreenDevices();
var j;
for (j = 0; j < gs.length; j++) {
var gd = gs[j];
application.output("Default configuration with bounds: " + gd.getDefaultConfiguration().getBounds() + " found for screen '" + gd.getIDstring() + "'.");
// OR, if you want to see all capabilities of a screen
//var gc = gd.getConfigurations();
//var i;
//for (i=0; i < gc.length; i++) {
// application.output("Configuration with bounds: " + gc[i].getBounds() + " found for device '" + gd.getIDstring() + "'.");
//}
}
I guess a plugin would be useful in this area.