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
qqmldomindentinglinewriter_p.h
Go to the documentation of this file.
1// Copyright (C) 2022 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QQMLDOMINDENTIGLINEWRITER_P
5#define QQMLDOMINDENTIGLINEWRITER_P
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include "qqmldom_global.h"
21
22#include <QtQml/private/qqmljssourcelocation_p.h>
23#include <QtCore/QAtomicInt>
24#include <functional>
25
27namespace QQmlJS {
28namespace Dom {
29
31{
33public:
43 void reindentAndSplit(const QString &eol, bool eof = false) override;
46
47 void lineChanged() override { m_fStatusValid = false; }
48 void willCommit() override;
49 bool reindent() const { return m_reindent; }
50 void setReindent(bool v) { m_reindent = v; }
51
52 void splitOnMaxLength(const QString &eol, bool eof);
53
54private:
57protected:
59 bool m_fStatusValid = false;
61};
62
63} // namespace Dom
64} // namespace QQmlJS
65QT_END_NAMESPACE
66#endif
void splitOnMaxLength(const QString &eol, bool eof)
void setLineIndent(int indentAmount)
static bool lexKindIsComment(int kind)
static constexpr bool shouldSplitAfterToken(int kind)
Combined button and popup list for selecting options.
#define QMLDOM_EXPORT