Join me for a special livestream
In this livestream I am going to show you how you can easily convert your old PySide or PyQt desktop apps to work with the custom widgets module without any errors
We are going to update this old GUI tutorial from this video: • 22 Modern UI - A Python App GUI For QT, Py...
Custom Widgets: https://github.com/KhamisiKibet/QT-Py...
https://pypi.org/project/QT-PyQt-PySi...
Complete source code: / updated-new-22-99539605
Steps
These are the steps were going to follow:
Install the latest Custom Widgets module
pip install --upgrade QT-PyQt-PySide-Custom-Widgets
Our GUI also uses an old version of PySideExtn that does not support PySide6 so we will install the new updated version I made
pip install PySideExtn
After installation, create an empty folder.
Inside this folder, create a new Custom Widgets project by running the command below
Custom_Widgets --create-project
Follow the onscreen prompt and feel the data you want.
After the project has been created you can run it to ensure everything is working
Now open your old project folder and copy every file to their respective folder inside the new project folder we just created. Ignore the following files:
The png icons files previously generated by the custom widget module, if available.
The interface ui_.... .py file genated from qt-designer or uic
Qrc rc_..... .py files generated from .qrc files.
The custom widgets will generate new icons inside the Qss folder. New ui and other files will also be generated.
When copying your files, please follow the folder structure described here: https://github.com/KhamisiKibet/QT-Py...
Now generate new files from your ui files. Assuming that you put all your UI files inside the ‘ui’ folder, run the following command to convert the files:
Custom_Widgets --convert-ui ui-path --qt-library your-lib
Replace ‘ui-path’ with you ui path or folder, fo this case the ui folder is ‘ui’.
Repace ‘your-lib’ with your qt lib, or live the remove argument(–qt-library your-lib) if youre using PySide6
RUN your project.
Be patient, new missing icon files will be generated. View your terminal for app theme progress activities.
That’s all. HAPPY CODING
License
MIT
Free Software, Hell Yeah!