Cursor misscaled in HiDPI mode when using mouse integration
|Reported by:||nitrous||Owned by:|
|Keywords:||HiDPI, retina, mouse integration, cursor||Cc:|
|Guest type:||Linux||Host type:||Mac OS X|
I am using an OS X 10.10.4 host on a Macbook Pro retina with an archlinux guest, exposing unscaled hidpi output to the guest. When mouse integration is enabled, the cursor is comically oversized -- multiplied by a factor of 2 from the hidpi bug because of my retina display, and another 1.5x from the guest's dpi, giving a 3x size cursor. This forum post suggests it affects other guests too, though I'm not sure about other hosts.
I think the problem is probably that the mouse integration code which implements the hardware cursor is hidpi-unaware and so writes the cursor pixels naively instead of to the underlying device pixels. As a result, the cursor is obviously pixellated and out-of-place with the rest of the guest. Presumably the solution is to simply test whether unscaled mode is on and to then remap the cursor to device pixels.