Hi everyone!
I’m using two monitors and I’m trying to get their geometry and usable client area, but I’m getting somewhat unexpected results using wx.Display.
I have two 1600x1200 identical monitors and the main one - on the left - has a 25 pixels-high taskbar, while the other one has no taskbar at all.
Here’s my code:
for i in range(wx.Display.GetCount()):
print i, wx.Display(i).GetGeometry(), wx.Display(i).GetClientArea()
and what I get:
0 (1600, 0, 1600, 1200) (0, 0, 3200, 1175)
1 (0, 0, 1600, 1200) (0, 0, 1600, 1200)
Since wx.Display.GetFromPoint((0,0)) returns 1, I’d say that wxPython sees 1 as the left display and this matches the (0, 0) position printed above, but then I don’t understand why it shows 1200 as client area height, ignoring the taskbar.
Moreover, if 0 is the right monitor the client area is reported as 1200-25 (taskbar height) even though on that display I don’t have a taskbar.
What I’d expect is something like this:
0 (1600, 0, 1600, 1200) (0, 0, 1600, 1200)
1 (0, 0, 1600, 1200) (0, 0, 1600, 1175)
Am I missing something?
This is on Xubuntu 12.04, wxPython 2.8.12.1 (gtk2-unicode), NVIDIA GPU GeForce 210 (GT218) using the Nvidia proprietary driver
Many thanks in advance!