Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-31602

Broken QSpinBox size calculation - content text clipping occurs

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • P2: Important
    • Resolution: Done
    • 5.1.0 RC1
    • 5.2.0
    • Widgets: Style Sheets
    • None
    • Windows 7 64 Bit
    • afce2b528ce30e19af618b077e3f184cf290fa81

    Description

      Qt 5.1.0 RC1 has a serious bug that affects height calculation of QSpinBoxes if stylesheets are used. The attached image Qt5.1.0-rc1-20130606.png shows this issue (vertical size policy used for spin boxes in this gui: fixed) - the spin box height is too small for the content and text clipping occurs.

      The picture Qt5.0.2-20130606.png shows the same application compiled with Qt 5.0.2. Also with Qt 4.8.4 and older version this problem does not exist. So it is a new bug related to Qt 5.1.0 RC1.

      The last picture Qt5.10-rc1-20130606.png shows the application if the stylesheet file has been removed. The spin boxex look o.k. with the default Windows style - so the issue seems to be related to the stylesheet style.

      Other widgets, like i.e. QLineEdit to not show this issue so to summarize the issue is related to:

      • QSpinBox
      • stylesheet style
      • Qt 5.1.0 RC 1 (qt-windows-opensource-5.1.0-rc1-mingw48_opengl-x86-offline-2013-06-02-48.exe)

      The bug is quite serious because it affects all spin boxes in our application and makes Qt 5.1.0 unusable for us.

      Attachments

        1. metro.css
          46 kB
        2. QSpinBox_Button_Width.png
          QSpinBox_Button_Width.png
          4 kB
        3. QSpinBox_Sizes_01.png
          QSpinBox_Sizes_01.png
          38 kB
        4. QSpinBox_Sizes_02.png
          QSpinBox_Sizes_02.png
          62 kB
        5. QSpinBox_Sizes_20130704.jpg
          QSpinBox_Sizes_20130704.jpg
          96 kB
        6. QSpinBoxCSS.zip
          5 kB
        7. Qt5.0.2-20130606.png
          Qt5.0.2-20130606.png
          182 kB
        8. Qt5.1.0-rc1-20130606.png
          Qt5.1.0-rc1-20130606.png
          138 kB
        9. Qt5.1.0-rc1-20130606-no-stylesheet.png
          Qt5.1.0-rc1-20130606-no-stylesheet.png
          181 kB
        10. TestApp_Qt4.8.4.jpg
          TestApp_Qt4.8.4.jpg
          24 kB
        11. TestApp_Qt5.1.0.jpg
          TestApp_Qt5.1.0.jpg
          24 kB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              carochao Caroline Chao (Inactive)
              ukindler Uwe Kindler
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes