summaryrefslogtreecommitdiffstats
path: root/src/gui/doc/snippets/picture
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2019-07-23 13:26:54 +0200
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2019-08-12 10:56:52 +0200
commitae83398d82173e7d416e72952760180414ea3fb6 (patch)
tree65fa964a876e878a6a7bce95a2c1f7dc4c920693 /src/gui/doc/snippets/picture
parent3eedb2fbd08ab73bfe3e9a8456f2c5228637b52a (diff)
Kill all QPictureIO
Has been deprecated for a long time. Change-Id: I4579e3c2997c649f0fa66b9cdbcf8e7fc6d661a5 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/gui/doc/snippets/picture')
-rw-r--r--src/gui/doc/snippets/picture/picture.cpp79
1 files changed, 0 insertions, 79 deletions
diff --git a/src/gui/doc/snippets/picture/picture.cpp b/src/gui/doc/snippets/picture/picture.cpp
index 863476fdbf..807c263b19 100644
--- a/src/gui/doc/snippets/picture/picture.cpp
+++ b/src/gui/doc/snippets/picture/picture.cpp
@@ -80,82 +80,3 @@ int main()
painter.end(); // painting done
//! [1]
}
-
- QPicture myPicture;
- {
- // FORMATS
-//! [2]
- const QStringList list = QPicture::inputFormatList();
- for (const QString &string : list)
- myProcessing(string);
-//! [2]
- }
-
- {
- // OUTPUT
-//! [3]
- const QStringList list = QPicture::outputFormatList();
- for (const QString &string : list)
- myProcessing(string);
-//! [3]
- }
-
- {
- // PIC READ
-//! [4]
- QPictureIO iio;
- QPixmap pixmap;
- iio.setFileName("vegeburger.pic");
- if (iio.read()) { // OK
- QPicture picture = iio.picture();
- QPainter painter(&pixmap);
- painter.drawPicture(0, 0, picture);
- }
-//! [4]
- }
-
- {
- QPixmap pixmap;
- // PIC WRITE
-//! [5]
- QPictureIO iio;
- QPicture picture;
- QPainter painter(&picture);
- painter.drawPixmap(0, 0, pixmap);
- iio.setPicture(picture);
- iio.setFileName("vegeburger.pic");
- iio.setFormat("PIC");
- if (iio.write())
- return true; // returned true if written successfully
-//! [5]
- }
-
-}
-
-// SVG READ
-//! [6]
-void readSVG(QPictureIO *picture)
-{
- // read the picture using the picture->ioDevice()
-}
-//! [6]
-
-// SVG WRITE
-//! [7]
-void writeSVG(QPictureIO *picture)
-{
- // write the picture using the picture->ioDevice()
-}
-//! [7]
-
-// USE SVG
-void foo() {
-
-//! [8]
- // add the SVG picture handler
- // ...
-//! [8]
- QPictureIO::defineIOHandler("SVG", 0, 0, readSVG, writeSVG);
- // ...
-
-}