dsettingswidgetfactory_zh
2022-04-14 15:58:39

Class::DSettingsWidgetFactory

暂无该属性


Detailed Description

DSettingsWidgetFactory 是一个用于构造Deepin风格的设置对话框的控件。\n 对于每种控件,均由一个id和对应的构造函数来组成, DSettingsWidgetFactory 内置了许多基础的控件,包括:\n checkbox/lineedit/combobox/spinbutton/buttongroup/radiogroup/slider等。 ~chinese

DSettingsWidgetFactory::metaObject

[public plain  virtual]

const QMetaObject * metaObject() const

DSettingsWidgetFactory::qt_metacast

[public plain  virtual]

void * qt_metacast(const char *)

DSettingsWidgetFactory::qt_metacall

[public plain  virtual]

int qt_metacall(QMetaObject::Call , int , void **)

DSettingsWidgetFactory::tr

[public plain static ]

QString tr(const char *s, const char *c, int n)

DSettingsWidgetFactory::trUtf8

[public plain static ]

QString trUtf8(const char *s, const char *c, int n)

DSettingsWidgetFactory::qt_static_metacall

[private plain static ]

void qt_static_metacall(QObject *, QMetaObject::Call , int , void **)

Class::QPrivateSignal

DSettingsWidgetFactory::QPrivateSignal


Detailed Description

typedef DSettingsWidgetFactory::WidgetCreateHandler

自定义的控件构建函数,一般接受一个 Dtk::Core::DSettingsOption 作为参数。\n

typedef DSettingsWidgetFactory::ItemCreateHandler

DSettingsWidgetFactory::DSettingsWidgetFactory

[public constructor  ]

DSettingsWidgetFactory(QObject *parent)

DSettingsWidgetFactory::~DSettingsWidgetFactory

[public destructor  virtual]

~DSettingsWidgetFactory()

DSettingsWidgetFactory::registerWidget

[public plain  ]

void registerWidget(const QString &viewType, int handler)

向Factory注册一种类型viewType。注册该类型后,可以通过在DSettings的DOption中,设置type为对应的viewType,这样Factory在构建viewType对应的控件时,会调用handler所指定的方法来构建。 viewType 控件类型,建议为全局唯一的字符串,且不要和内部类型重复,参考 Dtk::Widget::DSettingsWidgetFactory handler 自定义的控件构建函数, 参考 Dtk::Widget::DSettingsWidgetFactory::WidgetCreateHandler

DSettingsWidgetFactory::createWidget

[public plain  ]

QWidget * createWidget(int option)

DSettingsWidgetFactory::createWidget

[public plain  ]

QWidget * createWidget(const QByteArray &translateContext, int option)

DSettingsWidgetFactory::createItem

[public plain  ]

int createItem(int ) const

DSettingsWidgetFactory::createItem

[public plain  ]

int createItem(const QByteArray &, int ) const

DSettingsWidgetFactory::createStandardItem

[public plain static ]

int createStandardItem(const QByteArray &, int *, QWidget *)

DSettingsWidgetFactory::d_func

[private plain  ]

DSettingsWidgetFactoryPrivate * d_func()

DSettingsWidgetFactory::d_func

[private plain  ]

const DSettingsWidgetFactoryPrivate * d_func() const