Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qtextblock_p.h
Go to the documentation of this file.
1// Copyright (C) 2021 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 QTEXTBLOCK_P_H
5#define QTEXTBLOCK_P_H
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 <QtCore/qstring.h>
19
20namespace Utils {
21
22class TextDocument;
23class TextBlockUserData;
24
26{
27public:
28 bool isValid() const;
29
31 int blockNumber() const;
32
33 void setPosition(int position);
34 int position() const;
35
36 void setLength(int length);
37 int length() const;
38
39 TextBlock next() const;
40 TextBlock previous() const;
41
42 int userState() const;
43 void setUserState(int state);
44
45 bool isVisible() const;
46 void setVisible(bool visible);
47
49 int lineCount() const;
50
52 TextDocument *document() const;
53
54 QString text() const;
55
56 int revision() const;
57 void setRevision(int rev);
58
59 friend bool operator==(const TextBlock &t1, const TextBlock &t2);
60 friend bool operator!=(const TextBlock &t1, const TextBlock &t2);
61
62private:
63 TextDocument *m_document = nullptr;
64 int m_revision = 0;
65
66 int m_position = 0;
67 int m_length = 0;
68 int m_blockNumber = -1;
69};
70
71} // namespace Utils
72
73#endif // TEXTBLOCK_P_H
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
TextBlock next() const
int lineCount() const
bool isVisible() const
int userState() const
int length() const
void setLength(int length)
void setRevision(int rev)
void setDocument(TextDocument *document)
bool isValid() const
TextDocument * document() const
friend bool operator==(const TextBlock &t1, const TextBlock &t2)
int revision() const
friend bool operator!=(const TextBlock &t1, const TextBlock &t2)
int position() const
void setUserState(int state)
void setLineCount(int count)
int blockNumber() const
void setBlockNumber(int blockNumber)
void setVisible(bool visible)
TextBlock previous() const
QString text() const
else opt state
[0]
n void setPosition(void) \n\
GLenum GLuint GLenum GLsizei length
GLenum GLenum GLsizei count
GLuint GLfloat GLfloat GLfloat GLfloat GLfloat GLfloat GLfloat GLfloat GLfloat t1
[4]
#define t2