Hello everyone,

I'm trying to figure it out how to set the layout of an ODF doc to landscape instead of portrait, and until now no results.

Does anyone has any clue on this?

Regards,

Coss_cat

CODE of cpp file(the .h contains all necessary; the code compiles well):
Qt Code:
  1. m_document = new QTextDocument();
  2. QSizeF size;
  3. size.setHeight(225);
  4. size.setWidth(300);
  5. m_document->setPageSize(size);
  6.  
  7. // Cursor for traversing the document
  8. m_cursor = QTextCursor(m_document);
  9. //use the cursor to write things
  10.  
  11. //blah blah blah
  12.  
  13. QTextDocumentWriter writer;
  14. writer.setFormat("odt");
  15. writer.setFileName(docfilename.toAscii());
  16. writer.write(m_document);
To copy to clipboard, switch view to plain text mode