summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qfontmetrics.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/text/qfontmetrics.cpp')
-rw-r--r--src/gui/text/qfontmetrics.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/gui/text/qfontmetrics.cpp b/src/gui/text/qfontmetrics.cpp
index abab91c65..012c0f6c7 100644
--- a/src/gui/text/qfontmetrics.cpp
+++ b/src/gui/text/qfontmetrics.cpp
@@ -557,11 +557,10 @@ int QFontMetrics::width(const QString &text, int len) const
\warning This function will produce incorrect results for Arabic
characters or non-spacing marks in the middle of a string, as the
glyph shaping and positioning of marks that happens when
- processing strings cannot be taken into account. Use charWidth()
- instead if you aren't looking for the width of isolated
- characters.
+ processing strings cannot be taken into account. When implementing
+ an interactive text control, use QTextLayout instead.
- \sa boundingRect(), charWidth()
+ \sa boundingRect()
*/
int QFontMetrics::width(QChar ch) const
{
@@ -1386,9 +1385,8 @@ qreal QFontMetricsF::width(const QString &text) const
\warning This function will produce incorrect results for Arabic
characters or non-spacing marks in the middle of a string, as the
glyph shaping and positioning of marks that happens when
- processing strings cannot be taken into account. Use charWidth()
- instead if you aren't looking for the width of isolated
- characters.
+ processing strings cannot be taken into account. When implementing
+ an interactive text control, use QTextLayout instead.
\sa boundingRect()
*/