wxPython Linux custom resizable frame problem

Hey there.
I am having a weird problem with custom resizable frame.
When I try to resize it, resizing is not very smooth.

I’ve checked output from self.GetSize() in my frame’s paint event, and found out that it is like rarely being updated.

Sorry if the explanation is not very good. I still don’t understand what I am doing wrong. On Windows and Mac it works just fine.

Running wxPython 2.8.12.0 with Python 2.7.5 on Fedora 20 64bit.

test-resize.py (1.16 KB)

Hi,

···

On 8/14/2014 9:46, GamerCat wrote:

Hey there.
I am having a weird problem with custom resizable frame.
When I try to resize it, resizing is not very smooth.

I've checked output from self.GetSize() in my frame's paint event, and found out that it is like rarely being updated.

Sorry if the explanation is not very good. I still don't understand what I am doing wrong. On Windows and Mac it works just fine.

Running wxPython 2.8.12.0 with Python 2.7.5 on Fedora 20 64bit.

I see the same on Mint 17 with above, but if I use wxPython Phoenix 3.0 then the resize is smooth.

With 2.8 adding a wx.Yield after SetSize seems to make it a bit better.

Werner

Hey there.
Unfortunately, it didn’t really work for me :frowning:
About wxPython 3 - do I have to build it from source? I don’t see wxPython 3 rpm package, using yum.

···

On Thursday, August 14, 2014 12:05:48 PM UTC+2, werner wrote:

Hi,

On 8/14/2014 9:46, GamerCat wrote:

Hey there.

I am having a weird problem with custom resizable frame.

When I try to resize it, resizing is not very smooth.

I’ve checked output from self.GetSize() in my frame’s paint event, and
found out that it is like rarely being updated.

Sorry if the explanation is not very good. I still don’t understand
what I am doing wrong. On Windows and Mac it works just fine.

Running wxPython 2.8.12.0 with Python 2.7.5 on Fedora 20 64bit.

I see the same on Mint 17 with above, but if I use wxPython Phoenix 3.0
then the resize is smooth.

With 2.8 adding a wx.Yield after SetSize seems to make it a bit better.

Werner

On Windows 7 with wxpython 2.9.4 I can’t even see the Frame anywhere except the Windows task bar. Alt-tabbing or clicking does nothing. I can see it when I give the frame a border though, but when I click anywhere in the frame nothing happens. It also doesn’t look yellow to me.

I figured out that your code seems to work fine when I comment out:

self.Bind(wx.EVT_ERASE_BACKGROUND, lambda x: None)

···

On Thursday, August 14, 2014 11:52:47 AM UTC-7, GamerCat wrote:

Hey there.
Unfortunately, it didn’t really work for me :frowning:
About wxPython 3 - do I have to build it from source? I don’t see wxPython 3 rpm package, using yum.

On Thursday, August 14, 2014 12:05:48 PM UTC+2, werner wrote:

Hi,

On 8/14/2014 9:46, GamerCat wrote:

Hey there.

I am having a weird problem with custom resizable frame.

When I try to resize it, resizing is not very smooth.

I’ve checked output from self.GetSize() in my frame’s paint event, and
found out that it is like rarely being updated.

Sorry if the explanation is not very good. I still don’t understand
what I am doing wrong. On Windows and Mac it works just fine.

Running wxPython 2.8.12.0 with Python 2.7.5 on Fedora 20 64bit.

I see the same on Mint 17 with above, but if I use wxPython Phoenix 3.0
then the resize is smooth.

With 2.8 adding a wx.Yield after SetSize seems to make it a bit better.

Werner

Oh yea, sorry. I forgot to comment out this part.
I was just testing some stuff, hoping it will make it work.

···

On Thursday, August 14, 2014 11:08:30 PM UTC+2, Nathan McCorkle wrote:

On Windows 7 with wxpython 2.9.4 I can’t even see the Frame anywhere except the Windows task bar. Alt-tabbing or clicking does nothing. I can see it when I give the frame a border though, but when I click anywhere in the frame nothing happens. It also doesn’t look yellow to me.

I figured out that your code seems to work fine when I comment out:

self.Bind(wx.EVT_ERASE_BACKGROUND, lambda x: None)

On Thursday, August 14, 2014 11:52:47 AM UTC-7, GamerCat wrote:

Hey there.
Unfortunately, it didn’t really work for me :frowning:
About wxPython 3 - do I have to build it from source? I don’t see wxPython 3 rpm package, using yum.

On Thursday, August 14, 2014 12:05:48 PM UTC+2, werner wrote:

Hi,

On 8/14/2014 9:46, GamerCat wrote:

Hey there.

I am having a weird problem with custom resizable frame.

When I try to resize it, resizing is not very smooth.

I’ve checked output from self.GetSize() in my frame’s paint event, and
found out that it is like rarely being updated.

Sorry if the explanation is not very good. I still don’t understand
what I am doing wrong. On Windows and Mac it works just fine.

Running wxPython 2.8.12.0 with Python 2.7.5 on Fedora 20 64bit.

I see the same on Mint 17 with above, but if I use wxPython Phoenix 3.0
then the resize is smooth.

With 2.8 adding a wx.Yield after SetSize seems to make it a bit better.

Werner