Or the best thing for Linux + QML - use Qt GSettings binding
https://launchpad.net/gsettings-qt :)

2013/11/18 Mandeep Sandhu <mandeepsandhu....@gmail.com>:
> On Mon, Nov 18, 2013 at 5:24 PM, André Somers <an...@familiesomers.nl> wrote:
>> Tomasz Siekierda schreef op 17-11-2013 17:29:
>>> The settings class is a Singleton, and all options are accesible
>>> through member variables (private + getters and setters, or public -
>>> if you prefer). Although I personally believe Singletons are evil,
>>> they can be useful - and this is one of the place where the benefits
>>> outweight the problems.
>> Singletons really are evil indeed. However, Qt already provides one, and
>> you might as well use it: QApplication. We usually make our settings
>> object a member of our own QApplication-derived Application class. That
>> way, it is available where needed, but we don't have another singleton.
>
> Do you provide any sort of access restrictions to the settings. Eg: if
> some modules should only be able to read a particular setting and not
> change it, where would you enforce this? in the module itself or
> somewhere else or is this something not relevant in your context?
>
> Thanks,
> -mandeep
>
>>
>> André
>>
>> _______________________________________________
>> Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
> _______________________________________________
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
_______________________________________________
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest

Reply via email to