public static VNC_Screen GetScreenByDeviceName(string name) { if (name == "") { return(VNC_Screen.EnumerateScreens().Find(x => x.DeviceName == "\\\\.\\DISPLAY1")); } else { return(VNC_Screen.EnumerateScreens().Find(x => x.DeviceName == name)); } }
public static int[] CollapsedPositionForDisplay(string screenname) { int startx = 0; int starty = 0; VNC_Screen screen = VNC_Screen.GetScreenByDeviceName(screenname); startx = screen.x + 25; starty = screen.height - 84 - 25; return(new int[] { startx, starty }); }
public static VNC_Screen GetPrimaryScreen() { return(VNC_Screen.EnumerateScreens().Find(x => x.Primary == true)); }