1 /**************************************************************************** 2 ** 3 ** DQt - D bindings for the Qt Toolkit 4 ** 5 ** GNU Lesser General Public License Usage 6 ** This file may be used under the terms of the GNU Lesser 7 ** General Public License version 3 as published by the Free Software 8 ** Foundation and appearing in the file LICENSE.LGPL3 included in the 9 ** packaging of this file. Please review the following information to 10 ** ensure the GNU Lesser General Public License version 3 requirements 11 ** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. 12 ** 13 ****************************************************************************/ 14 module qt.gui.textdocumentwriter; 15 extern(C++): 16 17 import qt.config; 18 import qt.core.bytearray; 19 import qt.core.iodevice; 20 import qt.core.list; 21 import qt.core.string; 22 import qt.core.textcodec; 23 import qt.gui.textdocument; 24 import qt.gui.textdocumentfragment; 25 import qt.helpers; 26 27 extern(C++, class) struct QTextDocumentWriterPrivate; 28 /+ class QIODevice; 29 class QByteArray; 30 class QTextDocument; 31 class QTextDocumentFragment; +/ 32 33 extern(C++, class) struct /+ Q_GUI_EXPORT +/ QTextDocumentWriter 34 { 35 public: 36 @disable this(); 37 pragma(mangle, defaultConstructorMangling(__traits(identifier, typeof(this)))) 38 ref typeof(this) rawConstructor(); 39 static typeof(this) create() 40 { 41 typeof(this) r = typeof(this).init; 42 r.rawConstructor(); 43 return r; 44 } 45 46 this(QIODevice device, ref const(QByteArray) format); 47 /+ explicit +/this(ref const(QString) fileName, ref const(QByteArray) format = globalInitVar!QByteArray); 48 ~this(); 49 50 void setFormat (ref const(QByteArray) format); 51 QByteArray format () const; 52 53 void setDevice (QIODevice device); 54 QIODevice device () const; 55 void setFileName (ref const(QString) fileName); 56 QString fileName () const; 57 58 bool write(const(QTextDocument) document); 59 bool write(ref const(QTextDocumentFragment) fragment); 60 61 /+ #if QT_CONFIG(textcodec) +/ 62 void setCodec(QTextCodec codec); 63 QTextCodec codec() const; 64 /+ #endif +/ 65 66 static QList!(QByteArray) supportedDocumentFormats(); 67 68 private: 69 /+ Q_DISABLE_COPY(QTextDocumentWriter) +/ 70 @disable this(this); 71 /+this(ref const(QTextDocumentWriter));+//+ref QTextDocumentWriter operator =(ref const(QTextDocumentWriter));+/ QTextDocumentWriterPrivate* d; 72 } 73