File indexing completed on 2024-06-23 05:48:51
0001 /* 0002 This file is part of the Okteta Kasten module, made within the KDE community. 0003 0004 SPDX-FileCopyrightText: 2009 Friedrich W. H. Kossebau <kossebau@kde.org> 0005 0006 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0007 */ 0008 0009 #ifndef KASTEN_CHAR8EDITOR_HPP 0010 #define KASTEN_CHAR8EDITOR_HPP 0011 0012 // lib 0013 #include "char8stringparser.hpp" 0014 #include "../types/char8.hpp" 0015 // Qt 0016 #include <QLineEdit> 0017 0018 namespace Okteta { 0019 class CharCodec; 0020 } 0021 0022 class Char8Editor : public QLineEdit 0023 { 0024 Q_OBJECT 0025 Q_PROPERTY(Char8 data READ data WRITE setData USER true) 0026 0027 public: 0028 Char8Editor(const Okteta::CharCodec* charCodec, QWidget* parent); 0029 0030 ~Char8Editor() override; 0031 0032 public: 0033 void setData(Char8 data); 0034 Char8 data() const; 0035 0036 private: 0037 Okteta::Char8StringParser m_parser; 0038 }; 0039 0040 #endif