wxProgressDialog wonky under Win32
Grant Edwards
grante at visi.com
Mon Mar 11 18:44:28 EST 2002
In article <mailman.1015885644.13105.python-list at python.org>, Cliff Wells wrote:
> On Mon, 11 Mar 2002 19:15:34 GMT
> Grant Edwards wrote:
>>
>> According to one of the wx mailing list archives, this is a
>> known bug in the MSW port of wxWindows (the "size" value of a
>> gauge is treated as a 16-bit number). It's been fixed, but
>> it's still available only from CVS.
>
> The usual trick I use to get around this is to use a gauge with
> a max of 100 and then update it with the percentage done
> (n/max) rather than the number of items done (n). This can
> also help performance as you can avoid updating the gauge as
> often if you have a large number of items to process.
Yup. It's a bit incovenient in my case because function calling
the update callback didn't know how much data was to be
processed. I had to create an extra function that did know the
total size, and pass that to the data-processing function.
It also caused problems because the integer math didn't really
work right and the thing finished when it got to "100" even
though it was really only 99.99.
--
Grant Edwards grante Yow! I was in a HOT
at TUB! I was NORMAL! I was
visi.com ITALIAN!! I enjoyed th'
EARTHQUAKE!
More information about the Python-list
mailing list