Feature request #2562
Two fixes to utils.py
|Pull Request or Patch supplied:||Resolution:||fixed|
|Easy fix?:||No||Copied to github as #:||12622|
This patch makes two changes to utils.py.
1) updates the canUninstallPlugin function to provide a bit more robustness, in particular to allow the plugin to be uninstalled if its canBeUninstalled function throws an exception.
2) adds a new function showPluginHelp. This is designed to be called from a plugin, using
from qgis import utils
This will open a help file in the plugin directory in the users browser. It will first look for index-ll.html, where ll is the major locale, and if it doesn't find that, will try index.html. This allows for multiple language versions of the help file. It has optional parameters to replace "index" with an alternative helpfile name, and to append an html anchor to the url to jump to directly to a section of the helpfile.
The function can also be called specifying a package name, e.g.
The intention of this is to provide a simple common way for python plugins to supply documentation