Skip to content

Commit

Permalink
[style dock] use a QLineEntry for layer title (#3141)
Browse files Browse the repository at this point in the history
  • Loading branch information
nirvn authored and NathanW2 committed May 31, 2016
1 parent c7da8a7 commit bf9f5b6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 14 deletions.
4 changes: 2 additions & 2 deletions src/app/qgsmapstylingwidget.cpp
Expand Up @@ -62,7 +62,7 @@ void QgsMapStylingWidget::setLayer( QgsMapLayer *layer )
{
if ( !layer || !layer->isSpatial() )
{
mLayerTitleLabel->clear();
mLayerTitle->setText( QString() );
mStackedWidget->setCurrentIndex( mNotSupportedPage );
return;
}
Expand Down Expand Up @@ -177,7 +177,7 @@ void QgsMapStylingWidget::updateCurrentWidgetLayer()

mUndoWidget->setUndoStack( layer->undoStackStyles() );

mLayerTitleLabel->setText( layer->name() );
mLayerTitle->setText( layer->name() );

if ( layer->type() == QgsMapLayer::VectorLayer )
{
Expand Down
18 changes: 6 additions & 12 deletions src/ui/qgsmapstylingwidgetbase.ui
Expand Up @@ -154,24 +154,18 @@
<item row="0" column="0" colspan="2">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="mLayerTitleLabel">
<widget class="QLabel" name="textLabel">
<property name="text">
<string/>
<string>Layer name</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
<widget class="QLineEdit" name="mLayerTitle">
<property name="readOnly">
<bool>true</bool>
</property>
</spacer>
</widget>
</item>
<item>
<widget class="QCheckBox" name="mLiveApplyCheck">
Expand Down

0 comments on commit bf9f5b6

Please sign in to comment.