Skip to content
Permalink
Browse files

Adjust colorramp height on HiDPI screens

  • Loading branch information
elpaso committed Dec 7, 2017
1 parent bac80aa commit 251b2aefdffa2cfe55280532c3b98b15b32b8c04
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/gui/qgscolorrampbutton.cpp
@@ -69,7 +69,8 @@ QSize QgsColorRampButton::sizeHint() const
#ifdef Q_OS_WIN
return QSize( 120, 22 );
#else
return QSize( 120, 28 );
// Adjust height for HiDPI screens
return QSize( 120, std::max( static_cast<int>( fontMetrics().height( ) * 1.4 ), 28 ) );
#endif
}

0 comments on commit 251b2ae

Please sign in to comment.
You can’t perform that action at this time.