TreeFrogFramework  2.8
thtmlattribute.h
Go to the documentation of this file.
1 #pragma once
2 #include <QPair>
3 #include <QStringList>
4 #include <TGlobal>
5 
6 
7 class T_CORE_EXPORT THtmlAttribute : public QList<QPair<QString, QString>> {
8 public:
10  THtmlAttribute(const QString &key, const QString &value);
11  THtmlAttribute(const THtmlAttribute &other);
12  THtmlAttribute(const QList<QPair<QString, QString>> &list);
13 
14  bool contains(const QString &key) const;
15  void prepend(const QString &key, const QString &value);
16  void append(const QString &key, const QString &value);
17  THtmlAttribute &operator()(const QString &key, const QString &value);
18  THtmlAttribute &operator=(const THtmlAttribute &other);
19  THtmlAttribute operator|(const THtmlAttribute &other) const;
20  QString toString(bool escape = true) const;
21 };
22 
23 Q_DECLARE_METATYPE(THtmlAttribute)
24 
The THtmlAttribute class represents HTML attributes for customizing web elements.
Definition: thtmlattribute.h:7
THtmlAttribute()
Constructor.
Definition: thtmlattribute.h:9
#define T_CORE_EXPORT
Definition: tdeclexport.h:28
TOption operator|(const TOption &o1, const TOption &o2)
Definition: toption.cpp:11