[Development] QSettings refactor updates

Simon Hausmann simon.hausmann at theqtcompany.com
Mon Oct 20 14:26:17 CEST 2014


On Monday 20. October 2014 20.11.20 Thiago Macieira wrote:
> On Monday 20 October 2014 08:36:17 Simon Hausmann wrote:
> > On Monday 20. October 2014 07.06.00 Thiago Macieira wrote:
> > > On Sunday 19 October 2014 22:39:42 Branislav Katreniak wrote:
> > > > > Cache format: binary json
> > > > 
> > > > You use json internally as cache. What is the motivation to introduce
> > > > new classes with similar API like QJson classes?
> > > 
> > > It's an implementation detail because the binary json loading and
> > > parsing
> > > is extremely fast.
> > 
> > What about the data type support?
> 
> Should be completely transparent and orthogonal. The data types supported by
> the front-end should not be affected by whatever it uses for caching.

Ah, so that means custom types (types other than what QJson supports) will be 
converted to the same QVariant(0x12, 0x54, ...) type of string as in .ini 
files?

> > The current .ini format Qt defines allows for custom types to be stored
> > (in
> > a hackish way and hard to version). Would the new API be limited to
> > booleans, integers, doubles and strings? (i.e. no QVariant in the API)
> 
> I'd say it's a good idea to do that, though I'm pretty sure we'll get asked
> for lists too. Then again, for lists I'd save multiple config entries
> instead of one entry containing multiple items.

Yeah, I think that's a lot more robust than trying to look for an unescaped 
',' and then split.
 
Does XDG allow for that?


Simon



More information about the Development mailing list