Filters configuration

Cyrille Berger cberger at
Sun Oct 16 18:48:26 CEST 2005


I have the feeling, for sometime, that we could do better for 
filtersconfiguration than what we are doing.
Here is my proposition :

class KisFilterConfiguration {

KisFilterWidget createWidget();
void addGroup(KisFilterConfigurationGroup*> );

KisFilterConfigurationValue* operator[char * name];
vector<KisFilterConfigurationGroup*> m_groups;

class KisFilterConfigurationGroup {

KisFilterWidget* createWidget(QWidget* parent);
vector<KisFilterConfigurationValue*> m_children;

class KisFilterConfigurationValue {

virtual KisFilterWidget* createWidget(QWidget* parent) =0;

class KisFilterConfigurationDoubleValue : public KisFilterConfigurationValue {
double value();


class KisFilterConfigurationIntValue : public KisFilterConfigurationValue {
int value();

etc... (one subclass of KisFilterConfigurationValue for each different types 
of value).

I am considering using namespaces for this one.
What do you think ?

--- Cyrille Berger ---

More information about the kimageshop mailing list