Qt Charts C++ 類

用於 Qt Charts API 的 C++ 類。 更多...

QAreaSeries 在區域圖錶中呈現數據
QBarCategoryAxis 將類彆添加到圖錶軸
QCategoryAxis Places named ranges on the axis
QDateTimeAxis Adds dates and times to a chart's axis
QLogValueAxis Adds a logarithmic scale to a chart's axis
QAbstractAxis 用於專用軸類的基類
QValueAxis 將值添加到圖錶軸
QHorizontalBarSeries Presents a series of data as horizontal bars grouped by category
QHorizontalPercentBarSeries Presents a series of categorized data as a percentage of each category
QHorizontalStackedBarSeries Presents a series of data as horizontally stacked bars, with one bar per category
QAbstractBarSeries 用於所有條形係列類的抽象父級類
QBarSet 錶示條形圖錶中的一組條形
QHBarModelMapper Horizontal model mapper for bar series
QVBarModelMapper Vertical model mapper for bar series
QBarSeries 將一係列數據按類彆分組呈現為垂直條形
QPercentBarSeries Presents a series of categorized data as a percentage of each category
QStackedBarSeries Presents a series of data as vertically stacked bars, with one bar per category
QBoxPlotSeries Presents data in box-and-whiskers charts
QBoxSet Represents one item in a box-and-whiskers chart
QHBoxPlotModelMapper Horizontal model mapper for box plot series
QVBoxPlotModelMapper Vertical model mapper for box plot series
QCandlestickModelMapper Abstract model mapper class for candlestick series
QCandlestickSeries Presents data as candlesticks
QCandlestickSet Represents a single candlestick item in a candlestick chart
QHCandlestickModelMapper Horizontal model mapper for a candlestick series
QVCandlestickModelMapper Vertical model mapper for a candlestick series
QAreaLegendMarker Legend marker for an area series
QBarLegendMarker Legend marker for a bar series
QBoxPlotLegendMarker Legend marker for a box plot series
QCandlestickLegendMarker Legend marker for a candlestick series
QLegend 顯示圖錶的圖例
QLegendMarker Abstract object that can be used to access markers within a legend
QPieLegendMarker Legend marker for a pie series
QXYLegendMarker Legend marker for a line, spline, or scatter series
QLineSeries 以綫圖錶形式呈現數據
QHPieModelMapper Horizontal model mapper for pie series
QPieSeries Presents data in pie charts
QPieSlice Represents a single slice in a pie series
QVPieModelMapper Vertical model mapper for pie series
QAbstractSeries 用於所有 Qt Chart 係列的基類
QChart 管理圖錶的係列、圖例和軸的圖形錶示
QChartView 可以顯示圖錶的獨立 Widget
QPolarChart Presents data in polar charts
QScatterSeries Presents data in scatter charts
QSplineSeries 以樣條綫圖錶形式呈現數據
QHXYModelMapper Horizontal model mapper for line, spline, and scatter series
QVXYModelMapper Vertical model mapper for line, spline, and scatter series
QXYSeries Base class for line, spline, and scatter series

詳細描述

Charts API 構建於 Qt 圖形視圖框架之上。Charts 可以顯示為 QGraphicsWidget 使用 QChart 類。不管怎樣,還有方便類 QChartView ,其是 QWidget 基於。這些使我們能夠快速將 Qt Charts 用作正常 Qt 小部件。

各圖錶類型的錶示通過 QAbstractSeries 派生類。要創建圖錶,用戶必須使用相關係列類的實例並將它添加到 QChart 實例。

QLineSeries* series = new QLineSeries();
series->add(0, 6);
series->add(2, 4);
...
chartView->chart()->addSeries(series);
chartView->chart()->createDefaultAxes();