Libksieve

addresslineedit.h
1/*
2 SPDX-FileCopyrightText: 2013-2024 Laurent Montel <montel@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6#pragma once
7
8#include "ksieveui_private_export.h"
9#include <KSieveUi/AbstractSelectEmailLineEdit>
10class QLineEdit;
11namespace KSieveUi
12{
13class KSIEVEUI_TESTS_EXPORT AddressLineEdit : public AbstractSelectEmailLineEdit
14{
15 Q_OBJECT
16public:
17 explicit AddressLineEdit(QWidget *parent = nullptr);
18 ~AddressLineEdit() override;
19
20 void setText(const QString &str) override;
21 [[nodiscard]] QString text() const override;
22 [[nodiscard]] bool isValid() const override;
23
24protected:
25 void focusOutEvent(QFocusEvent *ev) override;
26
27private:
28 void slotTextChanged();
29 void verifyAddress();
30 QLineEdit *mLineEdit = nullptr;
31 QString mNegativeBackground;
32 bool mEmailIsInvalid = true;
33};
34}
bool isValid(QStringView ifopt)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 16:57:10 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.