summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorTopi Reinio <topi.reinio@qt.io>2021-11-06 17:39:20 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-11-27 10:55:50 +0000
commit7e01c4a99b4afa70485b0901e9432e337f078d31 (patch)
tree6743115d62e3e7cdbb9545b870c7f069c1e816c3 /doc
parent440a87248e059e37e56a25375e4ae79029d9ff78 (diff)
Doc: Add \QtMajorVersion macro
This macro expands to the major version of Qt, complementing the already existing \QtMinorVersion macro. Change-Id: I64861f8cc50d73f34369311a19b5e554645a4127 Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit 68942a37721bfeef5ce3009d061e0805da26d57e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'doc')
-rw-r--r--doc/global/macros.qdocconf5
1 files changed, 3 insertions, 2 deletions
diff --git a/doc/global/macros.qdocconf b/doc/global/macros.qdocconf
index d165d291b4..8b5f499d07 100644
--- a/doc/global/macros.qdocconf
+++ b/doc/global/macros.qdocconf
@@ -51,8 +51,9 @@ macro.emptyspan.HTML = "<span></span>"
# \summary {Creates a build target.}
macro.summary = "\\brief \1\n\n\1\n"
-# Expands to the minor version based on the QT_VER environment variable
-macro.QtMinorVersion = "$QT_VER"
+# Macros that expand to the major and minor versions based on the QT_VER environment variable
+{macro.QtMajorVersion,macro.QtMinorVersion} = "$QT_VER"
+macro.QtMajorVersion.match = "^(\\d+)\\."
macro.QtMinorVersion.match = "\\d+\\.(\\d+)"
# Embed YouTube content by video ID - Example: \youtube dQw4w9WgXcQ