3nids / quickfinder

Quick Finder is a QGIS 2.x plugin offering a single place to perform searches on project layers and online remote services
http://3nids.github.io/quickfinder/
Other
8 stars 14 forks source link

Accessing plugin settings through QSettings #27

Closed rbovard closed 9 years ago

rbovard commented 9 years ago

Hi Denis,

Is there a way to access plugin settings through QSettings?

The goal is to deploy this plugin with some settings, especially geomapfishUrl and geomapfishCrs.

TIA

3nids commented 9 years ago

Salut Rémi, These settings are project related (QgsProject) and not global settings (QSettings).

See https://github.com/3nids/quickfinder/blob/master/core/mysettings.py

You can manually set them with QgsProject.instance().writeEntry('quickfinder_plugin', 'geomapfishUrl','my_url')

rbovard commented 9 years ago

Thanks for the quick answer and the explanation.

I understand how to set them with writeEntry but in this case, as you said, it's only project related. So if I open another project, those settings are gone.

Is not possible to add the possibility to store them in global settings? Still in the context of a global deploy.