summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeir Vattekar <geir.vattekar@nokia.com>2011-03-17 12:08:34 (GMT)
committerGeir Vattekar <geir.vattekar@nokia.com>2011-03-17 12:08:34 (GMT)
commita09903cd713f94508b599d7723725295821775a5 (patch)
tree2ff8eb90901dcb83478d361c631cf2b8e0afec2d
parent86724150c8117dd2fbfa117a642dce57176e5e23 (diff)
downloadQt-a09903cd713f94508b599d7723725295821775a5.zip
Qt-a09903cd713f94508b599d7723725295821775a5.tar.gz
Qt-a09903cd713f94508b599d7723725295821775a5.tar.bz2
Doc: Fixed reference to absolete API in exceptionsafety.html
Task-number: QTBUG-14445 Reviewed-by: Jerome Pasion
-rw-r--r--doc/src/howtos/exceptionsafety.qdoc5
-rw-r--r--src/gui/image/qimage.cpp4
2 files changed, 7 insertions, 2 deletions
diff --git a/doc/src/howtos/exceptionsafety.qdoc b/doc/src/howtos/exceptionsafety.qdoc
index c4b5ebc..b3795d6 100644
--- a/doc/src/howtos/exceptionsafety.qdoc
+++ b/doc/src/howtos/exceptionsafety.qdoc
@@ -100,8 +100,9 @@
if any allocation fails. Allocations can fail if the system runs out of memory or
doesn't have enough continuous memory to allocate the requested size.
- Exceptions to that rule are documented. As an example, \l QImage::create()
- returns false if not enough memory exists instead of throwing an exception.
+ Exceptions to that rule are documented. As an example, QImage constructors will
+ create a \l{QImage::isNull()}{null} image if not enough memory exists instead
+ of throwing an exception.
\section1 Recovering from exceptions
diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp
index 168c518..441bdb1 100644
--- a/src/gui/image/qimage.cpp
+++ b/src/gui/image/qimage.cpp
@@ -833,6 +833,8 @@ QImage::QImage()
Constructs an image with the given \a width, \a height and \a
format.
+ A \l{isNull()}{null} image will be returned if memory cannot be allocated.
+
\warning This will create a QImage with uninitialized data. Call
fill() to fill the image with an appropriate pixel value before
drawing onto it with QPainter.
@@ -846,6 +848,8 @@ QImage::QImage(int width, int height, Format format)
/*!
Constructs an image with the given \a size and \a format.
+ A \l{isNull()}{null} image is returned if memory cannot be allocated.
+
\warning This will create a QImage with uninitialized data. Call
fill() to fill the image with an appropriate pixel value before
drawing onto it with QPainter.