diff --git a/src/gui/text/qtextformat.cpp b/src/gui/text/qtextformat.cpp index 985209473ca..44986c337c9 100644 --- a/src/gui/text/qtextformat.cpp +++ b/src/gui/text/qtextformat.cpp @@ -1457,6 +1457,7 @@ QTextCharFormat::QTextCharFormat(const QTextFormat &fmt) /*! \fn void QTextCharFormat::setFontFamily(const QString &family) + \obsolete Use setFontFamilies() instead. Sets the text format's font \a family. @@ -1466,6 +1467,7 @@ QTextCharFormat::QTextCharFormat(const QTextFormat &fmt) /*! \fn QString QTextCharFormat::fontFamily() const + \obsolete Use fontFamilies() instead. Returns the text format's font family. diff --git a/src/gui/text/qtextformat.h b/src/gui/text/qtextformat.h index 9cdd34be2c0..b297862b6fd 100644 --- a/src/gui/text/qtextformat.h +++ b/src/gui/text/qtextformat.h @@ -456,10 +456,10 @@ class Q_GUI_EXPORT QTextCharFormat : public QTextFormat void setFont(const QFont &font, FontPropertiesInheritanceBehavior behavior = FontPropertiesAll); QFont font() const; -#if QT_DEPRECATED_SINCE(6, 0) - QT_DEPRECATED_VERSION_X_6_0("Use setFontFamilies instead") inline void setFontFamily(const QString &family) +#if QT_DEPRECATED_SINCE(6, 1) + QT_DEPRECATED_VERSION_X_6_1("Use setFontFamilies instead") inline void setFontFamily(const QString &family) { setProperty(FontFamilies, QVariant(QStringList(family))); } - QT_DEPRECATED_VERSION_X_6_0("Use fontFamilies instead") inline QString fontFamily() const + QT_DEPRECATED_VERSION_X_6_1("Use fontFamilies instead") inline QString fontFamily() const { return property(FontFamilies).toStringList().first(); } #endif