Print metadata and v2svk header

This commit is contained in:
Michael Mandl 2018-11-26 21:47:42 +01:00
parent 458de36cbc
commit bf963adeb5
7 changed files with 88 additions and 21 deletions

View file

@ -199,3 +199,15 @@ void V2SvkModel::read(const ESGRAF48::V2SvkModel &model)
emit dataChanged(index(0, 0), index(rowCount() - 1, columnCount() - 1));
}
void V2SvkModel::printTo(QTextCursor &cursor) const
{
cursor.insertBlock();
QTextCharFormat headerFormat;
headerFormat.setFontPointSize(12);
cursor.insertText("Subtest 1: Verbzweitstellungsregel (V2) und Subjekt-Verb-Kontrollregel (SVK)", headerFormat);
cursor.movePosition(QTextCursor::NextBlock);
}

View file

@ -3,6 +3,8 @@
#include "CheckableTestModel.h"
#include "V2SvkModel.pb.h"
#include <QTextCursor>
class V2SvkModel : public CheckableTestModel
{
Q_OBJECT
@ -16,6 +18,8 @@ public:
void write(ESGRAF48::V2SvkModel &model) const;
void read(const ESGRAF48::V2SvkModel &model);
void printTo(QTextCursor &cursor) const;
protected:
bool isValidIndex(const QModelIndex &index) const override;
};