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

Bad QSlider behavior with large max on OS X

    XMLWordPrintable

Details

    • macOS

    Description

      QSlider on OS X with a huge maximum is buggy.

      The handle of the slider always stays stuck at the beginning with the following code :

      m_slider = new QSlider{Qt::Horizontal}}
      m_slider->setMinimum(0);
      m_slider->setMaximum(std::numeric_limits<int>::max());

      If I decrease the max, I can notice that the handle actually seems to loop at the very beginning of the range which makes me thinks of some kind of integer overflowing.

      It is visible for instance from std::numeric_limits<int>::max() / 32 to std::numeric_limits<int>::max() / 8192 on big sliders.

      I attached a video of what I am seeing.

      Attachments

        1. Enregistrement de l’écran.mov
          938 kB
          Jean-Michaël Celerier

        Activity

          People

            sorvig Morten Sørvig
            jcelerier Jean-Michaël Celerier
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: