Skip to content

Commit 2df37a2

Browse files
committed
Some visual tweaks to property assistant widget
1 parent 9c19142 commit 2df37a2

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

src/gui/qgspropertyassistantwidget.cpp

+4-2
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ void QgsPropertyAssistantWidget::updatePreview()
164164
mPreviewList.clear();
165165

166166
QList<double> breaks = QgsSymbolLayerUtils::prettyBreaks( minValueSpinBox->value(),
167-
maxValueSpinBox->value(), 4 );
167+
maxValueSpinBox->value(), 8 );
168168

169169
QList< QgsSymbolLegendNode* > nodes = mTransformerWidget->generatePreviews( breaks, mLayerTreeLayer, mSymbol.get(), minValueSpinBox->value(),
170170
maxValueSpinBox->value() );
@@ -181,7 +181,9 @@ void QgsPropertyAssistantWidget::updatePreview()
181181
const QSize minSize( node->minimumIconSize() );
182182
node->setIconSize( minSize );
183183
widthMax = qMax( minSize.width(), widthMax );
184-
mPreviewList.appendRow( new QStandardItem( node->data( Qt::DecorationRole ).value<QPixmap>(), QString::number( breaks[i] ) ) );
184+
QStandardItem* item = new QStandardItem( node->data( Qt::DecorationRole ).value<QPixmap>(), QString::number( breaks[i] ) );
185+
item->setEditable( false );
186+
mPreviewList.appendRow( item );
185187
delete node;
186188
i++;
187189
}

src/ui/qgspropertyassistantwidgetbase.ui

+8
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,14 @@
121121
<height>16777215</height>
122122
</size>
123123
</property>
124+
<property name="toolTip">
125+
<string>Fetch value range from layer</string>
126+
</property>
127+
<property name="icon">
128+
<iconset>
129+
<normalon>:/images/themes/default/mActionDraw.svg</normalon>
130+
</iconset>
131+
</property>
124132
</widget>
125133
</item>
126134
<item row="0" column="1" colspan="2">

0 commit comments

Comments
 (0)