MSW: Migration from 3.0.4 to 3.1.3 slows down (freezes) layout in wxScrolledWindow

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
rsb
I live to help wx-kind
I live to help wx-kind
Posts: 156
Joined: Fri May 29, 2015 7:26 pm

Re: MSW: Migration from 3.0.4 to 3.1.3 slows down (freezes) layout in wxScrolledWindow

Post by rsb » Wed Jul 08, 2020 6:06 pm

Hi ONEEYEMAN.

I tried something similar to what hneubauer posted on May 18, but it didn't help. It looks like he has
created a new class that inherits from wxScrolledWindow and creates/manages his own scroll bars so
it would be hard to recreate what he has exactly.

Thanks.

hneubauer
Earned a small fee
Earned a small fee
Posts: 11
Joined: Wed May 13, 2020 4:08 pm

Re: MSW: Migration from 3.0.4 to 3.1.3 slows down (freezes) layout in wxScrolledWindow

Post by hneubauer » Mon Jul 13, 2020 11:47 am

You can do this without own scrollbars I think.

At first you have to build you own wxWidgets version with wxWindowMSW::MSWIsPositionDirectlySupported() to always returning true so there should be no freezing.

Than you have to do a Layout before scrolling. Use a class which inherits from wxScrolledWindow.

I'm not sure where the layout should be done so that it works everywhere. We just overwrote DoScroll and called first the layout and then the base method.

But DoScroll is only used if, for example, the child focus changes, but not if the scrolling is triggered from the scrollbar itself. For us that was enough because we have our own scrollbar.

But maybe someone here in the forum can tell you which is the best position in the code for the layout.

Post Reply