##// END OF EJS Templates
Defines actions for a data source items...
Defines actions for a data source items DataSourceItemAction is an object that will be connected to a QAction. When the QAction will be triggered, the DataSourceItemAction will be executed

File last commit:

r126:2c63a29c9c11
r144:7a9a79ed3b02
Show More
ScalarSeries.cpp
13 lines | 422 B | text/x-c | CppLexer
/ core / src / Data / ScalarSeries.cpp
Alexandre Leroux
Creates scalar series
r126 #include <Data/ScalarSeries.h>
ScalarSeries::ScalarSeries(int size, const QString &xAxisUnit, const QString &valuesUnit)
: DataSeries{std::make_shared<ArrayData<1> >(size), xAxisUnit,
std::make_shared<ArrayData<1> >(size), valuesUnit}
{
}
void ScalarSeries::setData(int index, double x, double value) noexcept
{
xAxisData()->setData(index, x);
valuesData()->setData(index, value);
}