<p dir="ltr">Make files don't work very well on windows I would avoid them if you can. Any reason the UI can't be loaded in code to avoid the build steps.</p>
<br><div class="gmail_quote"><div dir="ltr">On Thu, 6 Aug 2015 6:54 pm Denis Rouzaud <<a href="mailto:denis.rouzaud@gmail.com">denis.rouzaud@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Here is an example of a Makefile compiling ui files<br>
<a href="https://github.com/3nids/quickfinder/blob/master/Makefile#L52" target="_blank">https://github.com/3nids/quickfinder/blob/master/Makefile#L52</a><br>
<br>
it's the line with pyuic4 which does the job!</div><div bgcolor="#FFFFFF" text="#000000"><br>
<br>
<br>
<br>
<div>On 08/06/2015 10:33 AM, Anita Graser
wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div class="gmail_default" style="font-size:small"><br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Thu, Aug 6, 2015 at 10:10 AM,
Denis Rouzaud <span dir="ltr"><<a href="mailto:denis.rouzaud@gmail.com" target="_blank">denis.rouzaud@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"> Never used, I would
think it would work directly.<br>
</div>
</blockquote>
<div><br>
</div>
<div>
<div class="gmail_default" style="font-size:small">
According to the plugin author the plugin with
uic.loadUiTypes works on Linux but it certainly does not
work on Windows.</div>
</div>
<div>
<div class="gmail_default" style="font-size:small"></div>
</div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"> But why not adding
a new rule to the makefile to compile the ui?</div>
</blockquote>
<div><br>
</div>
<div>
<div class="gmail_default" style="font-size:small">If
that's necessary to get custom widgets work on all
platforms, why not. But I don't know where to start to
make that work.</div>
<div class="gmail_default" style="font-size:small"><br>
</div>
<div class="gmail_default" style="font-size:small">Best
wishes.</div>
<div class="gmail_default" style="font-size:small">Anita</div>
<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
<div>
<div><br>
<br>
<br>
<br>
<div>On 08/06/2015 10:06 AM, Anita Graser wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div style="font-size:small"><br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Thu, Aug 6, 2015
at 9:44 AM, Denis Rouzaud <span dir="ltr"><<a href="mailto:denis.rouzaud@gmail.com" target="_blank"><a href="mailto:denis.rouzaud@gmail.com" target="_blank">denis.rouzaud@gmail.com</a></a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Well, how is compiled the UI file?<br>
</div>
</blockquote>
<div><br>
</div>
<div>
<div style="font-size:small">The plugin
builder creates a template that uses
uic.loadUiType</div>
<br>
FORM_CLASS, _ =
uic.loadUiType(os.path.join(<br>
os.path.dirname(__file__),
'cartogram_dialog_base.ui'))
<div style="font-size:small"></div>
</div>
<div>
<div style="font-size:small">So the UI is
compiled automatically when the plugin
starts in QGIS.</div>
<div style="font-size:small"><br>
</div>
<div style="font-size:small">Best wishes,</div>
<div style="font-size:small">Anita</div>
<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div> </div>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Usually, it is done prior to deployment
using pyuic4<br>
<br>
If pyuic4 was run without the proper
python path, you won't have any error at
compilation but the plugin won't work if
it contains QGIS widgets.<br>
<br>
Was pyuic4 run in an Osgeo shell?
<div>
<div><br>
<br>
<br>
<br>
<div>On 08/06/2015 09:39 AM, Anita
Graser wrote:<br>
</div>
<blockquote type="cite">
<div dir="ltr">
<div style="font-size:small"><br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On
Thu, Aug 6, 2015 at 9:24 AM,
Denis Rouzaud <span dir="ltr"><<a href="mailto:denis.rouzaud@gmail.com" target="_blank"><a href="mailto:denis.rouzaud@gmail.com" target="_blank">denis.rouzaud@gmail.com</a></a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000"> You need
to have qgis lib in your
python path.<br>
On windows, that would
be
C:\OSGeo4W\apps\qgis-dev\python\qgis<br>
To check this, just do
"from qgis.gui import *"
in python. If you don't
have an error, then
pyuic4 will work
properly.<br>
</div>
</blockquote>
<div><br>
</div>
<div>My point is that the
plugin needs to work out
of the box - and it
doesn't. <br>
</div>
<div>
<div style="font-size:small">Usually
all paths are set
correctly on Win in the
OSGeo shell. Only in
this case there is an
issue.</div>
<div style="font-size:small"><br>
</div>
<div style="font-size:small">Best
wishes,</div>
<div style="font-size:small">Anita</div>
<div style="font-size:small"><br>
</div>
</div>
</div>
<br>
</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra"><br>
</div>
</div>
</blockquote>
<br>
</div>
</div>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</blockquote>
<br>
</div>
</div>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</blockquote>
<br>
</div>
_______________________________________________<br>
Qgis-developer mailing list<br>
<a href="mailto:Qgis-developer@lists.osgeo.org" target="_blank">Qgis-developer@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></blockquote></div>