QGIS API Documentation
4.3.0-Master (52aa6503bed)
Toggle main menu visibility
Loading...
Searching...
No Matches
src
gui
qgsconfigureshortcutsdialog.h
Go to the documentation of this file.
1
/***************************************************************************
2
qgsconfigureshortcutsdialog.h
3
-----------------------------
4
begin : May 2009
5
copyright : (C) 2009 by Martin Dobias
6
email : wonder dot sk at gmail dot com
7
***************************************************************************
8
* *
9
* This program is free software; you can redistribute it and/or modify *
10
* it under the terms of the GNU General Public License as published by *
11
* the Free Software Foundation; either version 2 of the License, or *
12
* (at your option) any later version. *
13
* *
14
***************************************************************************/
15
16
#ifndef QGSCONFIGURESHORTCUTSDIALOG_H
17
#define QGSCONFIGURESHORTCUTSDIALOG_H
18
19
#include "ui_qgsconfigureshortcutsdialog.h"
20
21
#include "qgis_gui.h"
22
#include "
qgis_sip.h
"
23
#include "
qgshelp.h
"
24
25
#include <QDialog>
26
27
class
QShortcut;
28
class
QgsShortcutsManager
;
29
35
36
class
GUI_EXPORT
QgsConfigureShortcutsDialog
:
public
QDialog,
private
Ui::QgsConfigureShortcutsDialog
37
{
38
Q_OBJECT
39
40
public
:
47
QgsConfigureShortcutsDialog
( QWidget *parent
SIP_TRANSFERTHIS
=
nullptr
,
QgsShortcutsManager
*manager =
nullptr
);
48
49
public
slots:
50
58
void
setFilter
(
const
QString &filterText );
59
60
protected
:
61
void
keyPressEvent
( QKeyEvent *event )
override
;
62
void
keyReleaseEvent
( QKeyEvent *event )
override
;
63
64
private
slots:
65
void
changeShortcut();
66
void
resetShortcut();
67
void
setNoShortcut();
68
void
loadShortcuts();
69
void
saveShortcutsPdf();
70
void
mLeFilter_textChanged(
const
QString &text );
71
72
void
actionChanged( QTreeWidgetItem *current, QTreeWidgetItem *previous );
73
75
void
showHelp();
76
77
private
:
78
enum class
ActionOnExisting
79
{
80
Ask,
81
ReassignAll,
82
SkipAll,
83
};
84
86
void
populateActions();
87
89
QObject *currentObject();
90
92
QAction *currentAction();
93
95
QShortcut *currentShortcut();
96
98
void
saveShortcuts(
bool
saveAll =
true
);
99
100
void
setGettingShortcut(
bool
getting );
101
void
setCurrentActionShortcut(
const
QKeySequence &s );
102
void
updateShortcutText();
103
104
QgsShortcutsManager
*mManager =
nullptr
;
105
QMenu *mSaveMenu =
nullptr
;
106
QAction *mSaveUserShortcuts =
nullptr
;
107
QAction *mSaveAllShortcuts =
nullptr
;
108
QAction *mSaveAsPdf =
nullptr
;
109
110
bool
mGettingShortcut =
false
;
111
Qt::KeyboardModifiers mModifiers = Qt::KeyboardModifiers();
112
int
mKey = 0;
113
};
114
115
#endif
//QGSCONFIGURESHORTCUTSDIALOG_H
QgsConfigureShortcutsDialog::QgsConfigureShortcutsDialog
QgsConfigureShortcutsDialog(QWidget *parent=nullptr, QgsShortcutsManager *manager=nullptr)
Constructor for QgsConfigureShortcutsDialog.
Definition
qgsconfigureshortcutsdialog.cpp:47
QgsConfigureShortcutsDialog::setFilter
void setFilter(const QString &filterText)
Sets the text for the filter line edit.
Definition
qgsconfigureshortcutsdialog.cpp:85
QgsConfigureShortcutsDialog::keyReleaseEvent
void keyReleaseEvent(QKeyEvent *event) override
Definition
qgsconfigureshortcutsdialog.cpp:522
QgsConfigureShortcutsDialog::keyPressEvent
void keyPressEvent(QKeyEvent *event) override
Definition
qgsconfigureshortcutsdialog.cpp:482
QgsShortcutsManager
Shortcuts manager is a class that contains a list of QActions and QShortcuts that have been registere...
Definition
qgsshortcutsmanager.h:38
qgis_sip.h
SIP_TRANSFERTHIS
#define SIP_TRANSFERTHIS
Definition
qgis_sip.h:52
qgshelp.h
Generated on
for QGIS API Documentation by
1.17.0