[Solved] How can I change wizard custom button font?



  • Hi,

    I'm making a wizard app. I want to change the size of the font of the wizard buttons (in that case: CustomButton1 and CustomButton2).

    The thing is that I can change the colour of the text and the background when it has the focus for example but not the size...O.o or put it in bold in normal way but it ignores totally the font size..

    I have this on the Wizard:
    @

    this->button(QWizard::CustomButton1)->setStyleSheet("QPushButton{background-color:#ff2255; font: 25 px; font-weight: bold;;} QPushButton:focus{background-color: #2266ff); color: white;}");

    @

    I tried with font: 30 px, font-size: 30 px; font-size: 200%

    Thank you!!



  • Found the solution. As simple as QApplication::setFont();


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.