QGIS API Documentation 4.3.0-Master (16649ce5cc6)
Loading...
Searching...
No Matches
qgsprocessingscripteditordialog.cpp
Go to the documentation of this file.
1/***************************************************************************
2 qgsprocessingscripteditordialog.cpp
3 ------------------------
4 Date : September 2026
5 Copyright : (C) 2026 Nyall Dawson
6 Email : nyall dot dawson 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
17
18#include "qgsgui.h"
19
20#include "moc_qgsprocessingscripteditordialog.cpp"
21
22using namespace Qt::StringLiterals;
23
25
26
27QgsProcessingScriptEditorDialog::QgsProcessingScriptEditorDialog( QWidget *parent, Qt::WindowFlags flags )
28 : QMainWindow( parent, flags )
29{
30 setupUi( this );
31
32 setObjectName( "QgsProcessingScriptEditorDialog" );
34
35 setStyleSheet( QgsGui::applicationStyleSheet() );
36 connect( QgsGui::instance(), &QgsGui::applicationStyleSheetChanged, this, &QgsProcessingScriptEditorDialog::setStyleSheet );
37
38 mToolBar->setIconSize( QgsGui::iconSize() );
39}
40
41QgsProcessingScriptEditorDialog::~QgsProcessingScriptEditorDialog() = default;
42
43QWidget *QgsProcessingScriptEditorDialog::editorContainer()
44{
45 return mEditorContainer;
46}
47
48QAction *QgsProcessingScriptEditorDialog::actionToggleComment()
49{
50 return mActionToggleComment;
51}
52
53QAction *QgsProcessingScriptEditorDialog::actionOpenScript()
54{
55 return mActionOpenScript;
56}
57
58QAction *QgsProcessingScriptEditorDialog::actionSaveScript()
59{
60 return mActionSaveScript;
61}
62
63QAction *QgsProcessingScriptEditorDialog::actionSaveScriptAs()
64{
65 return mActionSaveScriptAs;
66}
67
68QAction *QgsProcessingScriptEditorDialog::actionRunScript()
69{
70 return mActionRunScript;
71}
72
73QAction *QgsProcessingScriptEditorDialog::actionCut()
74{
75 return mActionCut;
76}
77
78QAction *QgsProcessingScriptEditorDialog::actionCopy()
79{
80 return mActionCopy;
81}
82
83QAction *QgsProcessingScriptEditorDialog::actionPaste()
84{
85 return mActionPaste;
86}
87
88QAction *QgsProcessingScriptEditorDialog::actionUndo()
89{
90 return mActionUndo;
91}
92
93QAction *QgsProcessingScriptEditorDialog::actionRedo()
94{
95 return mActionRedo;
96}
97
98QAction *QgsProcessingScriptEditorDialog::actionFindReplace()
99{
100 return mActionFindReplace;
101}
102
103QAction *QgsProcessingScriptEditorDialog::actionIncreaseFontSize()
104{
105 return mActionIncreaseFontSize;
106}
107
108QAction *QgsProcessingScriptEditorDialog::actionDecreaseFontSize()
109{
110 return mActionDecreaseFontSize;
111}
112
113
static QSize iconSize(Qgis::UserInterfaceIconType iconType=Qgis::UserInterfaceIconType::MainWindowToolbar)
Returns the desired size for user interface icons.
Definition qgsgui.cpp:514
void applicationStyleSheetChanged(const QString &styleSheet)
Emitted whenever the application style sheet is changed.
static QString applicationStyleSheet()
Returns the application style sheet.
Definition qgsgui.cpp:399
static QgsGui * instance()
Returns a pointer to the singleton instance.
Definition qgsgui.cpp:94
static void enableAutoGeometryRestore(QWidget *widget, const QString &key=QString())
Register the widget to allow its position to be automatically saved and restored when open and closed...
Definition qgsgui.cpp:225