BarSet QML Type

Represents one set of bars in a bar chart. 更多...

导入语句: import QtCharts .
Since: Qt Quick Ultralite 1.1



A bar set contains one data value for each category. The first value of a set is assumed to belong to the first category, the second one to the second category, and so on. If the set has fewer values than the no. of categories, the missing values are assumed to be located at the end of the set.

The BarSet type is based on QtCharts .BarSet. The following members are not supported yet:

  • values (see below)
  • count
  • label, labelFont, labelColor
  • brushFilename
  • borderColor, borderWidth
  • all signals and methods

Although the values property is not supported, you can add values to the BarSet using the BarSetValue 类型:

ChartView {
    BarSeries {
        BarSet {
            BarSetValue { value: 7 }
            BarSetValue { value: 2 }
            BarSetValue { value: 6 }

另请参阅 AbstractBarSeries and BarSeries .


color : color

The fill color of the bar set.