Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[hig] Capitalization, improve dialog titles
(cherry picked from commit baf2a0f)
  • Loading branch information
nyalldawson committed Nov 29, 2018
1 parent 65c26d8 commit f34ddaf
Show file tree
Hide file tree
Showing 8 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/app/layout/qgslayoutlegendwidget.cpp
Expand Up @@ -1106,7 +1106,7 @@ void QgsLayoutLegendWidget::mItemTreeView_doubleClicked( const QModelIndex &idx
}

bool ok;
QString newText = QInputDialog::getText( this, tr( "Legend item properties" ), tr( "Item text" ),
QString newText = QInputDialog::getText( this, tr( "Legend Item Properties" ), tr( "Item text" ),
QLineEdit::Normal, currentText, &ok );
if ( !ok || newText == currentText )
return;
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgisapp.cpp
Expand Up @@ -8811,7 +8811,7 @@ QgsVectorLayer *QgisApp::pasteAsNewMemoryVector( const QString &layerName )
{
bool ok;
QString defaultName = tr( "Pasted" );
layerNameCopy = QInputDialog::getText( this, tr( "New temporary scratch layer name" ),
layerNameCopy = QInputDialog::getText( this, tr( "Paste as Scratch Layer" ),
tr( "Layer name" ), QLineEdit::Normal,
defaultName, &ok );
if ( !ok )
Expand Down
4 changes: 2 additions & 2 deletions src/app/qgsmaplayerstyleguiutils.cpp
Expand Up @@ -101,7 +101,7 @@ void QgsMapLayerStyleGuiUtils::addStyle()
return;

bool ok;
QString text = QInputDialog::getText( nullptr, tr( "New style" ),
QString text = QInputDialog::getText( nullptr, tr( "New Style" ),
tr( "Style name:" ), QLineEdit::Normal,
QStringLiteral( "new style" ), &ok );
if ( !ok || text.isEmpty() )
Expand Down Expand Up @@ -166,7 +166,7 @@ void QgsMapLayerStyleGuiUtils::renameStyle()
QString name = layer->styleManager()->currentStyle();

bool ok;
QString text = QInputDialog::getText( nullptr, tr( "Rename style" ),
QString text = QInputDialog::getText( nullptr, tr( "Rename Style" ),
tr( "Style name:" ), QLineEdit::Normal,
name, &ok );
if ( !ok )
Expand Down
2 changes: 1 addition & 1 deletion src/auth/oauth2/qgsauthoauth2method.cpp
Expand Up @@ -462,7 +462,7 @@ void QgsAuthOAuth2Method::onRefreshFinished( QNetworkReply::NetworkError err )
void QgsAuthOAuth2Method::onAuthCode()
{
bool ok = false;
QString code = QInputDialog::getText( QApplication::activeWindow(), QStringLiteral( "Enter the authorization code" ), QStringLiteral( "Authoriation code" ), QLineEdit::Normal, QStringLiteral( "Required" ), &ok, Qt::Dialog, Qt::InputMethodHint::ImhNone );
QString code = QInputDialog::getText( QApplication::activeWindow(), QStringLiteral( "Authoriation Code" ), QStringLiteral( "Enter the authorization code" ), QLineEdit::Normal, QStringLiteral( "Required" ), &ok, Qt::Dialog, Qt::InputMethodHint::ImhNone );
if ( ok && !code.isEmpty() )
{
emit setAuthCode( code );
Expand Down
4 changes: 2 additions & 2 deletions src/gui/qgsexpressionbuilderwidget.cpp
Expand Up @@ -329,8 +329,8 @@ void QgsExpressionBuilderWidget::newFunctionFile( const QString &fileName )
void QgsExpressionBuilderWidget::btnNewFile_pressed()
{
bool ok;
QString text = QInputDialog::getText( this, tr( "Enter new file name" ),
tr( "File name:" ), QLineEdit::Normal,
QString text = QInputDialog::getText( this, tr( "New File" ),
tr( "New file name:" ), QLineEdit::Normal,
QString(), &ok );
if ( ok && !text.isEmpty() )
{
Expand Down
2 changes: 1 addition & 1 deletion src/gui/qgsmaplayerstylemanagerwidget.cpp
Expand Up @@ -139,7 +139,7 @@ void QgsMapLayerStyleManagerWidget::styleRenamed( const QString &oldname, const
void QgsMapLayerStyleManagerWidget::addStyle()
{
bool ok;
QString text = QInputDialog::getText( nullptr, tr( "New style" ),
QString text = QInputDialog::getText( nullptr, tr( "New Style" ),
tr( "Style name:" ), QLineEdit::Normal,
QStringLiteral( "new style" ), &ok );
if ( !ok || text.isEmpty() )
Expand Down
2 changes: 1 addition & 1 deletion src/providers/ogr/qgsogrdataitems.cpp
Expand Up @@ -490,7 +490,7 @@ bool QgsOgrDataCollectionItem::storeConnection( const QString &path, const QStri
while ( ok && ! QgsOgrDbConnection( connName, ogrDriverName ).path( ).isEmpty( ) )
{

connName = QInputDialog::getText( nullptr, tr( "Cannot add connection '%1'" ).arg( connName ),
connName = QInputDialog::getText( nullptr, tr( "Add Connection" ),
tr( "A connection with the same name already exists,\nplease provide a new name:" ), QLineEdit::Normal,
QString(), &ok );
}
Expand Down
2 changes: 1 addition & 1 deletion src/providers/spatialite/qgsspatialitesourceselect.cpp
Expand Up @@ -296,7 +296,7 @@ bool QgsSpatiaLiteSourceSelect::newConnection( QWidget *parent )
while ( ! settings.value( baseKey + savedName + "/sqlitepath", "" ).toString().isEmpty() )
{
bool ok;
savedName = QInputDialog::getText( nullptr, tr( "Cannot add connection '%1'" ).arg( myName ),
savedName = QInputDialog::getText( nullptr, tr( "Add Connection" ),
tr( "A connection with the same name already exists,\nplease provide a new name:" ), QLineEdit::Normal,
QString(), &ok );
if ( !ok || savedName.isEmpty() )
Expand Down

0 comments on commit f34ddaf

Please sign in to comment.