CuteLogger
Fast and simple logging solution for Qt based applications
qmleditmenu.h
1 /*
2  * Copyright (c) 2022 Meltytech, LLC
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef QMLEDITMENU_H
19 #define QMLEDITMENU_H
20 
21 #include <QObject>
22 
23 class QmlEditMenu : public QObject
24 {
25  Q_OBJECT
26 
27  Q_PROPERTY(bool showPastePlain MEMBER m_showPastePlain NOTIFY showPastePlainChanged)
28  Q_PROPERTY(bool readOnly MEMBER m_readOnly NOTIFY readOnlyChanged)
29 
30 public:
31  explicit QmlEditMenu(QObject *parent = 0);
32 
33 signals:
34  void showPastePlainChanged();
35  void readOnlyChanged();
36  void undoTriggered();
37  void redoTriggered();
38  void cutTriggered();
39  void copyTriggered();
40  void pasteTriggered();
41  void pastePlainTriggered();
42  void deleteTriggered();
43  void clearTriggered();
44  void selectAllTriggered();
45 
46 public slots:
47  void popup();
48 
49 private:
50  bool m_showPastePlain;
51  bool m_readOnly;
52 };
53 
54 #endif // QMLEDITMENU_H