i want to change menu item's height,but the code didnot work.i don't know how to use PixelMetric.
int Mstyle
::pixelMetric(PixelMetric which,
const QStyleOption* option,
const QWidget * widget
) const {
switch(which)
{
case PM_MenuHMargin:
return 40;
case PM_MenuVMargin:
return 40;
default:
}
}
int Mstyle::pixelMetric(PixelMetric which, const QStyleOption* option, const QWidget * widget) const
{
switch(which)
{
case PM_MenuHMargin:
return 40;
case PM_MenuVMargin:
return 40;
default:
return QWindowsStyle::pixelMetric(which,option,widget);
}
}
To copy to clipboard, switch view to plain text mode
Bookmarks