File indexing completed on 2024-12-29 04:54:40
0001 /* 0002 SPDX-FileCopyrightText: 2017-2024 Laurent Montel <montel@kde.org> 0003 0004 SPDX-License-Identifier: GPL-2.0-or-later 0005 */ 0006 0007 #pragma once 0008 0009 #include "ksieveui_private_export.h" 0010 #include <KSieveUi/AbstractRegexpEditorLineEdit> 0011 0012 class QLineEdit; 0013 namespace KSieveUi 0014 { 0015 class KSIEVEUI_TESTS_EXPORT RegexpEditorLineEdit : public KSieveUi::AbstractRegexpEditorLineEdit 0016 { 0017 Q_OBJECT 0018 public: 0019 explicit RegexpEditorLineEdit(QWidget *parent = nullptr); 0020 ~RegexpEditorLineEdit() override; 0021 0022 void switchToRegexpEditorLineEdit(bool regexpEditor) override; 0023 void setCode(const QString &str) override; 0024 [[nodiscard]] QString code() const override; 0025 void setClearButtonEnabled(bool b) override; 0026 void setPlaceholderText(const QString &str) override; 0027 0028 private: 0029 QLineEdit *const mLineEdit; 0030 }; 0031 }