File indexing completed on 2024-09-15 03:28:21
0001 /* 0002 This file is part of Kiten, a KDE Japanese Reference Tool 0003 SPDX-FileCopyrightText: 2006 Joseph Kerian <jkerian@gmail.com> 0004 0005 SPDX-License-Identifier: LGPL-2.0-or-later 0006 */ 0007 0008 #ifndef KANJI_H 0009 #define KANJI_H 0010 0011 #include <QSet> 0012 #include <QString> 0013 0014 #include "radical.h" 0015 0016 class Kanji : public QString 0017 { 0018 public: 0019 Kanji(); 0020 explicit Kanji(const QString &kanji, const QSet<QString> &radicals); 0021 0022 void addRadical(const QString &it); 0023 void setStrokes(unsigned int strokes); 0024 const QSet<QString> &getRadicals() const; 0025 unsigned int strokes() const; 0026 0027 bool operator<(const Kanji &other) const; 0028 0029 protected: 0030 unsigned int strokeCount; 0031 QSet<QString> components; 0032 }; 0033 0034 #endif