469,352 Members | 2,150 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,352 developers. It's quick & easy.

wxWindow GetPosition() bug???

Hi,
I've found a strange behavior in method GetPosition() of wxWindow class

( and derived ).
On windows, if you create a window object

frame = wx.Frame(None, -1, "TESTING")

and you set the position to:
frame.SetPosition( (300, 45000) )

If you call method GetPosition, the result will be:
frame.GetPosition()
>>(300, 32767)
32767 is the integer limit. Why GetPosition() returns this value??? and

why on Unix Platform this problem was not found??

thx very much!

bye

Aug 22 '06 #1
1 1806
mardif <ma**************@gmail.comwrote:
Hi,
I've found a strange behavior in method GetPosition() of wxWindow class

( and derived ).
On windows, if you create a window object

frame = wx.Frame(None, -1, "TESTING")

and you set the position to:
frame.SetPosition( (300, 45000) )

If you call method GetPosition, the result will be:
frame.GetPosition()
>(300, 32767)

32767 is the integer limit. Why GetPosition() returns this value??? and

why on Unix Platform this problem was not found??

thx very much!
Traditionally, there was a 16(15?) bit limit for coordinates on X Window
systems.

Maybe the wx implementations tries to be smarter than X itself and
restricts the positions artificially. Maybe Windows has sch a limit
itself...

I don't really know, other than 'never try to access coordinates
that are 'much' bigger than what is actually visible'...

Andre'
Aug 22 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by James | last post: by
reply views Thread by MooMaster | last post: by
2 posts views Thread by Lee | last post: by
11 posts views Thread by cyberdave | last post: by
reply views Thread by mardif | last post: by
6 posts views Thread by Eran.Yasso | last post: by
reply views Thread by suresh191 | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.