Mac OS 9 Lives

Mac OS 9 Discussion => Development & Programming => Topic started by: OS923 on October 02, 2020, 09:05:21 AM

Title: Horizontal scroll in ListBox doesn't update
Post by: OS923 on October 02, 2020, 09:05:21 AM
I have a ListBox in REALbasic with a custom background and custom text. If I scroll horizontally by clicking in the arrows, then it draws correctly, but if I scroll to the right by clicking in the gray area, then it updates only the last row and only if you see it only partially. I checked it: there's no CellBackgroundPaint or CellTextPaint event for those rows.
Title: Re: Horizontal scroll in ListBox doesn't update
Post by: OS923 on October 06, 2020, 11:15:24 AM
If you make a scrollbar instead of setting ScrollBarHorizontal to true then you can use the ValueChanged event to do your own update. I did this by setting cellType to normal for every row. This causes a refresh.