summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorThiago Macieira <[email protected]>2024-05-20 19:51:16 -0500
committerThiago Macieira <[email protected]>2024-06-01 08:36:42 -0300
commit70dd53e3d30dc85b6963bb2412535d037f4edf04 (patch)
treedfbc6b19315339943b994e137fefe788b978505f /src
parentd5dd7da3eef45c69957e4b16cc8af83475aa1e99 (diff)
uic: recognize <legal> tag as an alias for <comment>
That is printed at the top of the file and we've used it for the copyright inside Qt, so just declare an alias. [ChangeLog][uic] The Qt UI Compiler now accepts a <legal> XML tag to indicate the copyright of the UI file and other legal terms of use. The text of this tag will be emitted in the generated code. This tag is an alias to <comment>. Change-Id: If3345151ddf84c43a4f1fffd17d15ab77412e289 Reviewed-by: Volker Hilsheimer <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/tools/uic/ui4.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/tools/uic/ui4.cpp b/src/tools/uic/ui4.cpp
index d65fc4a8c3a..b6a8f4eb4bf 100644
--- a/src/tools/uic/ui4.cpp
+++ b/src/tools/uic/ui4.cpp
@@ -77,7 +77,8 @@ void DomUI::read(QXmlStreamReader &reader)
setElementAuthor(reader.readElementText());
continue;
}
- if (!tag.compare(u"comment"_s, Qt::CaseInsensitive)) {
+ if (!tag.compare(u"comment"_s, Qt::CaseInsensitive)
+ || !tag.compare(u"legal"_s, Qt::CaseInsensitive)) {
setElementComment(reader.readElementText());
continue;
}