could pyside6-rcc compile .qrc to .rcc ?
-
I am using python 3.9.7, pyside 6.2.1.
I ran the following command.pyside6-rcc --binary some.qrc -o some.rcc
Then I got some.rcc but it was not a binary file. The contents of the file equalled to a file created by pyside6-rcc without --binarny option, likes some.py file.
Maybe I did not input arguments to pyside6-rcc properly. How could I get binary .rcc file..? -
@EbyZero said in could pyside6-rcc compile .qrc to .rcc ?:
pyside6-rcc --binary
Could you supply a reference link for the command-line usage of
pyside6-rcc
? I am unable to locate such, so do not even know if it accepts a--binary
option or what it says about it. -
@EbyZero
I don't use Python, PySide-anything or Qt6! Hence I was looking an online documentation reference forpyside6-rcc
, because I can't spot one Googling... indeed, there doesn't seem to be much out there aboutpyside6-rcc
, only a bit about olderpyside2-rcc
, and under Linux, where it didn't seem to have any--binary
option. -
@JonB
I could not find it on google too. so I opened this post.
umm..let me short explain, if you installed pyside6 by pip, many qt6 stuffs installed in python directory including qt6 tools like designer, lupdate, lrelease, rcc, uic, linguist, etc.
Because it's hard to find and execute tools in python directory when the tool be needed, pyside6 provides prefixed-named tools like 'pyside6-designer.exe' in python scripts directory can be used just on the terminal.
Most of prefixed-named tools equals to original tools, so I thought 'pyside6-rcc.exe' also equals to 'rcc.exe', but it was not.
Also I couldn't find accurate information on google, so I asked a question.
I didn't get an answer yet, but I can get a binary .rcc file to use directly original rcc.exe in pyside6 directory.
I'm not an english user, I'm not sure I explained it properly. Off topic, google translator is great. -
Hi,
From the back of my memory, for Python the .qrc file will be converted in something useable in Python so you can import it and thus make it usable in your application. So you likely got a Python module that you can use with your code.
-
Here you have the tutorial on how to use qrc files. I have never seen a python project that works with a binary rcc file, the proper way is just to generate a python file that internally is serialized:
https://doc.qt.io/qtforpython/tutorials/basictutorial/qrcfiles.htmlSo only a
pyside6-rcc yourfile.qrc -o rc_yourfile.py
is enough to then do animport rc_yourfile.py
and use the resources.