Libksieve

sievescriptdebuggerwidget.h
1 /*
2  SPDX-FileCopyrightText: 2015-2021 Laurent Montel <[email protected]>
3 
4  SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6 
7 #pragma once
8 
9 #include "ksieveui_export.h"
10 #include <QWidget>
11 class QStackedWidget;
12 class QLabel;
13 namespace KSieveUi
14 {
15 class SieveScriptDebuggerFrontEndWidget;
16 /**
17  * @brief The SieveScriptDebuggerWidget class
18  * @author Laurent Montel <[email protected]>
19  */
20 class KSIEVEUI_EXPORT SieveScriptDebuggerWidget : public QWidget
21 {
22  Q_OBJECT
23 public:
24  explicit SieveScriptDebuggerWidget(QWidget *parent = nullptr);
25  ~SieveScriptDebuggerWidget() override;
26 
27  void setScript(const QString &script);
28  Q_REQUIRED_RESULT QString script() const;
29 
30  Q_REQUIRED_RESULT bool canAccept() const;
31 
32  Q_REQUIRED_RESULT QList<int> splitterSizes() const;
33  void setSplitterSizes(const QList<int> &sizes);
34 
35  Q_REQUIRED_RESULT bool haveDebugApps() const;
36 
37 Q_SIGNALS:
38  void scriptTextChanged();
39  void debugScriptButtonClicked();
40  void debugButtonEnabled(bool state);
41  void sieveTestNotFound();
42 
43 private:
44  void checkSieveTestApplication();
45  QStackedWidget *mStackedWidget = nullptr;
46  SieveScriptDebuggerFrontEndWidget *mSieveScriptFrontEnd = nullptr;
47  QLabel *mSieveNoExistingFrontEnd = nullptr;
48  bool mHaveDebugApps = false;
49 };
50 }
The SieveScriptDebuggerWidget class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Sun Apr 11 2021 23:09:37 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.