KConfig compiler. GenerateProperties and Mutable.

Artem Fedoskin afedoskin3 at gmail.com
Thu May 26 00:31:29 UTC 2016


>>> We could also start with turning that into quint64, to already double
the number of possible settings, right? Easy short term fix.

Am I correct that with quint64 we will gain just 32 more additional unique
signal bit masks? The problem is that my config file has more than 300.

I managed to make mSettingsChanged QHash<int,bool>. This way we hold there
only non-modify signals. However, I encountered some other problems:

   1. Sometimes read function in Q_PROPERTY declaration starts with capital
   letter while the read function itself starts with the lowercase one. Almost
   the same thing happens with signal names. At each call to
   changeSignalName() and name() I make the first letter capital, is it OK?
   2. Some of the properties in my .kcfg file have min and max values but
   KConfigCompilerSignallingItem doesn't support them. Should I just copy all
   the stuff from ItemInt or is it better to make it a subclass of ItemInt?

Thank you for your help. After getting an answer to these questions I'm
going to file a review request for my patch.

Regards, Artem

2016-05-23 9:09 GMT+02:00 David Faure <faure at kde.org>:

> On mardi 10 mai 2016 16:49:57 CEST Aleix Pol wrote:
> > On Mon, May 9, 2016 at 8:02 PM, Artem Fedoskin <afedoskin3 at gmail.com>
> wrote:
> > > Dear KDE developers,
> > >
> > > For my GSoC 2016 project at KDE (Lite version of KStars for mobile
> > > devices)
> > > I need to access C++ class generated from XML configure file with
> KConfig
> > > compiler from QML. I found in this patch
> > > https://git.reviewboard.kde.org/r/123367/ and in the source code of
> > > KConfig
> > > compiler that I should set GenerateProperties=true in my .kcfgc file to
> > > create option properties as Q_PROPERTY. However, I got following error
> > > "Too
> > > many signals to create unique bit masks". There is some conflict
> between
> > > Mutators and GenerateProperties options that causes this error in my
> XML
> > > configure file but I can't figure out what I should change to have
> setters
> > > in Q_PROPERTY.
> > >
> > > Would be grateful if someone could help me with this issue.
> > >
> > > Options.kcfgc - https://paste.kde.org/pm1klcbls
> > >
> > > kstars.kcfg - https://paste.kde.org/phit6qibo
> >
> > Hi Artem,
> > KConfigCompiler is limited in this regard by an implementation detail.
> > See "uint mSettingsChanged;".
> >
> > To solve it, I would patch kconfig_compiler and turn it into an
> > std::vector<bool> or patch kstars.kcfg to use separate config files
> > rather than a huge one.
>
> We could also start with turning that into quint64, to already double the
> number of possible settings, right? Easy short term fix.
>
> --
> David Faure, faure at kde.org, http://www.davidfaure.fr
> Working on KDE Frameworks 5
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20160526/832ab9b4/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list