Commit 2792ea8f authored by tanelipe's avatar tanelipe

Update README.md

Updated README to include examples
parent afe1e123
......@@ -4,3 +4,13 @@ QmlPrinter
Simple Qt component which allows user to print out a QML view from C++.
Based on the work of Cyrille Berger (https://github.com/cyrilleberger/PrintML)
Examples
==========
```
// Get the root view object
QQuickItem *root = ...
// Print the view to Report.pdf located in Public Documents and then open it with a default PDF viewer
QmlPrinter printer;
printer.printPDF("C:\\Users\\Public\\Documents\\Report.pdf", root, true);
```
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment