Important: Please read the Qt Code of Conduct -

Resizing MenuBar by stylesheet

  • Hello everyone,

    i'm trying to resize and set background image, to my menuBar, background image is ok, but when i try resize the
    menuBar, the items render out of the mainwindow(screen included).

    ! error)!

    Is it possible resize the menu bar ? Or am i doing something wrong?
    QMenuBar *myBar = menuBar();
    QMenuBar#menuBar {
    background: url(':/images/header.png') no-repeat;
    width: 1024px;
    height: 40px;

    thx for answers

Log in to reply