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

QColor::fromHsl changes the given saturation value

    XMLWordPrintable

Details

    • All

    Description

      If I create QColor from HSL values, created QColor has different saturation value than what was given as a parameter to QColor::fromHsl() function. It seems that saturation value is affected by lightness value also given as a parameter.

      If I use QColor::lighter() or darker() functions, it does not change the saturation because QColor is first converted to HSV and lightness is applied to (V)alue.

      If this is working as intended, would it be possible to explain this in the documentations?

      I have attached an example project to demonstrate this issue

      Attachments

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

        Activity

          People

            vgt Eirik Aavitsland
            pekarjal Pekka Karjalainen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes