Removed html output
This commit is contained in:
parent
bf08d0c5e4
commit
bcd0b17caa
@ -72,29 +72,6 @@ void DataModel::printTo(QTextCursor &cursor) const
|
||||
m_v2Svk.printTo(cursor);
|
||||
}
|
||||
|
||||
std::string DataModel::toHtml() const
|
||||
{
|
||||
std::stringstream out;
|
||||
|
||||
out << "<html>" << std::endl;
|
||||
out << "<head>" << std::endl;
|
||||
out << "<style>" << std::endl;
|
||||
out << "body {" << std::endl;
|
||||
out << "font-family:sans-serif;" << std::endl;
|
||||
out << "}" << std::endl;
|
||||
out << "</style>" << std::endl;
|
||||
out << "</head>" << std::endl;
|
||||
out << "<body>" << std::endl;
|
||||
out << "<h2>ESGRAF 4-8 Auswertungsbogen</h2>" << std::endl;
|
||||
out << "<p>" << std::endl;
|
||||
out << m_metaData.toHtml();
|
||||
out << "</p>" << std::endl;
|
||||
out << "</body>" << std::endl;
|
||||
out << "</html>" << std::endl;
|
||||
|
||||
return out.str();
|
||||
}
|
||||
|
||||
void DataModel::pluralModelChanged()
|
||||
{
|
||||
m_results.setPluralResult(m_plural.getPoints());
|
||||
|
@ -36,7 +36,6 @@ public:
|
||||
DataModel(QObject *parent);
|
||||
|
||||
void printTo(QTextCursor &cursor) const;
|
||||
std::string toHtml() const;
|
||||
|
||||
void write(std::ostream &outStream) const;
|
||||
void read(std::istream &inStream);
|
||||
|
@ -178,27 +178,3 @@ void MetaDataModel::printTo(QTextCursor &cursor) const
|
||||
cursor.movePosition(QTextCursor::NextBlock);
|
||||
}
|
||||
|
||||
std::string MetaDataModel::toHtml() const
|
||||
{
|
||||
std::ostringstream out;
|
||||
|
||||
out << "<table border=\"1\" cellspacing=\"0\" cellpadding=\"2\" frame=\"box\" rules=\"all\">" << std::endl;
|
||||
out << "<tr>" << std::endl;
|
||||
out << "<td colspan=\"2\">Bemerkungen</td>" << std::endl;
|
||||
out << "</tr>" << std::endl;
|
||||
out << "<tr>" << std::endl;
|
||||
out << "<td>Untersuchungsdatum</td>" << std::endl;
|
||||
out << "<td>" << m_dateOfTest.toString("dd.MM.yyyy").toHtmlEscaped().toStdString() << "</td>"
|
||||
<< std::endl;
|
||||
out << "<td colspan=\"2\" rowspan=\"2\">"
|
||||
<< m_remarks.trimmed().toHtmlEscaped().replace("\n", "<br>").toStdString() << "</td>"
|
||||
<< std::endl;
|
||||
out << "</tr>" << std::endl;
|
||||
out << "<tr>" << std::endl;
|
||||
out << "<td>Alter am Testtag</td>" << std::endl;
|
||||
out << "<td>" << getAge().toString() << "</td>" << std::endl;
|
||||
out << "</tr>" << std::endl;
|
||||
out << "</table>" << std::endl;
|
||||
|
||||
return out.str();
|
||||
}
|
||||
|
@ -35,7 +35,6 @@ public:
|
||||
void write(ESGRAF48::MetaDataModel &model) const;
|
||||
|
||||
void printTo(QTextCursor &cursor) const;
|
||||
std::string toHtml() const;
|
||||
|
||||
Age getAge() const
|
||||
{
|
||||
|
@ -132,9 +132,6 @@ void MainWindow::closeFile()
|
||||
|
||||
void MainWindow::print() const
|
||||
{
|
||||
//std::ofstream htmlfile("print.html");
|
||||
//htmlfile << m_dataModel->toHtml();
|
||||
|
||||
QPrinter printer;
|
||||
|
||||
QPrintDialog dialog(&printer);
|
||||
|
Reference in New Issue
Block a user