Tools to supplement the official PyQt5 wheels
Project description
The PyQt5 wheels do not provide tools such as Qt Designer that were included in the old binary installers. This package aims to provide those in a separate package which is useful for developers while the official PyQt5 wheels stay focused on fulfilling the dependencies of PyQt5 applications.
Installation
yourenv\Scripts\pip.exe install --pre pyqt5-tools~=5.11
You will generally install pyqt5-tools using pip install. In most cases you should be using virtualenv or venv to create isolated environments to install your dependencies in. The above command assumes an env in the directory yourenv. The --pre allows for the latest version to be installed despite not being a full release version. You will have to decide if this is a good option for you at any given point in time. The ~=5.11 specifies a release compatible with 5.11 which will be the latest version of pyqt5-tools built for PyQt5 5.11. If you are using a different PyQt5 version, specify it instead of 5.11. PyPI keeps a list of all available versions.
Usage
For each tool a script is created such that you get files like Scripts\designer.exe to launch the programs. Each one searches up the filesystem tree from your current working directory to find a .env file and loads it if found. If found the environment variable DOT_ENV_DIRECTORY will be set to the directory containing the .env file. With this extra variable you can specify paths relative to the .env location.
PYQTDESIGNERPATH=${PYQTDESIGNERPATH};${DOT_ENV_DIRECTORY}/path/to/my/widgets
Additionally, each pyqt5* wrapper listed below includes a parameter to run a basic example which can be used to see if the plugins are working. These examples are not intended to be used as examples of good code.
Designer
There is a Scripts\pyqt5designer.exe entry point that will help fill out PYQTDESIGNERPATH from either command line arguments or a .env file. Unknown arguments are passed through to the original Qt Designer program.
Usage: pyqt5designer [OPTIONS]
Options:
-p, --widget-path DIRECTORY Paths to be combined with PYQTDESIGNERPATH
--example-widget-path Include the path for the pyqt5-tools example
button (c:\users\sda\testenv\lib\site-
packages\pyqt5_tools)
--designer-help Pass through to get Designer's --help
--test-exception-dialog Raise an exception to check the exception
dialog functionality.
--qt-debug-plugins / --no-qt-debug-plugins
Set QT_DEBUG_PLUGINS=1
--help Show this message and exit.
If you want to use Form > View Code... from within Designer you can run Scripts\pyqt5toolsinstalluic.exe and it will copy pyuic5.exe such that Designer will use it and show you generated Python code. pyqt5 must already be installed or this script will be unable to find the original pyuic5.exe to copy.
In addition to the standard features of the official Designer plugin, this provides an exception dialog for your widget’s Python code. Otherwise Designer in Windows silently crashes on Python exceptions.
QML Plugin
The QML plugin is also included. In the future a tool may be provided to handle copying of the plugin to each directory where it is needed. For now this must be done manually.
site-packages\pyqt5_tools\Qt\bin\plugins\pyqt5qmlplugin.dll
QML Scene
Usage: pyqt5qmlscene [OPTIONS]
Options:
-p, --qml2-import-path DIRECTORY
Paths to be combined with QML2_IMPORT_PATH
--qmlscene-help Pass through to get QML scene's --help
--qt-debug-plugins / --no-qt-debug-plugins
Set QT_DEBUG_PLUGINS=1
--run-qml-example Run the pyqt5-tools QML example
--help Show this message and exit.
QML Test Runner
Usage: pyqt5qmltestrunner [OPTIONS]
Options:
-p, --qml2-import-path DIRECTORY
Paths to be combined with QML2_IMPORT_PATH
--qmltestrunner-help Pass through to get QML test runner's --help
--qt-debug-plugins / --no-qt-debug-plugins
Set QT_DEBUG_PLUGINS=1
--test-qml-example Test the pyqt5-tools QML example
--help Show this message and exit.
Special Thanks
Thanks to MacStadium for providing me with a macOS system to develop and test out the final pyqt5-tools platform.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for pyqt5_tools-5.15.0.1.7.2-cp38-cp38-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0af0c5f45e9e1590dd49de99747e2c87e37911588316447311a9aa0b8c2b8d13 |
|
MD5 | db3f62380c72f544af4e4f89570f2e9f |
|
BLAKE2b-256 | d96578a6b968bb269c9e99f9bdaa98abc414b618510283a4def2abb0fe53bcfb |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp38-cp38-manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 094ca3d6b5d310a620dd022875741aff2b21c7f0cb727131b3fc7959bdcb750f |
|
MD5 | 585b771a2068d33b3563c8d77b786ecc |
|
BLAKE2b-256 | f6579c200013e9e629f4402fbbe9f86f66c0ac5d69501228d191efff2c16568c |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp37-cp37m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0ba58ab944fdd1a7fc70b114ef5f58351e3ef5a6670dd999b349616926bf5c11 |
|
MD5 | ec60e56eb1254c89eee9c70e82d88d92 |
|
BLAKE2b-256 | 60761b182d33891b44346141dfc6933f3b4c5770ab59710b205cb216f3b57e03 |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp37-cp37m-manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0e0375f8d8a66f1205146d3f8f14643df6c5ca394646b076cb4b0f40f7de1826 |
|
MD5 | de861c3cc752e090e9be797883907319 |
|
BLAKE2b-256 | 5fbf05ff8933260e4adcd30825413b745d597a44a7be232a8381c6c4a8885896 |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp36-cp36m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2b0e924218267f237b1cb1d8bf37d3fb19a8aacc357a3b217821c800c81da293 |
|
MD5 | 7c85d598a7594c49ef341cfe6a967a8e |
|
BLAKE2b-256 | 2913ff126328754b6c6f570f466c182753f35ee4d1a404c343b2e5be9d668209 |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp36-cp36m-manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 11fac756107240b3a5ce0400e841bb976858160cf1d70f113a0a59504f622850 |
|
MD5 | 56d8b9f3699e2ccd576367a8832e1f5c |
|
BLAKE2b-256 | 7fb64fd50ce65e8e32e8e57a55f1f44c0e0ae79fa528d1718739a88b3685691e |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp35-cp35m-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 532bcb48be828d14e9d7354770ec39a9c3c46d8827adc823626b1c6b92079f28 |
|
MD5 | 3b8e64e113f686af4dcf456e7a056edf |
|
BLAKE2b-256 | 863f840d40c176363e96c1714a0d96d9fbb183e74f22d02503702f3beb33cff5 |
Hashes for pyqt5_tools-5.15.0.1.7.2-cp35-cp35m-manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 83f9402d9aabf3e389da6bdb5078dc2c3df36ecc5dc7b8b0ea6ce7fdfcd72661 |
|
MD5 | c89872a035d0ede7dd589ff7bcbdc2e9 |
|
BLAKE2b-256 | da6711d87a07b51cced2b8df8b37e1375023d408191855973adfd77646110185 |