Files
Scott Talbert 8c43b40baf Fix a bunch of Python 3.10 issues with pure-Python classes and demos
In Python 3.10, a change[1] was implemented where extension functions
that take integer arguments will no longer silently accept non-integer
arguments (e.g., floats) that can only be converted to integers with a
loss of precision.  This PR fixes most of these issues in the pure-Python
classes and demos by explicitly converting the parameters to int before
passing them to wxWidgets.  There is loss of precision, but this was
happening before (automatically) anyway as most wxWidgets DeviceContext
functions operate using integers.

Additionally, the PR fixes a few sizing issues, mostly with SpinCtrls being
too small on GTK3.

This is an example of the relevant exception:
Traceback (most recent call last):
  File "/usr/lib64/python3.10/site-packages/wx/lib/agw/pygauge.py", line 355, in OnPaint
    r.width = w
TypeError: 'float' object cannot be interpreted as an integer

Fixes #2038.

[1] https://bugs.python.org/issue37999

(cherry picked from commit 173d079681)
2022-02-15 20:16:53 -05:00
..
2016-10-04 12:40:59 -05:00
2018-06-06 10:59:51 -07:00
2018-06-06 10:59:51 -07:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-07-18 21:31:26 -07:00
2014-01-23 00:44:14 +00:00
2016-07-20 17:11:31 -07:00
2016-07-20 17:11:31 -07:00
2016-07-25 21:25:09 -07:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-07-30 23:45:22 -07:00
2014-01-23 00:44:14 +00:00
2016-07-30 23:45:22 -07:00
2016-11-24 19:26:05 -06:00
2016-10-06 23:33:33 -07:00
2014-01-23 00:44:14 +00:00
2013-06-11 18:24:09 +00:00
2016-11-24 19:26:05 -06:00
2018-06-06 10:59:51 -07:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-05-22 12:54:43 +01:00
2014-01-23 00:44:14 +00:00
2016-08-02 21:55:15 -07:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-08-02 21:55:15 -07:00
2014-01-23 00:44:14 +00:00
2016-08-02 21:55:15 -07:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2017-04-16 21:14:22 +10:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-10-06 22:41:09 -07:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2018-06-25 14:17:37 -07:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-08-03 14:09:40 -07:00
2018-10-29 14:17:39 -07:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2018-06-25 14:17:37 -07:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2017-07-21 13:20:54 -07:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2013-06-11 18:24:09 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-02-29 22:41:00 -08:00
2013-07-05 22:24:56 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-11-24 19:26:05 -06:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2014-01-23 00:44:14 +00:00
2016-08-03 14:09:40 -07:00
2016-11-24 19:26:05 -06:00
2014-01-23 00:44:14 +00:00
2016-08-10 19:46:58 -07:00

To run the main demo in this directory, execute demo.py.  In other
words, one of the following commands should do it:

       demo.py
       python demo.py
       pythonw demo.py