Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Small enhancements for labeling dialog: disable minimum size ui for p…
…oints, add pt to font name and set two decimal places for distance spin boxes

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13616 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Jun 1, 2010
1 parent f94e381 commit 5da64f2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
4 changes: 3 additions & 1 deletion src/app/qgslabelinggui.cpp
Expand Up @@ -61,6 +61,8 @@ QgsLabelingGui::QgsLabelingGui( QgsPalLabeling* lbl, QgsVectorLayer* layer, QWid
}

chkMergeLines->setEnabled( layer->geometryType() == QGis::Line );
label_19->setEnabled( layer->geometryType() != QGis::Point );
mMinSizeSpinBox->setEnabled( layer->geometryType() != QGis::Point );

populateFieldNames();

Expand Down Expand Up @@ -266,7 +268,7 @@ void QgsLabelingGui::changeTextFont()

void QgsLabelingGui::updateFont( QFont font )
{
lblFontName->setText( QString( "%1, %2" ).arg( font.family() ).arg( font.pointSize() ) );
lblFontName->setText( QString( "%1, %2 %3" ).arg( font.family() ).arg( font.pointSize() ).arg( tr( "pt" ) ) );
lblFontPreview->setFont( font );

updatePreview();
Expand Down
8 changes: 4 additions & 4 deletions src/ui/qgslabelingguibase.ui
Expand Up @@ -77,7 +77,7 @@
<item>
<widget class="QStackedWidget" name="stackedPlacement">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="pagePoint">
<layout class="QVBoxLayout" name="verticalLayout_2">
Expand Down Expand Up @@ -182,7 +182,7 @@
<item>
<widget class="QStackedWidget" name="stackedOptions">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="pageOptionsPoint">
<layout class="QGridLayout" name="gridLayout_2">
Expand All @@ -199,7 +199,7 @@
<item row="0" column="1">
<widget class="QDoubleSpinBox" name="spinDistPoint">
<property name="decimals">
<number>0</number>
<number>2</number>
</property>
</widget>
</item>
Expand Down Expand Up @@ -305,7 +305,7 @@
<item>
<widget class="QDoubleSpinBox" name="spinDistLine">
<property name="decimals">
<number>0</number>
<number>2</number>
</property>
</widget>
</item>
Expand Down

0 comments on commit 5da64f2

Please sign in to comment.