41 return new QgsDateTimeEditConfig( vl, fieldIdx, parent );
46 QHash<const char *, int> map = QHash<const char *, int>();
47 map.insert( QDateTimeEdit::staticMetaObject.className(), 10 );
48 map.insert( QgsDateTimeEdit::staticMetaObject.className(), 10 );
56 if ( field.
isDateOrTime() || config.contains( QStringLiteral(
"field_format" ) ) )
QgsEditorWidgetWrapper * create(QgsVectorLayer *vl, int fieldIdx, QWidget *editor, QWidget *parent) const override
Override this in your implementation.
QgsDateTimeEditFactory(const QString &name)
Constructor for QgsDateTimeEditFactory, where name is a human-readable name for the factory...
Wraps a date time widget.
QgsEditorWidgetSetup editorWidgetSetup() const
Gets the editor widget setup for the field.
QgsFields fields() const FINAL
Returns the list of fields of this layer.
QHash< const char *, int > supportedWidgetTypes() override
Returns a list of widget types which this editor widget supports.
QgsSearchWidgetWrapper * createSearchWidget(QgsVectorLayer *vl, int fieldIdx, QWidget *parent) const override
By default a simple QgsFilterLineEdit is returned as search widget.
Encapsulate a field in an attribute table or data source.
unsigned int fieldScore(const QgsVectorLayer *vl, int fieldIdx) const override
This method allows disabling this editor widget type for a certain field.
QgsEditorConfigWidget * configWidget(QgsVectorLayer *vl, int fieldIdx, QWidget *parent) const override
Override this in your implementation.
Represents a vector layer which manages a vector based data sets.
QgsField field(int fieldIdx) const
Gets field at particular index (must be in range 0..N-1)