MCPcopy Create free account
hub / github.com/KDE/labplot / columns

Method columns

src/frontend/datasources/ROOTOptionsWidget.cpp:178–195  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

176}
177
178QVector<QStringList> ROOTOptionsWidget::columns() const {
179 QVector<QStringList> cols;
180
181 // ui.twColumns->selectedItems() returns the items in the order of selection.
182 // Iterate through the tree to retain the displayed order.
183 for (int t = 0; t < ui.twColumns->topLevelItemCount(); ++t) {
184 auto titem = ui.twColumns->topLevelItem(t);
185 if (titem->isSelected())
186 cols << titem->data(0, Qt::UserRole).toStringList();
187 for (int c = 0; c < titem->childCount(); ++c) {
188 auto citem = titem->child(c);
189 if (citem->isSelected())
190 cols << citem->data(0, Qt::UserRole).toStringList();
191 }
192 }
193
194 return cols;
195}
196
197void ROOTOptionsWidget::setNRows(int nrows) {
198 // try to retain the range settings:

Callers 1

currentFileFilterMethod · 0.45

Calls 4

isSelectedMethod · 0.45
dataMethod · 0.45
childCountMethod · 0.45
childMethod · 0.45

Tested by

no test coverage detected