[Qgis-developer] Enable / disable a plugin in Python

Rémi Bovard remi.bovard at gmail.com
Fri May 16 00:42:30 PDT 2014


Hi Arnaud,

Thanks for your answer, it works fine but only with Python plugins. I can
get the list of available plugin with:
`qgis.utils.available_plugins`

In my case, I'd like to enable / disable plugin like Grass or Road graph.

Any hint?

Merci.

Rémi


2014-05-15 20:46 GMT+02:00 Arnaud Morvan <arnaud.morvan at camptocamp.com>:

>
> qgis.utils.loadPlugin(packageName)
> qgis.utils.unloadPlugin(packageName)
>
> You can take a look at the "Plugin Reloader" plugin
>
> https://github.com/borysiasty/plugin_reloader/blob/master/reloader_plugin.py
>
> qgis.utils seems to be based on qgspythonutils.h
> https://github.com/qgis/QGIS/blob/master/src/python/qgspythonutils.h
>
> Arnaud
>
> Le 15/05/2014 17:51, Rémi Bovard a écrit :
>
> Hi list,
> I'm wondering what is the best way to enable / disable a plugin in Python
> (like the checkbox does in the plugin manager)?
> Thank you in advance.
> Rémi
>
>
> _______________________________________________
> Qgis-developer mailing listQgis-developer at lists.osgeo.orghttp://lists.osgeo.org/mailman/listinfo/qgis-developer
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20140516/d3429da5/attachment.html>


More information about the Qgis-developer mailing list