KGAPI2::StaticMapMarker

Search for usage in LXR

KGAPI2::StaticMapMarker Class Reference

#include <staticmapmarker.h>

Public Types

enum  LocationType { Undefined = -1 , String , KABCAddress , KABCGeo }
 
enum  MarkerSize { Tiny , Small , Middle , Normal }
 

Public Member Functions

 StaticMapMarker ()
 
 StaticMapMarker (const KContacts::Address &address, QChar label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const KContacts::Address::List &locations, QChar label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const KContacts::Geo &address, QChar label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const QList< KContacts::Geo > &locations, QChar label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const QString &address, const QChar &label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const QStringList &locations, QChar label=QChar(), const MarkerSize size=Normal, const QColor &color=Qt::red)
 
 StaticMapMarker (const StaticMapMarker &other)
 
 ~StaticMapMarker ()
 
QColor color () const
 
bool isValid () const
 
QChar label () const
 
KContacts::Address::List locationsAddress () const
 
QList< KContacts::GeolocationsGeo () const
 
QStringList locationsString () const
 
LocationType locationType () const
 
StaticMapMarkeroperator= (const StaticMapMarker &other)
 
void setColor (const QColor &color)
 
void setLabel (QChar label)
 
void setLocation (const KContacts::Address &location)
 
void setLocation (const KContacts::Geo &location)
 
void setLocation (const QString &location)
 
void setLocations (const KContacts::Address::List &locations)
 
void setLocations (const QList< KContacts::Geo > &locations)
 
void setLocations (const QStringList &locations)
 
void setSize (const MarkerSize size)
 
MarkerSize size () const
 
QString toString () const
 

Detailed Description

Represents marker with defined label, color, size and markers.

Author
: Jan Grulich grulj.nosp@m.a@gm.nosp@m.ail.c.nosp@m.om
Since
: 0.4

Definition at line 25 of file staticmapmarker.h.

Member Enumeration Documentation

◆ LocationType

enum KGAPI2::StaticMapMarker::LocationType

Definition at line 30 of file staticmapmarker.h.

◆ MarkerSize

enum KGAPI2::StaticMapMarker::MarkerSize

Definition at line 28 of file staticmapmarker.h.

Constructor & Destructor Documentation

◆ StaticMapMarker() [1/8]

StaticMapMarker::StaticMapMarker ( )

Constructs an empty marker.

Definition at line 50 of file staticmapmarker.cpp.

◆ StaticMapMarker() [2/8]

StaticMapMarker::StaticMapMarker ( const QString & address,
const QChar & label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
addressLocation in QString where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 55 of file staticmapmarker.cpp.

◆ StaticMapMarker() [3/8]

StaticMapMarker::StaticMapMarker ( const KContacts::Address & address,
QChar label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
addressLocation in KContacts::Address where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 67 of file staticmapmarker.cpp.

◆ StaticMapMarker() [4/8]

StaticMapMarker::StaticMapMarker ( const KContacts::Geo & address,
QChar label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
addressLocation in KContacts::Geo where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 79 of file staticmapmarker.cpp.

◆ StaticMapMarker() [5/8]

StaticMapMarker::StaticMapMarker ( const QStringList & locations,
QChar label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
locationsLocations as a QStringList where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 91 of file staticmapmarker.cpp.

◆ StaticMapMarker() [6/8]

StaticMapMarker::StaticMapMarker ( const KContacts::Address::List & locations,
QChar label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
locationsLocations in KContacts::Address where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 101 of file staticmapmarker.cpp.

◆ StaticMapMarker() [7/8]

StaticMapMarker::StaticMapMarker ( const QList< KContacts::Geo > & locations,
QChar label = QChar(),
const MarkerSize size = Normal,
const QColor & color = Qt::red )
explicit

Constructs a new marker.

Parameters
locationsLocations in KContacts::Geo where marker will be visible
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker
sizeSpecifies the size of marker
colorColor of marker

Definition at line 111 of file staticmapmarker.cpp.

◆ StaticMapMarker() [8/8]

StaticMapMarker::StaticMapMarker ( const StaticMapMarker & other)

Copy constructor.

Definition at line 121 of file staticmapmarker.cpp.

◆ ~StaticMapMarker()

StaticMapMarker::~StaticMapMarker ( )

Destructor.

Definition at line 126 of file staticmapmarker.cpp.

Member Function Documentation

◆ color()

QColor StaticMapMarker::color ( ) const
nodiscard

Returns color of marker.

Definition at line 136 of file staticmapmarker.cpp.

◆ isValid()

bool StaticMapMarker::isValid ( ) const
nodiscard

Returns if marker is valid.

It means that marker needs defined location

Definition at line 146 of file staticmapmarker.cpp.

◆ label()

QChar StaticMapMarker::label ( ) const
nodiscard

Returns label of marker.

Definition at line 151 of file staticmapmarker.cpp.

◆ locationsAddress()

KContacts::Address::List StaticMapMarker::locationsAddress ( ) const
nodiscard

Returns locations in KContacts::Address.

Definition at line 183 of file staticmapmarker.cpp.

◆ locationsGeo()

QList< KContacts::Geo > StaticMapMarker::locationsGeo ( ) const
nodiscard

Returns locations in KContacts::Geo.

Definition at line 205 of file staticmapmarker.cpp.

◆ locationsString()

QStringList StaticMapMarker::locationsString ( ) const
nodiscard

Returns locations in QString.

Definition at line 161 of file staticmapmarker.cpp.

◆ locationType()

StaticMapMarker::LocationType StaticMapMarker::locationType ( ) const
nodiscard

Returns in which format is location saved.

Definition at line 131 of file staticmapmarker.cpp.

◆ operator=()

StaticMapMarker & StaticMapMarker::operator= ( const StaticMapMarker & other)

Assignment operator.

Definition at line 288 of file staticmapmarker.cpp.

◆ setColor()

void StaticMapMarker::setColor ( const QColor & color)

Sets color of marker.

Parameters
colorColor for marker

Definition at line 141 of file staticmapmarker.cpp.

◆ setLabel()

void StaticMapMarker::setLabel ( QChar label)

Sets label of marker.

Parameters
labelSpecifies a single uppercase alphanumeric character from set {A-Z, 0-9} which will be displayed in the marker

Definition at line 156 of file staticmapmarker.cpp.

◆ setLocation() [1/3]

void StaticMapMarker::setLocation ( const KContacts::Address & location)

Sets one location for marker.

Parameters
locationLocation for marker in KContacts::Address

Definition at line 188 of file staticmapmarker.cpp.

◆ setLocation() [2/3]

void StaticMapMarker::setLocation ( const KContacts::Geo & location)

Sets one location for marker.

Parameters
locationLocation for marker in KContacts::Geo

Definition at line 210 of file staticmapmarker.cpp.

◆ setLocation() [3/3]

void StaticMapMarker::setLocation ( const QString & location)

Sets one location for marker.

Parameters
locationLocation for marker in QString

Definition at line 166 of file staticmapmarker.cpp.

◆ setLocations() [1/3]

void StaticMapMarker::setLocations ( const KContacts::Address::List & locations)

Sets locations for marker.

Parameters
locationsLocations for marker in KContacts::Address

Definition at line 197 of file staticmapmarker.cpp.

◆ setLocations() [2/3]

void StaticMapMarker::setLocations ( const QList< KContacts::Geo > & locations)

Sets locations for marker.

Parameters
locationsLocations for marker in KContacts::Geo

Definition at line 219 of file staticmapmarker.cpp.

◆ setLocations() [3/3]

void StaticMapMarker::setLocations ( const QStringList & locations)

Sets locations for marker.

Parameters
locationsLocations for marker in QString

Definition at line 175 of file staticmapmarker.cpp.

◆ setSize()

void StaticMapMarker::setSize ( const MarkerSize size)

Sets size of marker.

Parameters
sizeSpecifies the size of marker

Definition at line 232 of file staticmapmarker.cpp.

◆ size()

StaticMapMarker::MarkerSize StaticMapMarker::size ( ) const
nodiscard

Returns size of marker.

Definition at line 227 of file staticmapmarker.cpp.

◆ toString()

QString StaticMapMarker::toString ( ) const
nodiscard

Returns all locations and markers preferences in format to URL query.

Definition at line 237 of file staticmapmarker.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Jul 26 2024 11:57:07 by doxygen 1.11.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.