mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Center menu titles, followup 09c2444
This commit is contained in:
parent
c93fdf9360
commit
74da2542b5
@ -10560,7 +10560,10 @@ QMenu* QgisApp::createPopupMenu()
|
|||||||
|
|
||||||
qSort( panels.begin(), panels.end(), cmpByText_ );
|
qSort( panels.begin(), panels.end(), cmpByText_ );
|
||||||
QWidgetAction* panelstitle = new QWidgetAction( menu );
|
QWidgetAction* panelstitle = new QWidgetAction( menu );
|
||||||
panelstitle->setDefaultWidget( new QLabel( QString( "<b>%1</b>" ).arg( tr( "Panels" ) ) ) );
|
QLabel* plabel = new QLabel( QString( "<b>%1</b>" ).arg( tr( "Panels" ) ) );
|
||||||
|
plabel->setMargin( 3 );
|
||||||
|
plabel->setAlignment( Qt::AlignHCenter );
|
||||||
|
panelstitle->setDefaultWidget( plabel );
|
||||||
menu->addAction( panelstitle );
|
menu->addAction( panelstitle );
|
||||||
foreach ( QAction* a, panels )
|
foreach ( QAction* a, panels )
|
||||||
{
|
{
|
||||||
@ -10568,7 +10571,10 @@ QMenu* QgisApp::createPopupMenu()
|
|||||||
}
|
}
|
||||||
menu->addSeparator();
|
menu->addSeparator();
|
||||||
QWidgetAction* toolbarstitle = new QWidgetAction( menu );
|
QWidgetAction* toolbarstitle = new QWidgetAction( menu );
|
||||||
toolbarstitle->setDefaultWidget( new QLabel( QString( "<b>%1</b>" ).arg( tr( "Toolbars" ) ) ) );
|
QLabel* tlabel = new QLabel( QString( "<b>%1</b>" ).arg( tr( "Toolbars" ) ) );
|
||||||
|
tlabel->setMargin( 3 );
|
||||||
|
tlabel->setAlignment( Qt::AlignHCenter );
|
||||||
|
toolbarstitle->setDefaultWidget( tlabel );
|
||||||
menu->addAction( toolbarstitle );
|
menu->addAction( toolbarstitle );
|
||||||
qSort( toolbars.begin(), toolbars.end(), cmpByText_ );
|
qSort( toolbars.begin(), toolbars.end(), cmpByText_ );
|
||||||
foreach ( QAction* a, toolbars )
|
foreach ( QAction* a, toolbars )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user