2

I edited a python plugin's code and had to change the UI a bit as well. However, unlike in the plugins I made from scratch with the plugin builder, the UI doesn't automatically update in QGIS when I change the .ui file with Qt designer and reload the plugin. I figured I'd have to compile it (to .py) manually with

"C:\Program Files\QGIS Chugiak\bin\pyrcc4" -o ui_changeDSDialog.py ui_changeDSDialog.ui

but that just throws a "No resources in resource description." error. How do I compile it?

/edit: pyuic4 doesn't work either.

ImportError: No module named site

Nor does -x -o

  • You don't need to compile it. There should be a change after you reload plugins. If there are changes in xml file and its not working, there must be something wrong with your QGIS. – dmh126 Jun 27 '15 at 17:41
  • Hmm okay, I don't need to compile it (to .pyc). However, the .py file does not change when I change the .ui file. I can open the .py file in a text editor and edit the ui elements textually, which is reflected in QGIS. So the question still remains.. how do I go from .ui to .py? Maybe compiling is the wrong word. Translating? – MapEngine Jun 28 '15 at 19:39
  • It shouldn't change. Your ui_changeDSDialog.py contains only one class, which is constructor and it doesn't change after editing ui. – dmh126 Jun 28 '15 at 21:20
  • I'm a bit confused, in the first comment you said it should change (on its own?), now it shouldn't? – MapEngine Jun 29 '15 at 8:43
  • In first comment I wrote about ui_changeDSDialog.ui, It's pure xml file. – dmh126 Jun 29 '15 at 9:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.