Upgrade to wxPython 4.0.3 (Phoenix)#7104
Conversation
…vaccess#7077. One of the biggest benefits of using wxPython 4 is easier route for upgrading to Python 3.x. Due to changes made in wxPython 4, NvDA source code (at least wx routines) must be modified. This provides some foundations, namely wx.adv.TaskbarIcon and replacing wx.SpinCtrlNameStr with a string literal.
…xtCtrl.write. re nvaccess#7077. wx.TextCtrl.write is no more - wx.TextCtrl.WriteText should be used instead.
…rsor tracking. re nvaccess#7077. If wx.TextCtrl.WriteText is used and if the cursor is located at the top of the output window for the console, newly typed text will be inserted instead of being appended, thus wx.TextCtrl.AppendText will be used.
…nter instead. re nvaccess#7077. Somehow, documentation says wx.CENTRE_ON_SCREEN is included but it isn't there at runtime. Instead, wx.Center is used (does not follow variable naming convention though), so using it for now.
…anymore, replaced with wx.FONTFAMILY_DEFAULT. re nvaccess#7077
…r. re nvaccess#7077. In wxPython 4, when instantiating wx.GridSizer, horizontal and vertical gaps in pixels must be specified.
…fore the dialog is destroyed. re nvaccess#7077. Due to changes to how dialog sizes are constructed, keyword arguments cannot be used. Also, if Window.Destroy is called, somehow text controls and what not are gone, so save speech viewer position before destroying the window.
… sure to check if the treeview is alive. re nvaccess#7077. Somehow, when Cancel button is licked, treeview is removed first, yet item selection event is run. Make sure to catch this.
…t issues when installing more than one add-on remotely. re nvaccess#7077. Here 'remotely' refers to letting people install add-ons via Windows Explorer and other means. Without nullifying instance flag when the add-ons manager closes, instance flag will be kept, which causes wxPython to think (and correctly) that the dialog is still active, resulting in runtime error on add-on list control being thrown.
…cess#7077. Just like add-ons manager, if the instance flag for config profiles dialog isn't nullified, wxWidgets will think that the dialog is active when it is gone. Thus nullify it in two places: when the actual dialog closes and when a new profile is activated right away (for the latter, it is parent.Destroy).
# Conflicts: # source/gui/__init__.py
|
@josephsl: I belief this is still not a stable version. right? |
|
Hi, no stable version is out at the moment. I’m waiting for a stable build before posting the PR. Thanks for the reminder about this.
From: Leonard de Ruijter [mailto:notifications@github.com]
Sent: Thursday, October 12, 2017 12:06 PM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Mention <mention@noreply.github.com>
Subject: Re: [nvaccess/nvda] Upgrade to wxPython 4.0.0 (Phoenix) (#7104)
@josephsl <https://github.com/josephsl> : I belief this is still not a stable version. right?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#7104 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkLWpr0vRDh4NOqtmubeM8G19_NFsks5srmMjgaJpZM4NIQp3> .
|
|
IN that case, wouldn't it be better to close this pr for now and throw up a new one as soon as there is a real release we can work with? |
|
Hi, I’d say it’d best to keep it open, or if we do close it now, reopen once stable build comes out. Thanks.
From: Leonard de Ruijter [mailto:notifications@github.com]
Sent: Thursday, October 12, 2017 11:04 PM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Mention <mention@noreply.github.com>
Subject: Re: [nvaccess/nvda] Upgrade to wxPython 4.0.0 (Phoenix) (#7104)
IN that case, wouldn't it be better to close this pr for now and throw up a new one as soon as there is a real release we can work with?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#7104 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkLmXLf3XFI1kD6ArFlqsxEXQwy_Sks5srv1ggaJpZM4NIQp3> .
|
Due to request from a tester, wxPython 4 developer has decided to restore wx.TextCtrl.write. This means the AppendText workaround in place is no longer needed.
…WXK_pAGEUP and wx.WXK_PAGEDOWN, respectively. re nvaccess#7077. wx.WXK_PRIOR and wx.WXK_NEXT are no more, replaced by direct definition of page up and page down keys. This fixes the problem where sliders couldn't be changed in Voice Settings dialog.
|
Mentioning this here since I have seen a lot of changes explicitly changing to use |
|
@josephsl: does the issue with ID_ANY / newID etc affect anything in NVDA core? or just add-ons? If this does not affect NVDA core, I would like to merge this pr. |
|
Hi, this bug will manifest itself after running NVDA (Core) for a while and opening many dialogs due to wrap-around problem. This is fixed in wxPython 4.0.3, but apart from this bug, it is ready to go. I’ll do a follow-up study with 4.0.3 in the fall if NV Access is willing to update to wxPython 4.0.3 after NVDA 2018.3 hits the air. Thanks.
From: Michael Curran <notifications@github.com>
Sent: Tuesday, July 17, 2018 12:56 AM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Mention <mention@noreply.github.com>
Subject: Re: [nvaccess/nvda] Upgrade to wxPython 4.0.1 (Phoenix) (#7104)
@josephsl <https://github.com/josephsl> : does the issue with ID_ANY / newID etc affect anything in NVDA core? or just add-ons? If this does not affect NVDA core, I would like to merge this pr.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#7104 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkDQNo9mKtmR3cLDMDQ4KSNs7t4s6ks5uHZingaJpZM4NIQp3> .
|
|
So the problem is caused by wx.NewID(). Though not by ID_ANY?
Does wxPython 4.0.3 fix the problem with no code changes, or does it
just introduce a new method for possible usage?
I'm unwilling to merge this if it knowingly causes a regression such as
this.
If I understand correctly, to address this we must either replace
wx.NewID calls with ID_ANY, or as @feerrenrut suggests: use named
arguments and remove the need to specify IDs at all (at least where they
are not needed by events).
Please suggest a possible way to address this regression. This could
include upgrading to wxPython 4.0.3 which I am happy to accept if it
removes the regression.
|
|
Hi, I think the best course of action would be using 4.0.3 and take advantage of wx.NewIdRef function. CC @tspivey who reported this problem.
From: Michael Curran <notifications@github.com>
Sent: Tuesday, July 17, 2018 1:08 AM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Mention <mention@noreply.github.com>
Subject: Re: [nvaccess/nvda] Upgrade to wxPython 4.0.1 (Phoenix) (#7104)
So the problem is caused by wx.NewID(). Though not by ID_ANY?
Does wxPython 4.0.3 fix the problem with no code changes, or does it
just introduce a new method for possible usage?
I'm unwilling to merge this if it knowingly causes a regression such as
this.
If I understand correctly, to address this we must either replace
wx.NewID calls with ID_ANY, or as @feerrenrut suggests: use named
arguments and remove the need to specify IDs at all (at least where they
are not needed by events).
Please suggest a possible way to address this regression. This could
include upgrading to wxPython 4.0.3 which I am happy to accept if it
removes the regression.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#7104 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkG5y9UulkYrDljhMc6OX7Cf_cAaPks5uHZthgaJpZM4NIQp3> .
|
…ion for this checkbox just like others. re nvaccess#7077. Somehow, for touch interaction/touch typing mode checkbox, wx.NewId function was called, whereas other checkboxes do not do this. Thus make it consistent with other fellows by not calling this function in this particular checkbox.
… panels. Re nvaccess#7077. Reported by several people and subsequently confirmed: in wxPython 4.0.0 to 4.0.2, there exists a wrap-around bug in wx.NewId function that prevents programs calling this function from working normally after the ID's are exhausted. This is now fixed in wxPython 4.0.3 via wx.NewIdRef function. Thus use this function to keep an eye on panel ID's, used for announcing new categories as they become visible in multi-category NVDA Settings screen.
|
Hi, Hopefully this should close another chapter in our saga in wxPython 4 migration. Testing shows the wrap-around bug is gone, but a broad validation might be needed once this Phoenix takes flight aboard master branch. Thanks. |
|
Hi, By the way, for @feerrenrut: unit tests and Robot framework tests passes with wxPython 4 - no changes whatsoever on my computer. Thanks. |
|
Happy for me to merge this now @josephsl? |
|
Hi, thank you. Let the phoenix take flight around NVDA community (Project Heliopolis is “done” – moving onto follow-up phase). Thank you everyone.
From: Michael Curran <notifications@github.com>
Sent: Tuesday, July 17, 2018 10:16 PM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: Joseph Lee <joseph.lee22590@gmail.com>; Mention <mention@noreply.github.com>
Subject: Re: [nvaccess/nvda] Upgrade to wxPython 4.0.3 (Phoenix) (#7104)
Happy for me to merge this now @josephsl <https://github.com/josephsl> ?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#7104 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AHgLkBnQQ11gEJrQKrWdAyyFwOhUY6CIks5uHsSogaJpZM4NIQp3> .
|
Closes #7077
Closes #7429
Hi,
From 2012 to 2017, Robin Dunn and others have been working on a complete revamp of wxPython. One of the benefits of the resulting 4.0.0 release is ability to use wx modules via Python versions 2.7 and 3.5+. This will require a longer incubation period, as add-ons will need to be modified, an extensive hunt for issues must be carried out and so on.
at the moment the only major issue is wx.Yield, seen when one repeatedly taps arrow keys or certain keys quickly. For example, from Python Console, press backspace, and you may hear the error tone with a traceback that culminates in wxPython saying wx.Yield was called recursively. As for add-ons, wx.PyDeadObjectError must be changed to RuntimeError, certain wx.Center function arguments/constants have changed and so on.
Also, as part of wxPython, we also get the Six module for free, which eases transition to Python 3.x.
Thanks.