GeoDataFeature Class Reference
from PyKDE4.marble import *
Inherits: Marble.GeoDataObject → Marble.GeoNode
Subclasses: Marble.GeoDataContainer, Marble.GeoDataPlacemark
Namespace: Marble
Detailed Description
A base class for all geodata features
GeoDataFeature is the base class for most geodata classes that correspond to places on a map. It is never instantiated by itself, but is always used as part of a derived class.
- See also:
- GeoDataPlacemark
- See also:
- GeoDataContainer
Enumerations | |
GeoDataVisualCategory | { None, Default, Unknown, SmallCity, SmallCountyCapital, SmallStateCapital, SmallNationCapital, MediumCity, MediumCountyCapital, MediumStateCapital, MediumNationCapital, BigCity, BigCountyCapital, BigStateCapital, BigNationCapital, LargeCity, LargeCountyCapital, LargeStateCapital, LargeNationCapital, Nation, Mountain, Volcano, Mons, Valley, Continent, Ocean, OtherTerrain, Crater, Mare, GeographicPole, MagneticPole, ShipWreck, AirPort, Wikipedia, OsmSite, Coordinate, MannedLandingSite, RoboticRover, UnmannedSoftLandingSite, UnmannedHardLandingSite, LastIndex } |
Methods | |
__init__ (self, Marble.GeoDataObject parent=0) | |
__init__ (self, QString name, Marble.GeoDataObject parent=0) | |
__init__ (self, Marble.GeoDataFeature a0) | |
QString | address (self) |
QString | description (self) |
EnumFeatureId | featureId (self) |
bool | isFolder (self) |
bool | isPlacemark (self) |
bool | isVisible (self) |
QString | name (self) |
pack (self, QDataStream stream) | |
QString | phoneNumber (self) |
long | popularity (self) |
int | popularityIndex (self) |
QChar | role (self) |
setAddress (self, QString value) | |
setDescription (self, QString value) | |
setName (self, QString value) | |
setPhoneNumber (self, QString value) | |
setPopularity (self, long popularity) | |
setPopularityIndex (self, int index) | |
setRole (self, QChar role) | |
setStyle (self, Marble.GeoDataStyle style) | |
setStyleMap (self, Marble.GeoDataStyleMap map) | |
setStyleUrl (self, QString value) | |
setVisible (self, bool value) | |
setVisualCategory (self, Marble.GeoDataFeature.GeoDataVisualCategory category) | |
Marble.GeoDataStyle | style (self) |
Marble.GeoDataStyleMap | styleMap (self) |
QString | styleUrl (self) |
QPixmap | symbolPixmap (self) |
QSize | symbolSize (self) |
unpack (self, QDataStream stream) | |
Marble.GeoDataFeature.GeoDataVisualCategory | visualCategory (self) |
Static Methods | |
QFont | defaultFont () |
resetDefaultStyles () | |
setDefaultFont (QFont font) |
Method Documentation
__init__ | ( | self, | ||
Marble.GeoDataObject | parent=0 | |||
) |
__init__ | ( | self, | ||
QString | name, | |||
Marble.GeoDataObject | parent=0 | |||
) |
Create a new GeoDataFeature with name as its name.
__init__ | ( | self, | ||
Marble.GeoDataFeature | a0 | |||
) |
QString address | ( | self ) |
Return the address of the feature
QFont defaultFont | ( | ) |
QString description | ( | self ) |
Return the text description of the feature.
EnumFeatureId featureId | ( | self ) |
bool isFolder | ( | self ) |
bool isPlacemark | ( | self ) |
bool isVisible | ( | self ) |
Return whether this feature is visible or not
QString name | ( | self ) |
The name of the feature
The name of the feature should be a short string. It is often shown directly on the map and need therefore not take up much space.
- Returns:
- The name of this feature
pack | ( | self, | ||
QDataStream | stream | |||
) |
Serialize the contents of the feature to stream.
QString phoneNumber | ( | self ) |
Return the phone number of the feature
long popularity | ( | self ) |
Return the popularity of the feature.
int popularityIndex | ( | self ) |
Return the popularity index of the placemark.
The popularity index is a value which describes at which zoom level the placemark will be shown.
resetDefaultStyles | ( | ) |
Return the label font of the placemark.
QChar role | ( | self ) |
Return the role of the placemark.
FIXME: describe roles here!
setAddress | ( | self, | ||
QString | value | |||
) |
Set the address of this feature to value.
setDefaultFont | ( | QFont | font | |
) |
setDescription | ( | self, | ||
QString | value | |||
) |
Set the description of this feature to value.
setName | ( | self, | ||
QString | value | |||
) |
Set a new name for this feature
- Parameters:
-
value the new name
setPhoneNumber | ( | self, | ||
QString | value | |||
) |
Set the phone number of this feature to value.
setPopularity | ( | self, | ||
long | popularity | |||
) |
Sets the popularity of the feature.
- Parameters:
-
popularity the new popularity value
setPopularityIndex | ( | self, | ||
int | index | |||
) |
Sets the popularity index of the placemark.
- Parameters:
-
index the new index to be used.
setRole | ( | self, | ||
QChar | role | |||
) |
Sets the role of the placemark.
- Parameters:
-
role the new role to be used.
setStyle | ( | self, | ||
Marble.GeoDataStyle | style | |||
) |
Sets the style of the placemark.
- Parameters:
-
style the new style to be used.
setStyleMap | ( | self, | ||
Marble.GeoDataStyleMap | map | |||
) |
Sets the styleMap of the feature
setStyleUrl | ( | self, | ||
QString | value | |||
) |
Set the styleUrl of this feature to value.
setVisible | ( | self, | ||
bool | value | |||
) |
Set a new value for visibility
- Parameters:
-
value new value for the visibility
This function sets the visibility, i.e. whether this feature should be shown or not. This can be changed either from a GUI or through some action of the program.
setVisualCategory | ( | self, | ||
Marble.GeoDataFeature.GeoDataVisualCategory | category | |||
) |
Sets the symbol index of the placemark.
- Parameters:
-
category the new category to be used.
Marble.GeoDataStyle style | ( | self ) |
Return the style assigned to the placemark.
Marble.GeoDataStyleMap styleMap | ( | self ) |
Return a pointer to a GeoDataStyleMap object which represents the styleMap of this feature. A styleMap is simply a QMap<QString,QString> which can connect two styles with a keyword. This can be used to have a highlighted and a normal style.
- See also:
- GeoDataStyleMap
QString styleUrl | ( | self ) |
Return the styleUrl of the feature.
QPixmap symbolPixmap | ( | self ) |
Return the symbol of the feature as a pixmap.
Note that the pixmaps are shared between all features with the same visual category
QSize symbolSize | ( | self ) |
Return the symbol size of the feature in pixels.
unpack | ( | self, | ||
QDataStream | stream | |||
) |
Unserialize the contents of the feature from stream.
Marble.GeoDataFeature.GeoDataVisualCategory visualCategory | ( | self ) |
Return the symbol index of the placemark.
Enumeration Documentation
GeoDataVisualCategory |
A categorization of a placemark as defined by ...FIXME.
- Enumerator:
-
None Default Unknown SmallCity SmallCountyCapital SmallStateCapital SmallNationCapital MediumCity MediumCountyCapital MediumStateCapital MediumNationCapital BigCity BigCountyCapital BigStateCapital BigNationCapital LargeCity LargeCountyCapital LargeStateCapital LargeNationCapital Nation Mountain Volcano Mons Valley Continent Ocean OtherTerrain Crater Mare GeographicPole MagneticPole ShipWreck AirPort Wikipedia OsmSite Coordinate MannedLandingSite RoboticRover UnmannedSoftLandingSite UnmannedHardLandingSite LastIndex