Correction - it has got into the wxPython master branch.
I had another attempt at building a clone from the current master branch:
cd /home/richardt/Sources/development/python/wxpython
mkdir local_repo
cd local_repo
git clone https://github.com/wxWidgets/Phoenix
That will create a sub-directory âPhoenixâ containing a clone of the repository
cd Phoenix
git status
This should output the following:
On branch master
Your branch is up-to-date with 'origin/master'
Nothing to commit, working tree clean
Then run:
git submodule init
git submodule update --recursive
cd ext/wxWidgets
git submodule update --init 3rdparty/catch
git submodule update --init 3rdparty/nanosvg
git submodule update --init 3rdparty/pcre
cd ../..
python3 build.py dox etg --nodoc sip build
This will build wxPython, but not install it.
To test it locally:
export PYTHONPATH=/home/richardt/Sources/development/python/wxpython/local_repo/Phoenix:$PYTHONPATH
export LD_LIBRARY_PATH=/home/richardt/Sources/development/python/wxpython/local_repo/Phoenix/wx
richardt@Avalon:.../wxpython/local_repo/Phoenix $ python3
Python 3.12.3 (main, Jul 31 2024, 17:43:48) [GCC 13.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import wx
>>> wx.__file__
'/mnt/SSD_3/Sources/development/python/wxpython/local_repo/Phoenix/wx/__init__.py'
>>> import wx.html2
>>>
>>> dir(wx.html2)
['EVT_WEBVIEW_ERROR', 'EVT_WEBVIEW_FULLSCREEN_CHANGED', 'EVT_WEBVIEW_LOADED', 'EVT_WEBVIEW_NAVIGATED', 'EVT_WEBVIEW_NAVIGATING', 'EVT_WEBVIEW_NEWWINDOW', 'EVT_WEBVIEW_SCRIPT_MESSAGE_RECEIVED', 'EVT_WEBVIEW_SCRIPT_RESULT', 'EVT_WEBVIEW_TITLE_CHANGED', 'USE_WEBVIEW', 'WEBVIEWIE_EMU_DEFAULT', 'WEBVIEWIE_EMU_IE10', 'WEBVIEWIE_EMU_IE10_FORCE', 'WEBVIEWIE_EMU_IE11', 'WEBVIEWIE_EMU_IE11_FORCE', 'WEBVIEWIE_EMU_IE7', 'WEBVIEWIE_EMU_IE8', 'WEBVIEWIE_EMU_IE8_FORCE', 'WEBVIEWIE_EMU_IE9', 'WEBVIEWIE_EMU_IE9_FORCE', 'WEBVIEW_FIND_BACKWARDS', 'WEBVIEW_FIND_DEFAULT', 'WEBVIEW_FIND_ENTIRE_WORD', 'WEBVIEW_FIND_HIGHLIGHT_RESULT', 'WEBVIEW_FIND_MATCH_CASE', 'WEBVIEW_FIND_WRAP', 'WEBVIEW_INJECT_AT_DOCUMENT_END', 'WEBVIEW_INJECT_AT_DOCUMENT_START', 'WEBVIEW_NAV_ACTION_NONE', 'WEBVIEW_NAV_ACTION_OTHER', 'WEBVIEW_NAV_ACTION_USER', 'WEBVIEW_NAV_ERR_AUTH', 'WEBVIEW_NAV_ERR_CERTIFICATE', 'WEBVIEW_NAV_ERR_CONNECTION', 'WEBVIEW_NAV_ERR_NOT_FOUND', 'WEBVIEW_NAV_ERR_OTHER', 'WEBVIEW_NAV_ERR_REQUEST', 'WEBVIEW_NAV_ERR_SECURITY', 'WEBVIEW_NAV_ERR_USER_CANCELLED', 'WEBVIEW_RELOAD_DEFAULT', 'WEBVIEW_RELOAD_NO_CACHE', 'WEBVIEW_ZOOM_LARGE', 'WEBVIEW_ZOOM_LARGEST', 'WEBVIEW_ZOOM_MEDIUM', 'WEBVIEW_ZOOM_SMALL', 'WEBVIEW_ZOOM_TINY', 'WEBVIEW_ZOOM_TYPE_LAYOUT', 'WEBVIEW_ZOOM_TYPE_TEXT', 'WebView', 'WebViewArchiveHandler', 'WebViewBackendDefault', 'WebViewBackendEdge', 'WebViewBackendIE', 'WebViewBackendWebKit', 'WebViewDefaultURLStr', 'WebViewEvent', 'WebViewFSHandler', 'WebViewFactory', 'WebViewFindFlags', 'WebViewHandler', 'WebViewHistoryItem', 'WebViewIE_EmulationLevel', 'WebViewNameStr', 'WebViewNavigationActionFlags', 'WebViewNavigationError', 'WebViewReloadFlags', 'WebViewUserScriptInjectionTime', 'WebViewZoom', 'WebViewZoomType', '__builtins__', '__cached__', '__doc__', '__file__', '__loader__', '__name__', '__package__', '__spec__', 'os', 'wx', 'wxEVT_COMMAND_WEBVIEW_ERROR', 'wxEVT_COMMAND_WEBVIEW_LOADED', 'wxEVT_COMMAND_WEBVIEW_NAVIGATED', 'wxEVT_COMMAND_WEBVIEW_NAVIGATING', 'wxEVT_COMMAND_WEBVIEW_NEWWINDOW', 'wxEVT_COMMAND_WEBVIEW_TITLE_CHANGED', 'wxEVT_WEBVIEW_ERROR', 'wxEVT_WEBVIEW_FULLSCREEN_CHANGED', 'wxEVT_WEBVIEW_LOADED', 'wxEVT_WEBVIEW_NAVIGATED', 'wxEVT_WEBVIEW_NAVIGATING', 'wxEVT_WEBVIEW_NEWWINDOW', 'wxEVT_WEBVIEW_SCRIPT_MESSAGE_RECEIVED', 'wxEVT_WEBVIEW_SCRIPT_RESULT', 'wxEVT_WEBVIEW_TITLE_CHANGED']
>>>
I then ran a small test app which uses wx.html2 to display a simple web-browser and was able to successfully open the webpage https://wxpython.org/
So the master branch does have the fix for libwebkit2gtk-4.1
.
I think the reason that it didnât appear to work for me when I tried earlier was that I hadnât set PYTHONPATH
correctly
Note: /home/richardt/Sources
is a symbolic link to /mnt/SSD_3/Sources
.