Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qqmllintsettings.cpp
Go to the documentation of this file.
1// Copyright (C) 2026 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
3// Qt-Security score:significant
4
6
8
9using namespace Qt::StringLiterals;
10
11QQmlLintSettings::QQmlLintSettings(const QString &name)
12 : QQmlToolingSettings(name, { "General"_L1, "Warnings"_L1 })
13{
14 addOption(s_maxWarnings, -1);
15}
16
17qsizetype QQmlLintSettings::maxWarnings() const
18{
19 if (!isSet(QQmlLintSettings::s_maxWarnings))
20 return -1;
21 bool ok = false;
22 qsizetype result = value(QQmlLintSettings::s_maxWarnings).toLongLong(&ok);
23 return ok ? result : -1;
24}
25
26QT_END_NAMESPACE
Combined button and popup list for selecting options.