Marble

GeoDataItemIcon.h
1// SPDX-License-Identifier: LGPL-2.1-or-later
2//
3// SPDX-FileCopyrightText: 2012 Mohammed Nafees <nafees.technocool@gmail.com>
4//
5
6#ifndef GEODATAITEMICON_H
7#define GEODATAITEMICON_H
8
9#include <QFlags>
10
11#include "GeoDataObject.h"
12
13class QImage;
14
15namespace Marble
16{
17
18class GeoDataItemIconPrivate;
19
20/**
21 */
22class GEODATA_EXPORT GeoDataItemIcon : public GeoDataObject
23{
24 Q_FLAGS(ItemIconState ItemIconStates)
25public:
26 GeoDataItemIcon();
27
28 GeoDataItemIcon(const GeoDataItemIcon &other);
29
30 GeoDataItemIcon &operator=(const GeoDataItemIcon &other);
31 bool operator==(const GeoDataItemIcon &other) const;
32 bool operator!=(const GeoDataItemIcon &other) const;
33
34 ~GeoDataItemIcon() override;
35
36 /** Provides type information for downcasting a GeoNode */
37 const char *nodeType() const override;
38
39 enum ItemIconState {
40 Open = 1 << 0,
41 Closed = 1 << 1,
42 Error = 1 << 2,
43 Fetching0 = 1 << 3,
44 Fetching1 = 1 << 4,
45 Fetching2 = 1 << 5
46 };
47 Q_DECLARE_FLAGS(ItemIconStates, ItemIconState)
48
49 ItemIconStates state() const;
50 void setState(ItemIconStates state);
51
52 QString iconPath() const;
53 void setIconPath(const QString &path);
54
55 QImage icon() const;
56 void setIcon(const QImage &icon);
57
58private:
59 GeoDataItemIconPrivate *const d;
60};
61
62}
63
64#endif
KIOCORE_EXPORT bool operator!=(const UDSEntry &entry, const UDSEntry &other)
bool operator==(const StyleDelim &l, const StyleDelim &r)
Binds a QML item to a specific geodetic location in screen coordinates.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:04:13 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.