<div dir="ltr">Hi Matteo,<div>thank you for the help, your solution works fine in linux. Do you know if something similar exists for Windows?</div><div><br></div><div>Thanks</div><div>Roberta</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Il giorno mer 19 giu 2019 alle ore 08:24 matteo <<a href="mailto:matteo.ghetta@gmail.com">matteo.ghetta@gmail.com</a>> ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi Roberta,<br>
<br>
well the process is pretty easy and straightforward.<br>
<br>
I use the Makefile to manage all the process [0].<br>
<br>
Basically the steps are:<br>
<br>
* adding a list to locales in the Makefile, like: LOCALES = en it nl<br>
* always in the Makefile add all the paths to the files that contains<br>
the string you want to translate (managed by the <a href="http://self.tr" rel="noreferrer" target="_blank">self.tr</a>() method):<br>
<br>
SOURCES = \<br>
        __init__.py \<br>
        plugin.py plugin_dialog.py<br>
<br>
UI_FILES = plugin_base.ui<br>
<br>
* now you can use make transup to create the ts file in all the languages<br>
* translate using the software you prefer<br>
* compile the ts in qm using make transcompile<br>
<br>
That's it. Whenever you add/change something in the files/UI you have to<br>
run make transup again, translate, recompile<br>
<br>
Cheers<br>
<br>
Matteo<br>
<br>
<br>
<br>
[0]<br>
<a href="https://docs.qgis.org/testing/en/docs/pyqgis_developer_cookbook/plugins.html#translate-using-makefile" rel="noreferrer" target="_blank">https://docs.qgis.org/testing/en/docs/pyqgis_developer_cookbook/plugins.html#translate-using-makefile</a><br>
_______________________________________________<br>
QGIS-Developer mailing list<br>
<a href="mailto:QGIS-Developer@lists.osgeo.org" target="_blank">QGIS-Developer@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></blockquote></div>