How to change size (font) of numbers in a SpinBox (QtQuick.Controls 1.X)



  • Hello,

    I use a SpinBox from QtQuick.Controls 1.X and I need to change the height of the SpinBox
    However, it doesn't change the sizeof the numbers in the SpinBox and I would like to adjust these numbers to the size of the SpinBox

    Example :

    SpinBox {
        height: 200
       font : 50 //not working
         style: SpinBoxStyle{
                  font: 50 //Not working either
         }
    }
    

    How could I proceed ?



  • Hi,

    If you want to change the size of the numbers in the SpinBox , you need do like this:

    SpinBox {
    height: 200
    font.pixelSize:height
    }



  • Hello, it works great, thanks !


Log in to reply
 

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