diff options
author | Shawn Rutledge <shawn.rutledge@qt.io> | 2018-12-18 00:56:37 +0100 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2019-05-02 04:10:35 +0000 |
commit | 355ecfb11c838b4c9facc9a631e04a52531a2127 (patch) | |
tree | 5b59ec8df2690601b8e5d33252f8ba2dc45a534c /src/gui/text/qtextmarkdownwriter_p.h | |
parent | 0df30ff22e50aa301791fc72f106ab15ce385a6a (diff) |
Add QTextMarkdownWriter::writeTable(QAbstractTableModel)
This provides the ability to write live data from a table to Markdown,
which can be useful to load it into a text document or a wiki.
But so far QTextMarkdownWriter is still a private class, intended to be
used experimentally from QtQuick and perhaps later exposed in other ways.
Change-Id: I0de4673987e4172178604e49b5a024a05d4486ba
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Diffstat (limited to 'src/gui/text/qtextmarkdownwriter_p.h')
-rw-r--r-- | src/gui/text/qtextmarkdownwriter_p.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/text/qtextmarkdownwriter_p.h b/src/gui/text/qtextmarkdownwriter_p.h index 9845355259..2a9388ca2d 100644 --- a/src/gui/text/qtextmarkdownwriter_p.h +++ b/src/gui/text/qtextmarkdownwriter_p.h @@ -56,6 +56,7 @@ #include "qtextdocument_p.h" #include "qtextdocumentwriter.h" +#include "QAbstractTableModel" QT_BEGIN_NAMESPACE @@ -64,6 +65,7 @@ class Q_GUI_EXPORT QTextMarkdownWriter public: QTextMarkdownWriter(QTextStream &stream, QTextDocument::MarkdownFeatures features); bool writeAll(const QTextDocument &document); + void writeTable(const QAbstractTableModel &table); int writeBlock(const QTextBlock &block, bool table, bool ignoreFormat); void writeFrame(const QTextFrame *frame); |