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

BarSeries: Support drawing bars downwards to show negative values

XMLWordPrintable

    • d6192b1ae (dev)

      Code

      import QtQuick
      import QtGraphs
      
      Window {
          width: 800
          height: 600
          visible: true
          title: "Bars"
      
          GraphsView {
              anchors.fill: parent
      
              axisX: BarCategoryAxis {
                  titleText: "Year"
                  categories: [2023, 2024, 2025]
              }
              axisY: ValueAxis {
                  titleText: "Profits"
                  min: -60
                  max: 100
              }
      
              BarSeries {
                  BarSet {
                      label: "Dept. A"
                      values: [40, -20, 80]
                  }
                  BarSet {
                      label: "Dept. B"
                      values: [60, -40, 60]
                  }
              }
          }
      }
      

      Current Result

      Desired Result

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

            xavierbesson Xavier Besson
            skoh-qt Sze Howe Koh
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes