Doc: Fix QIcon documentation

* Move \externalpage topics to external-resources.qdoc, as that command
  cannot be embedded in other topics.

* Fix references to non-existent function fallbackIconTheme().

Change-Id: I5d08206c53aea9c2d4c6fddf5d04df187b01ef53
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
(cherry picked from commit b5169b5c909d06c61bdc45b09c97c05154043a24)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
Topi Reinio 2023-09-27 12:25:47 +00:00 committed by Qt Cherry-pick Bot
parent c2164340bf
commit d99e4ac02b
2 changed files with 20 additions and 18 deletions

View File

@ -29,14 +29,23 @@
/*!
\externalpage https://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html
\title Icon Theme Specification
\title Freedesktop Icon Theme Specification
*/
/*!
\externalpage https://specifications.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html
\title Freedesktop Icon Naming Specification
*/
/*!
\externalpage https://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html#directory_layout
\title Icon Theme Specification - Directory Layout
*/
/*!
\externalpage https://freedesktop.org/
\title Freedesktop
*/
/*!
\externalpage https://www.khronos.org/vulkan/
\title Vulkan

View File

@ -599,9 +599,9 @@ QFactoryLoader *qt_iconEngineFactoryLoader()
icons: via \l addFile() and \l fromTheme().
\l addFile() is useful if you have your own custom directory structure and do
not need to use the \l {Icon Theme Specification}{freedesktop.org Icon Theme
Specification}. Icons created via this approach use Qt's \l {High Resolution
Versions of Images}{"@nx" high DPI syntax}.
not need to use the \l {Freedesktop Icon Theme Specification}. Icons
created via this approach use Qt's \l {High Resolution Versions of Images}
{"@nx" high DPI syntax}.
Using \l fromTheme() is necessary if you plan on following the Icon Theme
Specification. To make QIcon use the high DPI version of an image, add an
@ -1200,10 +1200,8 @@ void QIcon::setFallbackSearchPaths(const QStringList &paths)
correspond to a directory name in the themeSearchPath()
containing an \c index.theme file describing its contents.
\externalpage http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html
\title Freedesktop Icon Theme Specification
\sa themeSearchPaths(), themeName()
\sa themeSearchPaths(), themeName(),
{Freedesktop Icon Theme Specification}
*/
void QIcon::setThemeName(const QString &name)
{
@ -1222,9 +1220,6 @@ void QIcon::setThemeName(const QString &name)
\l{Freedesktop} based systems at the moment, and the
icon theme depends on your desktop settings.
\externalpage https://www.freedesktop.org/
\title Freedesktop
\sa setThemeName(), themeSearchPaths(), fromTheme(),
hasThemeIcon()
*/
@ -1282,7 +1277,7 @@ void QIcon::setFallbackThemeName(const QString &name)
\l{themeName()}{current icon theme}.
If the current theme does not provide an icon for \a name,
the \l{fallbackIconTheme()}{fallback icon theme} is consulted,
the \l{fallbackThemeName()}{fallback icon theme} is consulted,
before falling back to looking up standalone icon files in the
\l{QIcon::fallbackSearchPaths()}{fallback icon search path}.
@ -1301,10 +1296,8 @@ void QIcon::setFallbackThemeName(const QString &name)
to bundle a \l{setThemeName()}{compliant theme} in one of your
themeSearchPaths(), and set the appropriate themeName().
\externalpage https://specifications.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html
\title Freedesktop Icon Naming Specification
\sa themeName(), fallbackIconTheme(), setThemeName(), themeSearchPaths(), fallbackSearchPaths()
\sa themeName(), fallbackThemeName(), setThemeName(), themeSearchPaths(), fallbackSearchPaths(),
{Freedesktop Icon Naming Specification}
*/
QIcon QIcon::fromTheme(const QString &name)
{
@ -1327,7 +1320,7 @@ QIcon QIcon::fromTheme(const QString &name)
\l{themeName()}{current icon theme}.
If the current theme does not provide an icon for \a name,
the \l{fallbackIconTheme()}{fallback icon theme} is consulted,
the \l{fallbackThemeName()}{fallback icon theme} is consulted,
before falling back to looking up standalone icon files in the
\l{QIcon::fallbackSearchPaths()}{fallback icon search path}.
@ -1341,7 +1334,7 @@ QIcon QIcon::fromTheme(const QString &name)
\snippet code/src_gui_image_qicon.cpp 4
\sa fallbackIconTheme(), fallbackSearchPaths()
\sa fallbackThemeName(), fallbackSearchPaths()
*/
QIcon QIcon::fromTheme(const QString &name, const QIcon &fallback)
{