Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Make locator bar shortcut hint show Cmd-K on MacOS (#4583)
  • Loading branch information
timlinux authored and nyalldawson committed May 18, 2017
1 parent 8997231 commit 43a0938
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/gui/locator/qgslocatorwidget.cpp
Expand Up @@ -34,7 +34,11 @@ QgsLocatorWidget::QgsLocatorWidget( QWidget *parent )
, mResultsView( new QgsLocatorResultsView( this ) )
{
mLineEdit->setShowClearButton( true );
#ifdef Q_OS_MACX
mLineEdit->setPlaceholderText( trUtf8( "Type to locate (⌘K)" ) );
#elif
mLineEdit->setPlaceholderText( tr( "Type to locate (Ctrl+K)" ) );
#endif

int placeholderMinWidth = mLineEdit->fontMetrics().width( mLineEdit->placeholderText() );
int minWidth = qMax( 200, ( int )( placeholderMinWidth * 1.3 ) );
Expand Down

0 comments on commit 43a0938

Please sign in to comment.