22 Commits

Author SHA1 Message Date
Scott Talbert
2871c46d33 Fix a bunch of DeprecationWarnings due to invalid escape sequences
Fixes #1454.
2022-01-11 11:23:06 -05:00
Scott Talbert
173d079681 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
2021-12-01 14:19:00 -05:00
Robin Dunn
732ff6752b Revert "Spelling fixes in wx.lib"
This reverts commit c00b8950da.
The spelling changes were a bit too aggressive.
2020-08-31 13:01:31 -07:00
Robin Dunn
c00b8950da Spelling fixes in wx.lib 2020-07-14 12:53:31 -07:00
Per A. Brodtkorb
fc1823315b Fixes issue # 1554:
Replaced "== None" and "!= None" with "is None" and "is not None", respectively, because the former is slower and error-prone.
2020-03-23 11:53:36 +01:00
Robin Dunn
705aa63d75 Merge branch 'more-windowidref' into wxPy-4.0.x
(cherry picked from commit ada7b2fc51)
2018-06-25 19:12:00 -07:00
Robin Dunn
b1b0c9e297 wx.NewId() --> wx.ID_ANY or wx.Window.NewControlId() as appropriate 2018-06-19 10:31:56 -07:00
Robin Dunn
99cc9ccadf Since both cases need wx.BU_EXACTFIT, simplify it 2017-06-08 00:37:54 -07:00
Robin Dunn
51c6cea7b9 Use a generic button on OSX 2017-06-07 20:35:24 -07:00
Metallicow
a8452dd575 Trim Whitespace lib directory 2016-10-12 22:21:38 -05:00
Robin Dunn
cc3190e240 Lots more docstring refs fixed 2016-07-06 20:20:10 -07:00
Robin Dunn
488f29b05a Fix docstring references to wx.Bitmap 2016-07-06 18:45:16 -07:00
wernerfb
d89745e761 fix doc links in wx.lib 2015-04-13 18:42:45 +02:00
Andrea Gavana
977ab38959 Phoenix docs: fix imagebrowser.py docstrings to avoid Sphinx warnings
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@75854 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-02-09 13:18:29 +00:00
Robin Dunn
de004a78b5 Use GetBitmap and range instead of getBitmap and xrange
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@75828 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-02-07 03:04:47 +00:00
Robin Dunn
2fb6f00867 PR 42 from Metallicow. Py3 and Phoenix updates
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@75603 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2014-01-11 23:13:15 +00:00
Robin Dunn
9f24505715 Merge of PR 11 with the whitespace-only changes omitted.
See https://github.com/RobinD42/Phoenix/pull/11

Mostly phoenix-port changes.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@74463 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-07-10 01:15:34 +00:00
Robin Dunn
980dc4d905 throbber and imagebrowser small Phoenix Fixes
imagebrowser wont complain when clicking on checkered background now.
throbber small PyPanel to Panel fix

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@74208 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-06-13 07:14:32 +00:00
Robin Dunn
676b45c860 Phoenix patch from Werner for imagebrowser.
- corrected all deprecation warnings
- wrapped all user visible strings with wx.GetTranslation macro
- reformatted existing doc to Sphinx format
- added a little bit of doc
- added a unittest

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@73800 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2013-04-10 00:06:00 +00:00
Robin Dunn
247673201b Copy (branch) wx.lib, wx.py and wx.tools from Classic, and include subpackages branched from 3rdParty
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@72061 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-07-13 01:36:07 +00:00
Robin Dunn
a30dfe91e2 I wasn't ready to add this yet.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@71834 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-22 21:29:15 +00:00
Robin Dunn
c8c2e1d97b set svn:eol-style to native
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@71832 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2012-06-22 21:02:42 +00:00