diff --git a/src/barchart/qbarmodelmapper.cpp b/src/barchart/qbarmodelmapper.cpp index dd4de7a..ac3aa43 100644 --- a/src/barchart/qbarmodelmapper.cpp +++ b/src/barchart/qbarmodelmapper.cpp @@ -39,12 +39,6 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE Adding/removing value from the BarSet causes the the same change in the rest of the BarSets added to the same series. NOTE: used model has to support adding/removing rows/columns and modifying the data of the cells. */ -/*! - \qmlclass BarModelMapper - Cannot be created by the user. Base for HBarModelMapper and VBarModelMapper. Model mappers allow you to use - QAbstractItemModel derived models as a data source for a chart series. Adding/removing value from the BarSet causes - the the same change in the rest of the BarSets added to the same series. -*/ /*! \property QBarModelMapper::series @@ -52,23 +46,11 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE All the data in the series is discarded when it is set to the mapper. When new series is specified the old series is disconnected (it preserves its data) */ -/*! - \qmlproperty BarSeries BarModelMapper::series - Defines the BarSeries based object that is used by the mapper. All the data in the series is - discarded when it is set to the mapper. When new series is specified the old series is - disconnected (it preserves its data). -*/ /*! \property QBarModelMapper::model \brief Defines the model that is used by the mapper. */ -/*! - \qmlproperty Model BarModelMapper::model - The QAbstractItemModel based model that is used by the mapper. You need to implement the model and expose it to - QML as shown in \l {QML Custom Model} demo application. NOTE: the model has to support adding/removing rows/columns - and modifying the data of the cells. -*/ /*! \fn void QBarModelMapper::seriesReplaced() diff --git a/src/barchart/qhbarmodelmapper.cpp b/src/barchart/qhbarmodelmapper.cpp index 65d7951..36b301a 100644 --- a/src/barchart/qhbarmodelmapper.cpp +++ b/src/barchart/qhbarmodelmapper.cpp @@ -34,18 +34,18 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE NOTE: used model has to support adding/removing rows/columns and modifying the data of the cells. */ /*! - \qmlclass HBarModelMapper - \inherits BarModelMapper + \qmlclass HBarModelMapper QHBarModelMapper \mainclass HBarModelMapper allows you to use your own QAbstractItemModel derived model with data in rows as a data source - for any bar series. The following QML example would create a bar series with three bar sets (assuming the model has - at least four rows). Each bar set would contain data starting from column 1. The name of a set would be defined - by the vertical header (of the row). + for any bar series. Adding/removing value from the BarSet causes the the same change in the rest of the BarSets + added to the same series. The following QML example would create a bar series with three bar sets (assuming the + model has at least four rows). Each bar set would contain data starting from column 1. The name of a set would be + defined by the vertical header (of the row). \code BarSeries { HBarModelMapper { - model: myCustomModel + model: myCustomModel // QAbstractItemModel derived implementation firstBarSetRow: 1 lastBarSetRow: 3 firstColumn: 1 @@ -55,18 +55,39 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE */ /*! + \qmlproperty BarSeries HBarModelMapper::series + Defines the BarSeries based object that is used by the mapper. All the data in the series is discarded when it is + set to the mapper. When new series is specified the old series is disconnected (it preserves its data). +*/ + +/*! + \qmlproperty Model HBarModelMapper::model + The QAbstractItemModel based model that is used by the mapper. You need to implement the model and expose it to + QML as shown in \l {QML Custom Model} demo application. NOTE: the model has to support adding/removing rows/columns + and modifying the data of the cells. +*/ + +/*! \property QHBarModelMapper::firstBarSetRow \brief Defines which column of the model is used as the data source for the first bar set - Default value is: -1 (invalid mapping) */ +/*! + \qmlproperty int HBarModelMapper::firstBarSetRow + Defines which column of the model is used as the data source for the first bar set. The default value is -1 + (invalid mapping). +*/ /*! \property QHBarModelMapper::lastBarSetRow \brief Defines which column of the model is used as the data source for the last bar set - Default value is: -1 (invalid mapping) */ +/*! + \qmlproperty int HBarModelMapper::lastBarSetRow + Defines which column of the model is used as the data source for the last bar set. The default value is -1 + (invalid mapping). +*/ /*! \property QHBarModelMapper::firstColumn @@ -74,20 +95,20 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE Minimal and default value is: 0 */ /*! - \qmlproperty int BarModelMapper::firstColumn + \qmlproperty int HBarModelMapper::firstColumn Defines which column of the model contains the first values of the QBarSets in the series. The default value is 0. */ /*! \property QHBarModelMapper::columnCount - \brief Defines the number of rows of the model that are mapped as the data for QBarSeries - Minimal and default value is: -1 (count limited by the number of rows in the model) + \brief Defines the number of columns of the model that are mapped as the data for QBarSeries + Minimal and default value is: -1 (count limited by the number of columns in the model) */ /*! - \qmlproperty int BarModelMapper::columnCount - Defines the number of rows of the model that are mapped as the data for QBarSeries. The default value is - -1 (count limited by the number of rows in the model) + \qmlproperty int HBarModelMapper::columnCount + Defines the number of columns of the model that are mapped as the data for QBarSeries. The default value is + -1 (count limited by the number of columns in the model) */ /*! diff --git a/src/barchart/qvbarmodelmapper.cpp b/src/barchart/qvbarmodelmapper.cpp index 4ea2ac1..51c1acb 100644 --- a/src/barchart/qvbarmodelmapper.cpp +++ b/src/barchart/qvbarmodelmapper.cpp @@ -35,17 +35,17 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE */ /*! \qmlclass VBarModelMapper - \inherits BarModelMapper \mainclass VBarModelMapper allows you to use your own QAbstractItemModel derived model with data in columns as a data source - for any bar series. The following QML example would create a bar series with three bar sets (assuming the model has - at least four columns). Each bar set would contain data starting from row 1. The name of a set would be defined - by the horizontal header (of the column). + for any bar series. Adding/removing value from the BarSet causes the the same change in the rest of the BarSets + added to the same series. The following QML example would create a bar series with three bar sets (assuming the + model has at least four columns). Each bar set would contain data starting from row 1. The name of a set would be + defined by the horizontal header (of the column). \code GroupedBarSeries { VBarModelMapper { - model: myCustomModel + model: myCustomModel // QAbstractItemModel derived implementation firstBarSetColumn: 1 lastBarSetColumn: 3 firstRow: 1 @@ -55,6 +55,19 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE */ /*! + \qmlproperty BarSeries VBarModelMapper::series + Defines the BarSeries based object that is used by the mapper. All the data in the series is discarded when it is + set to the mapper. When new series is specified the old series is disconnected (it preserves its data). +*/ + +/*! + \qmlproperty Model VBarModelMapper::model + The QAbstractItemModel based model that is used by the mapper. You need to implement the model and expose it to + QML as shown in \l {QML Custom Model} demo application. NOTE: the model has to support adding/removing rows/columns + and modifying the data of the cells. +*/ + +/*! \property QVBarModelMapper::firstBarSetColumn \brief Defines which column of the model is used as the data source for the first bar set Default value is: -1 (invalid mapping) @@ -82,7 +95,7 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE Minimal and default value is: 0 */ /*! - \qmlproperty int BarModelMapper::firstRow + \qmlproperty int VBarModelMapper::firstRow Defines which row of the model contains the first values of the QBarSets in the series. The default value is 0. */ @@ -93,7 +106,7 @@ QTCOMMERCIALCHART_BEGIN_NAMESPACE Minimal and default value is: -1 (count limited by the number of rows in the model) */ /*! - \qmlproperty int BarModelMapper::rowCount + \qmlproperty int VBarModelMapper::rowCount Defines the number of rows of the model that are mapped as the data for QBarSeries. The default value is -1 (count limited by the number of rows in the model) */