painter.
setPen(QPen(Qt
::black,
12,Qt
::SolidLine,Qt
::RoundCap));
painter.drawLine(line1);
painter.drawLine(line2);
m_cursor.insertImage(geometry);
m_document->print(&printer);
QImage geometry(300,200,QImage::Format_Mono);
QPainter painter(&geometry);
painter.setPen(QPen(Qt::black,12,Qt::SolidLine,Qt::RoundCap));
QLineF line1(10,80,80,80);
QLineF line2(10,10,80,80);
painter.drawLine(line1);
painter.drawLine(line2);
m_cursor.insertImage(geometry);
m_document->print(&printer);
To copy to clipboard, switch view to plain text mode
where m_cursor is a QTextCursor on QTextDocument.
Bookmarks