Page 1 of 1

Host Screen numbers are reversed in full screen mode

Posted: 21. Feb 2015, 10:41
by m6477
I have two identical monitors. When I run a VM (with a single virtual monitor) in full screen mode, I can use Mini Toolbar, View->Virtual Screen 1 to move the VM from one monitor to the other. However the monitor number is wrong - when I select Host Screen 1 (the left monitor), it puts the VM on monitor 2 (on the right), and vice-versa. I've checked the host machine display properties (including "Identify") and verified that host monitor 1 is on the left and 2 is on the right.

It used to work correctly, however I recently swapped the two physical monitors, ie left to right and right to left, and so far as I can tell that's when the problem with virtual box started.

At the time I swapped the monitors, I was doing some fault finding, so the host PC was switched on/off a few times with various combinations of one or both monitors disconnected, primary monitor being one or the other, swapping cables between monitors etc. (Virtual Box was not run at any time during this.) The problem turned out to be a physical/optical defect in one monitor - which was originally my primary monitor (number 1, on the left), so that monitor is now my secondary (number 2, on the right). (Swapping them back is not an option.) After I finished, I went to Windows Control Panel and ensured that monitor 1 (eg as shown by the "Identify" button) is on the left and is my main display, and the monitor 2 on the right is the secondary - it had changed during the process of testing. The port on the video card that's used for the left monitor hasn't changed - only the monitors have swapped places.

The host machine appears to correctly identify the monitors, but now Virtual Box puts the full-screen VM on the opposite monitor to what the mini toolbar menu item says.

The problem is not user-specific. I can replicate it with a different user on the same host PC.

Uninstalling/reinstalling VirtualBox does not fix the problem.

I've tried assorted combinations of disconnecting one or other of the monitors, restarting the machine etc, to see if that will fix it, but it doesn't make any difference.

I even reverted to a (Windows Backup and Restore) system image taken before the monitors were swapped, and that didn't fix the problem either.

It's as if VirtualBox's "host screen 1" is tied to the original physical monitor 1, rather than the logical monitor 1 (ie as Windows identifies it after swapping them).

Technical details:
  • Host is Windows 7 Ultimate, SP1, 64-bit. (The problem appears to be independent of the guest OS - I can replicate it with Windows and Ubuntu guests, and no guest OS at all, just the VM BIOS on a newly created VM with no software installed.)

    The monitors are both Dell 2209WA.

    Video card is AMD Radeon HD 6670.
Any suggestions as to how I might fix the screen numbering?

(I reported this as https://www.virtualbox.org/ticket/13749 - minor defect - a while ago, but in the absence of any response there, I'm trying here in case someone knows how to fix it.)

Re: Host Screen numbers are reversed in full screen mode

Posted: 21. Nov 2015, 11:06
by m6477
The problem still exists in VirtualBox 5.0.10
Any hints as to how I might fix the problem (a tweak to my registry setting?) would be appreciated.

Re: Host Screen numbers are reversed in full screen mode

Posted: 21. Nov 2015, 15:28
by Perryg
VirtualBox uses the port to distinguish the order. So just moving the monitors around does not actually change the order as far as the OS and VirtualBox is concerned. While you can on some OSes change the screen number around ( selecting one or the other as the primary monitor ), AFAIK VirtualBox does not have a way to do this.

Re: Host Screen numbers are reversed in full screen mode

Posted: 23. Nov 2015, 14:54
by m6477
you can on some OSes change the screen number around ( selecting one or the other as the primary monitor )
Windows (my host OS) does allow me to do this, and it correctly identifies screen 1 (primary) on the left, 2 on the right. However when I select "host screen 1" in VirtualBox (with the VM in full-screen mode), VirtualBox puts it on the right (which the host Windows identifies as 2).
VirtualBox uses the port to distinguish the order.
Can you be more specific. Is there, for example, a specific registry value that it might be looking at? I'm quite happy to tweak the host machine registry settings if necessary.

Re: Host Screen numbers are reversed in full screen mode

Posted: 23. Nov 2015, 15:06
by Perryg
AFAIK the ports are read at the hardware level and not the registry. Meaning you would need to alter the source in some way to fool the port numbers in a particular case. Of course you could ask the DEVs this and be sure.