Thanks a lot, Jonni!

Discussion went further already, but I am just fascinated you guys have got
such a plugin ready! I used to implement GConf modification on my own or
create a Settings wrapper for the LocalStorage and now there's a ready made
plugin for GConf - great!

Best regards,
Artem.



On Fri, Nov 15, 2013 at 7:44 AM, Jonni Rainisto <jonni.raini...@jolla.com>wrote:

> Hi,
>
> Normal usage of QSettings which saves under /home/nemo/.config/app would
> be just fine for C++.
> If you just want to save few config values in QML, then you might want to
> use GConf by importing nemo-qml-plugin-configuration module (
> https://github.com/nemomobile/nemo-qml-plugin-configuration) and use
> config key like com/yourdomain/applicationname etc.
>
> For example:
> --
> import org.nemomobile.configuration 1.0
>
> Page {
>     ConfigurationValue {
>         id: your_foo_setting
>         key: "/com/super/superapplication/light_value"
>         defaultValue: "-1"
>     }
> --
> re, Jonni
> ________________________________________
> From: devel-boun...@lists.sailfishos.org [
> devel-boun...@lists.sailfishos.org] on behalf of Thomas Tanghus [
> tho...@tanghus.net]
> Sent: Friday, November 15, 2013 3:13 AM
> To: Sailfish OS Developers
> Subject: [SailfishDevel] Saving state/config
>
> I couldn't find any standard way of saving an apps config. Is there such a
> standard, or is it up to the developer to choose format and location?
>
> I'm making a *very* simple app, so only using QML/JS, and only have to save
> 3-4 values.
>
> As far as I could see the location should be
> /home/nemo/.config/appname[.ext]
> which could probably be accomplished better using
> QStandardPaths::writableLocation(QStandardPaths::ConfigLocation) but is
> that
> possible in QML?
> And which format should it be in?
>
> --
> Med venlig hilsen / Best Regards
>
> Thomas Tanghus
> _______________________________________________
> SailfishOS.org Devel mailing list
> _______________________________________________
> SailfishOS.org Devel mailing list
>



-- 
Artem Marchenko
http://agilesoftwaredevelopment.com
http://twitter.com/AgileArtem
_______________________________________________
SailfishOS.org Devel mailing list

Reply via email to