17#include "moc_qgsclassificationwidgetwrapper.cpp" 
   30  return mComboBox->currentData();
 
 
   40  QComboBox *combo = 
new QComboBox( parent );
 
   41  combo->setMinimumContentsLength( 1 );
 
   42  combo->setSizeAdjustPolicy( QComboBox::SizeAdjustPolicy::AdjustToMinimumContentsLengthWithIcon );
 
 
   48  mComboBox = qobject_cast<QComboBox *>( editor );
 
   56      for ( 
int i = 0; i < categories.size(); i++ )
 
   58        QString label = categories[i].label();
 
   59        const QString 
value = categories[i].value().toString();
 
   60        if ( label.isEmpty() )
 
   63        mComboBox->addItem( label, 
value );
 
 
   76void QgsClassificationWidgetWrapper::updateValues( 
const QVariant &value, 
const QVariantList & )
 
   78  mComboBox->setCurrentIndex( mComboBox->findData( 
value ) );
 
A feature renderer which represents features using a list of renderer categories.
 
const QgsCategoryList & categories() const
Returns a list of all categories recognized by the renderer.
 
Represents a vector layer which manages a vector based dataset.
 
QgsFeatureRenderer * renderer()
Returns the feature renderer used for rendering the features in the layer in 2D map views.
 
QgsSignalBlocker< Object > whileBlocking(Object *object)
Temporarily blocks signals from a QObject while calling a single method from the object.
 
QList< QgsRendererCategory > QgsCategoryList