Marble

GeoDataListStyle.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 GEODATALISTSTYLE_H
7#define GEODATALISTSTYLE_H
8
9#include "MarbleGlobal.h"
10#include "GeoDataObject.h"
11#include "geodata_export.h"
12
13#include <QColor>
14#include <QVector>
15
16
17namespace Marble
18{
19
20class GeoDataListStylePrivate;
21class GeoDataItemIcon;
22
23/**
24 */
25class GEODATA_EXPORT GeoDataListStyle : public GeoDataObject
26{
27public:
28 GeoDataListStyle();
29
30 GeoDataListStyle( const GeoDataListStyle &other );
31
32 GeoDataListStyle& operator=( const GeoDataListStyle &other );
33
34 bool operator==( const GeoDataListStyle &other ) const;
35 bool operator!=( const GeoDataListStyle &other ) const;
36
37 ~GeoDataListStyle() override;
38
39 /** Provides type information for downcasting a GeoNode */
40 const char* nodeType() const override;
41
42 enum ListItemType {
43 Check,
44 RadioFolder,
45 CheckOffOnly,
46 CheckHideChildren
47 };
48
49 ListItemType listItemType() const;
50 void setListItemType(ListItemType type);
51
52 QColor backgroundColor() const;
53 void setBackgroundColor( const QColor &color );
54
55 QVector<GeoDataItemIcon*> itemIconList() const;
56
57 GeoDataItemIcon* child( int );
58
59 const GeoDataItemIcon* child( int ) const;
60
61 int childPosition( const GeoDataItemIcon *child ) const;
62
63 void append( GeoDataItemIcon *other );
64
65 void remove( int index );
66
67 int size() const;
68
69 GeoDataItemIcon& at( int pos );
70 const GeoDataItemIcon& at( int pos ) const;
71
72 GeoDataItemIcon& last();
73 const GeoDataItemIcon& last() const;
74
75 GeoDataItemIcon& first();
76 const GeoDataItemIcon& first() const;
77
82 void clear();
83
84 void pack( QDataStream& stream ) const override;
85
86 void unpack( QDataStream& stream ) override;
87
88private:
89 friend class GeoDataItemIcon;
90 GeoDataListStylePrivate* const d;
91};
92
93}
94
95#endif
KGuiItem remove()
KGuiItem clear()
const QList< QKeySequence > & begin()
const QList< QKeySequence > & end()
Binds a QML item to a specific geodetic location in screen coordinates.
bool operator==(const QGraphicsApiFilter &reference, const QGraphicsApiFilter &sample)
bool operator!=(const QGraphicsApiFilter &reference, const QGraphicsApiFilter &sample)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:18:17 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.