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
mainwindow.h
Go to the documentation of this file.
1
// Copyright (C) 2016 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
3
4
#
ifndef
WINDOW_H
5
#
define
WINDOW_H
6
7
#
include
<
QMainWindow
>
8
#
include
<
QTextDocumentFragment
>
9
10
class
QAction;
11
class
QTextDocument;
12
class
QTextEdit;
13
14
class
MainWindow
:
public
QMainWindow
15
{
16
Q_OBJECT
17
18
public
:
19
MainWindow
();
20
21
public
slots
:
22
void
cutSelection
();
23
void
copySelection
();
24
void
openFile
();
25
void
pasteSelection
();
26
void
selectWord
();
27
void
selectLine
();
28
void
selectBlock
();
29
void
selectFrame
();
30
void
updateMenus
();
31
32
private
:
33
QAction *cutAction =
nullptr
;
34
QAction *copyAction =
nullptr
;
35
QAction *pasteAction =
nullptr
;
36
QString currentFile;
37
QTextEdit *editor =
nullptr
;
38
QTextDocument *document =
nullptr
;
39
QTextDocumentFragment selection;
40
};
41
42
#
endif
main
int main(int argc, char *argv[])
[2]
Definition
buffer.cpp:77
MainWindow
[5]
Definition
src_corelib_kernel_qobject.cpp:52
MainWindow::selectBlock
void selectBlock()
Definition
mainwindow.cpp:131
MainWindow::copySelection
void copySelection()
Definition
mainwindow.cpp:88
MainWindow::openFile
void openFile()
MainWindow::selectLine
void selectLine()
Definition
mainwindow.cpp:119
MainWindow::selectFrame
void selectFrame()
Definition
mainwindow.cpp:143
MainWindow::pasteSelection
void pasteSelection()
Definition
mainwindow.cpp:97
MainWindow::selectWord
void selectWord()
Definition
mainwindow.cpp:103
MainWindow::updateMenus
void updateMenus()
Definition
mainwindow.cpp:156
qtbase
src
gui
doc
snippets
textdocument-selections
mainwindow.h
Generated on Thu Nov 14 2024 00:41:05 for Qt by
1.12.0