mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Flip rotation spin box to QgsDoubleSpinBox
Fix some other small spin box related ux improvements (fix #11833)
This commit is contained in:
parent
714a1e6835
commit
21c4cbbe1a
@ -1759,11 +1759,14 @@ void QgisApp::createStatusBar()
|
||||
mRotationLabel->setToolTip( tr( "Current clockwise map rotation in degrees" ) );
|
||||
statusBar()->addPermanentWidget( mRotationLabel, 0 );
|
||||
|
||||
mRotationEdit = new QSpinBox( statusBar() );
|
||||
mRotationEdit = new QgsDoubleSpinBox( statusBar() );
|
||||
mRotationEdit->setObjectName( "mRotationEdit" );
|
||||
mRotationEdit->setMaximumWidth( 100 );
|
||||
mRotationEdit->setClearValue( 0.0 );
|
||||
mRotationEdit->setKeyboardTracking( false );
|
||||
mRotationEdit->setMaximumWidth( 120 );
|
||||
mRotationEdit->setDecimals( 1 );
|
||||
mRotationEdit->setMaximumHeight( 20 );
|
||||
mRotationEdit->setRange( -180, 180 );
|
||||
mRotationEdit->setRange( -180.0, 180.0 );
|
||||
mRotationEdit->setWrapping( true );
|
||||
mRotationEdit->setSingleStep( 5.0 );
|
||||
mRotationEdit->setFont( myFont );
|
||||
@ -1772,7 +1775,7 @@ void QgisApp::createStatusBar()
|
||||
"the rotation" ) );
|
||||
mRotationEdit->setToolTip( tr( "Current clockwise map rotation in degrees" ) );
|
||||
statusBar()->addPermanentWidget( mRotationEdit, 0 );
|
||||
connect( mRotationEdit, SIGNAL( valueChanged( int ) ), this, SLOT( userRotation() ) );
|
||||
connect( mRotationEdit, SIGNAL( valueChanged( double ) ), this, SLOT( userRotation() ) );
|
||||
|
||||
showRotation();
|
||||
|
||||
|
@ -62,6 +62,7 @@ class QgsRectangle;
|
||||
class QgsUndoWidget;
|
||||
class QgsVectorLayer;
|
||||
class QgsVectorLayerTools;
|
||||
class QgsDoubleSpinBox;
|
||||
|
||||
class QDomDocument;
|
||||
class QNetworkReply;
|
||||
@ -1446,7 +1447,7 @@ class APP_EXPORT QgisApp : public QMainWindow, private Ui::MainWindow
|
||||
//! Widget that will live on the statusbar to display "Rotation"
|
||||
QLabel * mRotationLabel;
|
||||
//! Widget that will live in the statusbar to display and edit rotation
|
||||
QSpinBox * mRotationEdit;
|
||||
QgsDoubleSpinBox * mRotationEdit;
|
||||
//! The validator for the mCoordsEdit
|
||||
QValidator * mRotationEditValidator;
|
||||
//! Widget that will live in the statusbar to show progress of operations
|
||||
|
Loading…
x
Reference in New Issue
Block a user