New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Virtual ListCtrl does not reliably render more than about 364k rows #2522
Comments
I tested your code using Python 3.10.12 + wxPython 4.2.1 gtk3 (phoenix) wxWidgets 3.2.2.1 on Linux Mint 21.3 and it worked fine, even when I increased the item count to 1000*1000. The main differences between our setups is that I am using Python 3.10 and you are using 3.11, plus I installed wxPython 4.2.1 using pip, whereas you are using the version from your distribution. |
Probably not a python issue. Same in C++:
Although my system appears to have a broken wx-config:
So the way I build is:
|
What version of GTK3 do you have?
|
|
Tried downgrading Have tried gnome, cinnamon desktop envs with xorg and not. Have noticed that just at the position where rows begin disappearing, if I shrink the window vertically it causes the rows to reappear. But this does not work further down. If I resize the window back up, they disappear again. |
Tested that my overlay scrollbar setting is not causing this. I took ubuntu VM images from linuxvmimages.com (not affiliated nor recommended), then saved wxtest.cpp to the Desktop and ran:
On 23.10 (libgtk-3-0 3.24.38-5ubuntu1, libwxgtk3.2-dev 3.2.2+dfsg-4), issue is present On 23.04 (libgtk-3-0 3.24.37-1ubuntu1, libwxgtk3.2-dev 3.2.2+dfsg-2build1), issue is absent |
Downgrading every package in the dependency tree, the culprit appears to be libcairo2 libcairo2_1.18.0-1_amd64.deb: issue is present |
cairo 1.17.4 good |
cairo 5dafd741 good |
I don't know much about guis, but it looks like cairo change 451dcd31 clamps double values to fixed point values, but the 32-bit fixed point type uses 8 bits for the fractional part, leaving 24 bits for pixels. Dividing the pixels by the number of rows in my list yields 2^24/364000=46.09 pixels per row. And I have 46/2=23 pixels per row on my screen, I guess half the range being used for negative numbers. Observation seems to confirm the bisection, my list is being clamped by this change. |
Really nice work @CypherGrue in troubleshooting the issue. Unfortunately, I don't think we can do much to help in wxPython, but I'd suggest bringing your issue upstream to the cairo devs. |
Thanks. Raised https://gitlab.freedesktop.org/cairo/cairo/-/issues/824 |
This boomerang back down. Cairo dev suggests that the issue is that the library is not being used correctly. Maybe the wx virtual window is too big or something, or an issue in gtk? I am going to drop this here, as no more time. Good luck. |
Operating system: Ubuntu 23.10
wxPython version & source: 4.2.1 (distro python3-wxgtk4.0 4.2.1+dfsg-1)
Python version & source: 3.11.6 (distro python3 3.11.4-5)
Description of the problem:
Virtual ListCtrl does not reliably render more than about 364k rows
The text was updated successfully, but these errors were encountered: