[Development] QJsonDocument formatting

Matt Broadstone mbroadst at gmail.com
Sun Mar 3 22:33:47 CET 2013


On Sun, Mar 3, 2013 at 4:26 PM, Thiago Macieira
<thiago.macieira at intel.com>wrote:

> On domingo, 3 de março de 2013 16.19.17, Matt Broadstone wrote:
> > I'd like to propose a new method added to the QJsonDocument class:
> >    QJsonDocument::toFormattedJson(int indent, bool compact)
>
> Too late. It's already there.
>
>     enum JsonFormat {
>         Indented,
>         Compact
>     };
>
>     QByteArray toJson() const; //### Merge in Qt6
>     QByteArray toJson(JsonFormat format) const;
>
>
Oh, awesome :)

Matt


>
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>   Software Architect - Intel Open Source Technology Center
>
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20130303/ac220398/attachment.html>


More information about the Development mailing list