I need to do two full screen (borderless) windows in a dual-monitor configuration (actually two video projectors). I’m having a surprisingly hard time getting this to work nicely, and am currently resorting to a pretty ugly hack so I’m wondering if there’s a better way.
First, let me mention I’m using NVIDIA TwinView. I tried several approaches:
-
using PRC config variables. That gives me one nice full screen window, but it’s limited to 1 screen. (actually the correct behavior, but there’s no way to tell it to be super-full-screen across both monitors. Unless you configure xorg.conf for Xinerama I guess).
-
open a new window, try to make it undecorated and positioned on the second monitor:
winprops = WindowProperties.getDefault()
winprops.setOrigin(1920,0)
winprops.setSize(1920,1200)
winprops.setUndecorated(True)
fbprops = FrameBufferProperties.getDefault()
self.newWin = base.graphicsEngine.makeOutput(base.pipe,"mywin",0,fbprops,winprops,GraphicsPipe.BFRequireWindow)
And then something similar to change the properties on the primary window
wp = WindowProperties.getDefault()
wp.setSize(1920,1200)
wp.setOrigin(0,0)
wp.setUndecorated(True)
base.win.requestProperties(wp)
Here’s where it gets frustrating.
In KDE4:
neither of these work. setUndecorated(True) on the main window works, but it won’t achieve full screen size. if you undecorate the new window, it disregards the position and size parameters and just plops it in the middle of the first screen. setFullscreen(True) on the main window will enlarge it, but will not undecorate, and gets blocked by the KDE panel.
I can get close by hiding the panels, but the positioning is still never quite right so there’s a sliver of desktop always showing through.
I also thought to make one very large undecorated window to span both screens. However, the width is always truncated about halfway into the second screen (e.g. if I have 2 monitors at 1024x768 and I request the window at 2048x768, it only ends up being about 1500x768).
In Gnome:
Undecorating the second window and placing it on the right screen works, but I can’t undecorate and fullsize the main window at all. Using the PRC variables doesn’t work either, it still keeps the decoration and/or won’t expand to the full height of the screen.
Here’s the only solution I’ve found:
- use PRC variables to fullscreen the main window
- create the second window and set the position, size, and undecoration
- run in the Openbox Window Manager!
madness! there must be a better way.
On the plus side I’m enjoying how fast and efficient OpenBox is.