Skip to content

Commit

Permalink
More capitalization
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed May 28, 2018
1 parent ec96956 commit dd2279c
Show file tree
Hide file tree
Showing 17 changed files with 50 additions and 50 deletions.
2 changes: 1 addition & 1 deletion src/app/layout/qgslayoutlegendwidget.cpp
Expand Up @@ -1125,7 +1125,7 @@ QMenu *QgsLayoutLegendMenuProvider::createContextMenu()

if ( QgsLayerTree::isLayer( mView->currentNode() ) )
{
menu->addAction( QObject::tr( "Reset to defaults" ), mWidget, SLOT( resetLayerNodeToDefaults() ) );
menu->addAction( QObject::tr( "Reset to Defaults" ), mWidget, SLOT( resetLayerNodeToDefaults() ) );
menu->addSeparator();
}

Expand Down
28 changes: 14 additions & 14 deletions src/app/qgsidentifyresultsdialog.cpp
Expand Up @@ -1065,19 +1065,19 @@ void QgsIdentifyResultsDialog::contextMenuEvent( QContextMenuEvent *event )
{
mActionPopup->addAction(
QgsApplication::getThemeIcon( QStringLiteral( "/mActionPropertyItem.svg" ) ),
vlayer->isEditable() ? tr( "Edit feature form" ) : tr( "View feature form" ),
vlayer->isEditable() ? tr( "Edit Feature Form…" ) : tr( "View Feature Form…" ),
this, SLOT( featureForm() ) );
}

if ( featItem->feature().isValid() )
{
mActionPopup->addAction( tr( "Zoom to feature" ), this, SLOT( zoomToFeature() ) );
mActionPopup->addAction( tr( "Copy feature" ), this, SLOT( copyFeature() ) );
mActionPopup->addAction( tr( "Toggle feature selection" ), this, SLOT( toggleFeatureSelection() ) );
mActionPopup->addAction( tr( "Zoom to Feature" ), this, SLOT( zoomToFeature() ) );
mActionPopup->addAction( tr( "Copy Feature" ), this, SLOT( copyFeature() ) );
mActionPopup->addAction( tr( "Toggle Feature Selection" ), this, SLOT( toggleFeatureSelection() ) );
}

mActionPopup->addAction( tr( "Copy attribute value" ), this, SLOT( copyAttributeValue() ) );
mActionPopup->addAction( tr( "Copy feature attributes" ), this, SLOT( copyFeatureAttributes() ) );
mActionPopup->addAction( tr( "Copy Attribute Value" ), this, SLOT( copyAttributeValue() ) );
mActionPopup->addAction( tr( "Copy Feature Attributes" ), this, SLOT( copyFeatureAttributes() ) );

if ( item->parent() == featItem && item->childCount() == 0 )
{
Expand All @@ -1098,18 +1098,18 @@ void QgsIdentifyResultsDialog::contextMenuEvent( QContextMenuEvent *event )
mActionPopup->addSeparator();
}

mActionPopup->addAction( tr( "Clear results" ), this, SLOT( clear() ) );
mActionPopup->addAction( tr( "Clear highlights" ), this, SLOT( clearHighlights() ) );
mActionPopup->addAction( tr( "Highlight all" ), this, SLOT( highlightAll() ) );
mActionPopup->addAction( tr( "Highlight layer" ), this, SLOT( highlightLayer() ) );
mActionPopup->addAction( tr( "Clear Results" ), this, SLOT( clear() ) );
mActionPopup->addAction( tr( "Clear Highlights" ), this, SLOT( clearHighlights() ) );
mActionPopup->addAction( tr( "Highlight All" ), this, SLOT( highlightAll() ) );
mActionPopup->addAction( tr( "Highlight Layer" ), this, SLOT( highlightLayer() ) );
if ( layer && QgsProject::instance()->layerIsEmbedded( layer->id() ).isEmpty() )
{
mActionPopup->addAction( tr( "Activate layer" ), this, SLOT( activateLayer() ) );
mActionPopup->addAction( tr( "Layer properties" ), this, SLOT( layerProperties() ) );
mActionPopup->addAction( tr( "Activate Layer" ), this, SLOT( activateLayer() ) );
mActionPopup->addAction( tr( "Layer Properties" ), this, SLOT( layerProperties() ) );
}
mActionPopup->addSeparator();
mActionPopup->addAction( tr( "Expand all" ), this, SLOT( expandAll() ) );
mActionPopup->addAction( tr( "Collapse all" ), this, SLOT( collapseAll() ) );
mActionPopup->addAction( tr( "Expand All" ), this, SLOT( expandAll() ) );
mActionPopup->addAction( tr( "Collapse All" ), this, SLOT( collapseAll() ) );
mActionPopup->addSeparator();

if ( featItem && vlayer )
Expand Down
12 changes: 6 additions & 6 deletions src/app/qgssnappingwidget.cpp
Expand Up @@ -101,10 +101,10 @@ QgsSnappingWidget::QgsSnappingWidget( QgsProject *project, QgsMapCanvas *canvas,
mModeButton = new QToolButton();
mModeButton->setToolTip( tr( "Snapping Mode" ) );
mModeButton->setPopupMode( QToolButton::InstantPopup );
QMenu *modeMenu = new QMenu( tr( "Set snapping mode" ), this );
mAllLayersAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingAllLayers.svg" ) ), tr( "All layers" ), modeMenu );
mActiveLayerAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingActiveLayer.svg" ) ), tr( "Active layer" ), modeMenu );
mAdvancedModeAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingAdvanced.svg" ) ), tr( "Advanced configuration" ), modeMenu );
QMenu *modeMenu = new QMenu( tr( "Set Snapping Mode" ), this );
mAllLayersAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingAllLayers.svg" ) ), tr( "All Layers" ), modeMenu );
mActiveLayerAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingActiveLayer.svg" ) ), tr( "Active Layer" ), modeMenu );
mAdvancedModeAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingAdvanced.svg" ) ), tr( "Advanced Configuration" ), modeMenu );
modeMenu->addAction( mAllLayersAction );
modeMenu->addAction( mActiveLayerAction );
modeMenu->addAction( mAdvancedModeAction );
Expand All @@ -127,9 +127,9 @@ QgsSnappingWidget::QgsSnappingWidget( QgsProject *project, QgsMapCanvas *canvas,
mTypeButton = new QToolButton();
mTypeButton->setToolTip( tr( "Snapping Type" ) );
mTypeButton->setPopupMode( QToolButton::InstantPopup );
QMenu *typeMenu = new QMenu( tr( "Set snapping mode" ), this );
QMenu *typeMenu = new QMenu( tr( "Set Snapping Mode" ), this );
mVertexAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingVertex.svg" ) ), tr( "Vertex" ), typeMenu );
mVertexAndSegmentAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingVertexAndSegment.svg" ) ), tr( "Vertex and segment" ), typeMenu );
mVertexAndSegmentAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingVertexAndSegment.svg" ) ), tr( "Vertex and Segment" ), typeMenu );
mSegmentAction = new QAction( QIcon( QgsApplication::getThemeIcon( "/mIconSnappingSegment.svg" ) ), tr( "Segment" ), typeMenu );
typeMenu->addAction( mVertexAction );
typeMenu->addAction( mVertexAndSegmentAction );
Expand Down
6 changes: 3 additions & 3 deletions src/app/qgsvectorlayerproperties.cpp
Expand Up @@ -190,8 +190,8 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
{
//for loading
mLoadStyleMenu = new QMenu( this );
mLoadStyleMenu->addAction( tr( "Load from file" ) );
mLoadStyleMenu->addAction( tr( "Database styles manager" ) );
mLoadStyleMenu->addAction( tr( "Load from File" ) );
mLoadStyleMenu->addAction( tr( "Database Styles Manager…" ) );
//mActionLoadStyle->setContextMenuPolicy( Qt::PreventContextMenu );
mActionLoadStyle->setMenu( mLoadStyleMenu );

Expand All @@ -206,7 +206,7 @@ QgsVectorLayerProperties::QgsVectorLayerProperties(
if ( providerName == QLatin1String( "GPKG" ) )
providerName = QStringLiteral( "GeoPackage" );
}
mSaveAsMenu->addAction( tr( "Save in database (%1)" ).arg( providerName ) );
mSaveAsMenu->addAction( tr( "Save in Database (%1)" ).arg( providerName ) );
}

connect( mSaveAsMenu, &QMenu::triggered,
Expand Down
6 changes: 3 additions & 3 deletions src/gui/editorwidgets/qgsmultiedittoolbutton.cpp
Expand Up @@ -43,21 +43,21 @@ void QgsMultiEditToolButton::aboutToShowMenu()
{
case Default:
{
QAction *noAction = mMenu->addAction( tr( "No changes to commit" ) );
QAction *noAction = mMenu->addAction( tr( "No Changes to Commit" ) );
noAction->setEnabled( false );
break;
}
case MixedValues:
{
QString title = !mField.name().isEmpty() ? tr( "Set %1 for all selected features" ).arg( mField.name() )
QString title = !mField.name().isEmpty() ? tr( "Set %1 for All Selected Features" ).arg( mField.name() )
: tr( "Set field for all selected features" );
QAction *setFieldAction = mMenu->addAction( title );
connect( setFieldAction, &QAction::triggered, this, &QgsMultiEditToolButton::setFieldTriggered );
break;
}
case Changed:
{
QAction *resetFieldAction = mMenu->addAction( tr( "Reset to original values" ) );
QAction *resetFieldAction = mMenu->addAction( tr( "Reset to Original Values" ) );
connect( resetFieldAction, &QAction::triggered, this, &QgsMultiEditToolButton::resetFieldTriggered );
break;
}
Expand Down
2 changes: 1 addition & 1 deletion src/gui/editorwidgets/qgssearchwidgettoolbutton.cpp
Expand Up @@ -144,7 +144,7 @@ void QgsSearchWidgetToolButton::aboutToShowMenu()
}
}

QAction *clearAction = mMenu->addAction( tr( "Exclude field" ) );
QAction *clearAction = mMenu->addAction( tr( "Exclude Field" ) );
connect( clearAction, &QAction::triggered, this, &QgsSearchWidgetToolButton::setInactive );
clearAction->setCheckable( true );
clearAction->setChecked( !fieldActive );
Expand Down
4 changes: 2 additions & 2 deletions src/gui/qgscheckablecombobox.cpp
Expand Up @@ -85,8 +85,8 @@ QgsCheckableComboBox::QgsCheckableComboBox( QWidget *parent )
setLineEdit( lineEdit );

mContextMenu = new QMenu( this );
mSelectAllAction = mContextMenu->addAction( tr( "Select all" ) );
mDeselectAllAction = mContextMenu->addAction( tr( "Deselect all" ) );
mSelectAllAction = mContextMenu->addAction( tr( "Select All" ) );
mDeselectAllAction = mContextMenu->addAction( tr( "Deselect All" ) );
connect( mSelectAllAction, &QAction::triggered, this, &QgsCheckableComboBox::selectAllOptions );
connect( mDeselectAllAction, &QAction::triggered, this, &QgsCheckableComboBox::deselectAllOptions );

Expand Down
4 changes: 2 additions & 2 deletions src/gui/qgsexpressionbuilderwidget.cpp
Expand Up @@ -967,8 +967,8 @@ void QgsExpressionBuilderWidget::showContextMenu( QPoint pt )
if ( item->getItemType() == QgsExpressionItem::Field && mLayer )
{
QMenu *menu = new QMenu( this );
menu->addAction( tr( "Load top 10 unique values" ), this, SLOT( loadSampleValues() ) );
menu->addAction( tr( "Load all unique values" ), this, SLOT( loadAllValues() ) );
menu->addAction( tr( "Load First 10 Unique Values" ), this, SLOT( loadSampleValues() ) );
menu->addAction( tr( "Load All Unique Values" ), this, SLOT( loadAllValues() ) );
menu->popup( expressionTree->mapToGlobal( pt ) );
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/gui/qgsfontbutton.cpp
Expand Up @@ -540,7 +540,7 @@ void QgsFontButton::prepareMenu()
sizeWidget->setFocusPolicy( Qt::StrongFocus );
mMenu->addAction( sizeAction );

QMenu *recentFontMenu = new QMenu( tr( "Recent fonts" ), mMenu );
QMenu *recentFontMenu = new QMenu( tr( "Recent Fonts" ), mMenu );
Q_FOREACH ( const QString &family, QgsFontUtils::recentFontFamilies() )
{
QAction *fontAction = new QAction( family, recentFontMenu );
Expand Down
2 changes: 1 addition & 1 deletion src/gui/qgspropertyoverridebutton.cpp
Expand Up @@ -368,7 +368,7 @@ void QgsPropertyOverrideButton::aboutToShowMenu()
bool fieldActive = false;
if ( !mDataTypesString.isEmpty() )
{
QAction *fieldTitleAct = mDefineMenu->addAction( tr( "Attribute field" ) );
QAction *fieldTitleAct = mDefineMenu->addAction( tr( "Attribute Field" ) );
fieldTitleAct->setFont( titlefont );
fieldTitleAct->setEnabled( false );

Expand Down
4 changes: 2 additions & 2 deletions src/gui/qgsrelationeditorwidget.cpp
Expand Up @@ -688,10 +688,10 @@ void QgsRelationEditorWidget::showContextMenu( QgsActionMenu *menu, const QgsFea
{
QAction *qAction = nullptr;

qAction = menu->addAction( QgsApplication::getThemeIcon( QStringLiteral( "/mActionDeleteSelected.svg" ) ), tr( "Delete feature" ) );
qAction = menu->addAction( QgsApplication::getThemeIcon( QStringLiteral( "/mActionDeleteSelected.svg" ) ), tr( "Delete Feature" ) );
connect( qAction, &QAction::triggered, this, [this, fid]() { deleteFeature( fid ); } );

qAction = menu->addAction( QgsApplication::getThemeIcon( QStringLiteral( "/mActionUnlink.svg" ) ), tr( "Unlink feature" ) );
qAction = menu->addAction( QgsApplication::getThemeIcon( QStringLiteral( "/mActionUnlink.svg" ) ), tr( "Unlink Feature" ) );
connect( qAction, &QAction::triggered, this, [this, fid]() { unlinkFeature( fid ); } );
}
}
2 changes: 1 addition & 1 deletion src/gui/raster/qgspalettedrendererwidget.cpp
Expand Up @@ -45,7 +45,7 @@ QgsPalettedRendererWidget::QgsPalettedRendererWidget( QgsRasterLayer *layer, con
mContextMenu->addAction( tr( "Change Opacity…" ), this, SLOT( changeOpacity() ) );
mContextMenu->addAction( tr( "Change Label…" ), this, SLOT( changeLabel() ) );

mAdvancedMenu = new QMenu( tr( "Advanced options" ), this );
mAdvancedMenu = new QMenu( tr( "Advanced Options" ), this );
QAction *mLoadFromLayerAction = mAdvancedMenu->addAction( tr( "Load Classes from Layer" ) );
connect( mLoadFromLayerAction, &QAction::triggered, this, &QgsPalettedRendererWidget::loadFromLayer );
QAction *loadFromFile = mAdvancedMenu->addAction( tr( "Load Color Map from File…" ) );
Expand Down
8 changes: 4 additions & 4 deletions src/gui/symbology/qgscategorizedsymbolrendererwidget.cpp
Expand Up @@ -463,12 +463,12 @@ QgsCategorizedSymbolRendererWidget::QgsCategorizedSymbolRendererWidget( QgsVecto
// menus for data-defined rotation/size
QMenu *advMenu = new QMenu;

advMenu->addAction( tr( "Match to saved symbols" ), this, SLOT( matchToSymbolsFromLibrary() ) );
advMenu->addAction( tr( "Match to symbols from file" ), this, SLOT( matchToSymbolsFromXml() ) );
advMenu->addAction( tr( "Symbol levels" ), this, SLOT( showSymbolLevels() ) );
advMenu->addAction( tr( "Match to Saved Symbols" ), this, SLOT( matchToSymbolsFromLibrary() ) );
advMenu->addAction( tr( "Match to Symbols from File" ), this, SLOT( matchToSymbolsFromXml() ) );
advMenu->addAction( tr( "Symbol Levels" ), this, SLOT( showSymbolLevels() ) );
if ( mCategorizedSymbol->type() == QgsSymbol::Marker )
{
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined size legend" ) );
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined Size Legend" ) );
// only from Qt 5.6 there is convenience addAction() with new style connection
connect( actionDdsLegend, &QAction::triggered, this, &QgsCategorizedSymbolRendererWidget::dataDefinedSizeLegend );
}
Expand Down
4 changes: 2 additions & 2 deletions src/gui/symbology/qgsgraduatedsymbolrendererwidget.cpp
Expand Up @@ -524,10 +524,10 @@ QgsGraduatedSymbolRendererWidget::QgsGraduatedSymbolRendererWidget( QgsVectorLay
// menus for data-defined rotation/size
QMenu *advMenu = new QMenu( this );

advMenu->addAction( tr( "Symbol levels" ), this, SLOT( showSymbolLevels() ) );
advMenu->addAction( tr( "Symbol Levels" ), this, SLOT( showSymbolLevels() ) );
if ( mGraduatedSymbol->type() == QgsSymbol::Marker )
{
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined size legend" ) );
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined Size Legend" ) );
// only from Qt 5.6 there is convenience addAction() with new style connection
connect( actionDdsLegend, &QAction::triggered, this, &QgsGraduatedSymbolRendererWidget::dataDefinedSizeLegend );
}
Expand Down
8 changes: 4 additions & 4 deletions src/gui/symbology/qgsrulebasedrendererwidget.cpp
Expand Up @@ -84,10 +84,10 @@ QgsRuleBasedRendererWidget::QgsRuleBasedRendererWidget( QgsVectorLayer *layer, Q
viewRules->addAction( mCopyAction );
viewRules->addAction( mPasteAction );

mRefineMenu = new QMenu( tr( "Refine current rule" ), btnRefineRule );
mRefineMenu->addAction( tr( "Add scales to rule" ), this, SLOT( refineRuleScales() ) );
mRefineMenu->addAction( tr( "Add categories to rule" ), this, SLOT( refineRuleCategories() ) );
mRefineMenu->addAction( tr( "Add ranges to rule" ), this, SLOT( refineRuleRanges() ) );
mRefineMenu = new QMenu( tr( "Refine Current Rule" ), btnRefineRule );
mRefineMenu->addAction( tr( "Add Scales to Rule" ), this, SLOT( refineRuleScales() ) );
mRefineMenu->addAction( tr( "Add Categories to Rule" ), this, SLOT( refineRuleCategories() ) );
mRefineMenu->addAction( tr( "Add Ranges to Rule" ), this, SLOT( refineRuleRanges() ) );
btnRefineRule->setMenu( mRefineMenu );
contextMenu->addMenu( mRefineMenu );

Expand Down
4 changes: 2 additions & 2 deletions src/gui/symbology/qgssinglesymbolrendererwidget.cpp
Expand Up @@ -65,11 +65,11 @@ QgsSingleSymbolRendererWidget::QgsSingleSymbolRendererWidget( QgsVectorLayer *la
// advanced actions - data defined rendering
QMenu *advMenu = mSelector->advancedMenu();

QAction *actionLevels = advMenu->addAction( tr( "Symbol levels" ) );
QAction *actionLevels = advMenu->addAction( tr( "Symbol Levels" ) );
connect( actionLevels, &QAction::triggered, this, &QgsSingleSymbolRendererWidget::showSymbolLevels );
if ( mSingleSymbol->type() == QgsSymbol::Marker )
{
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined size legend" ) );
QAction *actionDdsLegend = advMenu->addAction( tr( "Data-defined Size Legend" ) );
// only from Qt 5.6 there is convenience addAction() with new style connection
connect( actionDdsLegend, &QAction::triggered, this, &QgsSingleSymbolRendererWidget::dataDefinedSizeLegend );
}
Expand Down
2 changes: 1 addition & 1 deletion src/gui/symbology/qgsstylemanagerdialog.cpp
Expand Up @@ -124,7 +124,7 @@ QgsStyleManagerDialog::QgsStyleManagerDialog( QgsStyle *style, QWidget *parent )
connect( groupModel, &QStandardItemModel::itemChanged,
this, &QgsStyleManagerDialog::groupRenamed );

QMenu *groupMenu = new QMenu( tr( "Group actions" ), this );
QMenu *groupMenu = new QMenu( tr( "Group Actions" ), this );
connect( actnTagSymbols, &QAction::triggered, this, &QgsStyleManagerDialog::tagSymbolsAction );
groupMenu->addAction( actnTagSymbols );
connect( actnFinishTagging, &QAction::triggered, this, &QgsStyleManagerDialog::tagSymbolsAction );
Expand Down

0 comments on commit dd2279c

Please sign in to comment.