<html><head></head><body>Just speculating,  have you tried instead of using a custom qgs widget to promote a QWidget to one of the custom widget?  I used this in the past for using my own widgets in my plugins. An example here [1]<br>
<br>
Ciao<br>
<br>
[1] <br>
<a href="http://bit.ly/2dOuDcs">http://bit.ly/2dOuDcs</a><br><br><div class="gmail_quote">On 6 October 2016 15:26:33 CEST, C Hamilton <adenaculture@gmail.com> wrote:<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid"><span>> One other thing for windows in the file PlotDialog.ui where it has the<br />
> following:<br />
><br />
>  <customwidgets><br />
>   <customwidget><br />
>    <class>QgsColorButtonV2</<wbr />class><br />
>    <extends>QToolButton</extends><br />
>    <header>qgscolorbuttonv2.h</<wbr />header><br />
>    <container>1</container><br />
>   </customwidget><br />
>  . . .<br />
><br />
> Every time you see <header>...h</header> it needs to be changed to<br />
> <header>qgis.gui</header><br />
<br />
</span>> first time I hear of such an error.. UI have been created with Qt<br />
> Designer so they should be cross pltamform<br />
<span><br /></span></blockquote><div>This is actually a known problem for any of the QGIS custom modules used in Qt Designer. It is because it is using the  C++ header to indicate where the module is located, but since it is python it is located in qgis.gui. This is only a problem with the custom widgets and unfortunately when you change <header>qgscolorbuttonv2.h</<wbr />header> to <header>qgis.gui</<wbr />header> and then save it with Qt Designer, it reverts back to the C++ header. Also this is only a problem when using loadUiType</div><div><br /></div><div><span class="gmail-pl-c1">FORM_CLASS</span>, _ <span class="gmail-pl-k">=</span> uic.loadUiType(os.path.join(os.path.dirname(<span class="gmail-pl-c1">__file__</span>), <span class="gmail-pl-s"><span class="gmail-pl-pds">'</span>ui/plotDialog.ui<span class="gmail-pl-pds">'</span></span>))</div><div><br /></div><div>If you compile the .ui file with pyuic4 then you don't encounter the
problem.</div><div><br /></div><div>All the best!</div></div></div></div>
<p style="margin-top: 2.5em; margin-bottom: 1em; border-bottom: 1px solid #000"></p><pre class="k9mail"><hr /><br />Qgis-developer mailing list<br />Qgis-developer@lists.osgeo.org<br />List info: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br />Unsubscribe: <a href="http://lists.osgeo.org/mailman/listinfo/qgis-developer">http://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre></blockquote></div><br>
-- <br>
Marco Bernasocchi (mobile).<br>
<a href="http://OPENGIS.ch">OPENGIS.ch</a> - <a href="http://berna.io">berna.io</a> - <a href="http://27summits.ch">27summits.ch</a></body></html>