summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Goffart <ogoffart@trolltech.com>2009-08-31 12:13:27 (GMT)
committerOlivier Goffart <ogoffart@trolltech.com>2009-08-31 12:20:35 (GMT)
commitab2faea59aef652606fdf34ccc8af83f1b6d557a (patch)
tree1c209349bf9d8941332f3b0084759285a7e03ddc
parent4ed5bb410bdcae60732a2636aa98336aa9a87b59 (diff)
downloadQt-ab2faea59aef652606fdf34ccc8af83f1b6d557a.zip
Qt-ab2faea59aef652606fdf34ccc8af83f1b6d557a.tar.gz
Qt-ab2faea59aef652606fdf34ccc8af83f1b6d557a.tar.bz2
Document some of the new QVariant feature
Including the befaviour change Reviewed-by: Thierry
-rw-r--r--dist/changes-4.6.024
-rw-r--r--src/corelib/kernel/qvariant.cpp1
2 files changed, 18 insertions, 7 deletions
diff --git a/dist/changes-4.6.0 b/dist/changes-4.6.0
index 194d670..ca984ac 100644
--- a/dist/changes-4.6.0
+++ b/dist/changes-4.6.0
@@ -27,6 +27,11 @@ information about a particular change.
* [245219] Added QXmlQuery::setFocus(const QString &focus);
+ - QVariant
+ * Many optimisations
+ * Added QVariant::toFloat() and QVariant::toReal()
+ * Added QVariant(float) constructor
+
****************************************************************************
* Platform Specific Changes *
****************************************************************************
@@ -83,29 +88,34 @@ information about a particular change.
- QDesktopWidget on X11 no longer emits the resized(int) signal when screens
are added or removed. This was not done on other platforms. Use the
screenCountChanged signal instead
-
+
- QUrl's parser is more strict when for hostnames in URLs. QUrl now
enforces STD 3 rules:
-
+
* each individual hostname section (between dots) must be at most
63 ASCII characters in length;
-
+
* only letters, digits, and the hyphen character are allowed in the
ASCII range; letters outside the ASCII range follow the normal
IDN rules
-
+
That means QUrl no longer accepts some URLs that were invalid
before, but weren't interpreted as such.
-
+
- The Unix configure-time check for STL is stricter now in Qt
4.6.0. This means some legacy STL implementations may fail to pass
the test and, therefore, Qt will automatically disable STL support.
-
+
This is a binary-compatible change: existing code will continue to
work without being recompiled. However, it affects the source code,
since some STL-compatibility API will not be enabled.
-
+
Platforms affected by this change:
* solaris-cc-* with the default (Cstd) C++ STL library
recommendation: use -library=stlport4
See Sun Studio's documentation for the effects of this option
+
+ - QVariant has now a new implicit constructor that takes a float. This
+ means that code that assigned a float to a variant would create a
+ variant with userType QMetaType::Float, instead of QVariant::Double.
+
diff --git a/src/corelib/kernel/qvariant.cpp b/src/corelib/kernel/qvariant.cpp
index 099fdf4..58f6537 100644
--- a/src/corelib/kernel/qvariant.cpp
+++ b/src/corelib/kernel/qvariant.cpp
@@ -1589,6 +1589,7 @@ QVariant::QVariant(const char *val)
\fn QVariant::QVariant(float val)
Constructs a new variant with a floating point value, \a val.
+ \since 4.6
*/
/*!