void TableView::removeRow(const QModelIndex &index){ beginRemoveRows(index, index.row(), index.row()); m_rows.erase(index.row()); qDebug() << "remove"; endRemoveRows(); emit layoutChanged();}
QVariant TableView::data(const QModelIndex& index, int role) const{ if(role == Qt::DisplayRole && !m_rows.empty()) { return (m_rows.at(index.row()))[index.column()].c_str(); } return QVariant::Invalid;}