[Qgis-developer] Better options dialogs

Etienne Tourigny etourigny.dev at gmail.com
Sun Jan 6 13:34:43 PST 2013


On Sat, Jan 5, 2013 at 7:48 PM, Andreas Neumann <a.neumann at carto.net> wrote:
> Hi,
>
> See my reply inline.
>
>>> Where do you get the list of properties from? Could tags and descriptive
>>> text be added to these settings?
>>
>> Actually they are read from the settings file / registry by QSettings.
>> So anything not in the user's setting does not show up.
>
> ok
>
>> Anything more complex such as you mention would require a csv or xml
>> file with description and tags for each settings key.
>> A csv file would be easier to write and maintain, but an xml file
>> would be easier to parse I guess. Unless someone can point me to
>> a handy xml editor or csv-to-xml tool.
>
> Ok - we would also need multi-language titles and tags and it should be
> easily translatable. Can we re-use some existing file for that purpose
> and extend it with the tags for the fuzzy search?

I don't really have a clue on where to start... Ideally this should be
integrated with current translation tools.

The translation part would be easier if there is straight c++ source
with many tr() statements that could be translated with Qt Linguist.
i.e.
 map["somekey"]["name"] = "This option is for something";
 map["somekey"]["tags"] = "tag1,tag2,tag3";

However, setting this up would be a pain for devs. It would be nicer
to have just a text file with a bunch of entries.
i.e. a csv file
key ; name ; tags
"somekey" ;  "This option is for something" ; "tag1,tag2,tag3"

Anyone have an idea on how to create this kind of file and allow to
use something like Qt Linguist to translate the entries into any
language?

Or is it just simpler to write in code?

>
>> Another thing that would be nice would be the possible values that a
>> setting can take, in a dictionnary (key=value pairs) style.
>> (e.g. 0="value1";1="value2")
>
> yes - it should also be possible to manually add/change settings that
> one could read/write per python script.

Do you mean an API accessible by python scripts/plugins to create
entries in the advanced settings editor?

cheers
Etienne

>
> Andreas
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-developer


More information about the Qgis-developer mailing list