marble
#include <MarbleModel.h>
Public Slots | |
void | clearPersistentTileCache () |
void | setPersistentTileCacheLimit (quint64 kiloBytes) |
void | setTrackedPlacemark (const GeoDataPlacemark *placemark) |
void | updateProperty (const QString &property, bool value) |
Signals | |
void | creatingTilesStart (TileCreator *, const QString &name, const QString &description) |
void | homeChanged (const GeoDataCoordinates newHomePoint) |
void | themeChanged (QString mapTheme) |
void | trackedPlacemarkChanged (const GeoDataPlacemark *placemark) |
void | workOfflineChanged () |
Properties | |
QString | mapThemeId |
bool | workOffline |
Detailed Description
The data model (not based on QAbstractModel) for a MarbleWidget.
This class provides a data storage and indexer that can be displayed in a MarbleWidget. It contains 3 different datatypes: tiles which provide the background, vectors which provide things like country borders and coastlines and placemarks which can show points of interest, such as cities, mountain tops or the poles.
The tiles provide the background of the image and can be for instance height and depth fields, magnetic strength, topographic data or anything else that is area based.
The vectors provide things like country borders and coastlines. They are stored in separate files and can be added or removed at anytime.
The placemarks contain points of interest, such as cities, mountain tops or the poles. These are sorted by size (for cities) and category (capitals, other important cities, less important cities, etc) and are displayed with different color or shape like square or round.
- See also
- MarbleWidget
Definition at line 96 of file MarbleModel.h.
Constructor & Destructor Documentation
|
explicit |
Construct a new MarbleModel.
- Parameters
-
parent the parent widget
Definition at line 161 of file MarbleModel.cpp.
|
virtual |
Definition at line 196 of file MarbleModel.cpp.
Member Function Documentation
void Marble::MarbleModel::addGeoDataFile | ( | const QString & | filename | ) |
Handle file loading into the treeModel.
- Parameters
-
filename the file to load
Definition at line 655 of file MarbleModel.cpp.
void Marble::MarbleModel::addGeoDataString | ( | const QString & | data, |
const QString & | key = "data" |
||
) |
Handle raw data loading into the treeModel.
- Parameters
-
data the raw data to load key the name to remove this raw data later
Definition at line 661 of file MarbleModel.cpp.
BookmarkManager * Marble::MarbleModel::bookmarkManager | ( | ) |
return instance of BookmarkManager
Definition at line 206 of file MarbleModel.cpp.
|
slot |
Definition at line 492 of file MarbleModel.cpp.
MarbleClock * Marble::MarbleModel::clock | ( | ) |
Definition at line 467 of file MarbleModel.cpp.
const MarbleClock * Marble::MarbleModel::clock | ( | ) | const |
Definition at line 472 of file MarbleModel.cpp.
QDateTime Marble::MarbleModel::clockDateTime | ( | ) | const |
Definition at line 620 of file MarbleModel.cpp.
int Marble::MarbleModel::clockSpeed | ( | ) | const |
Definition at line 625 of file MarbleModel.cpp.
int Marble::MarbleModel::clockTimezone | ( | ) | const |
Definition at line 640 of file MarbleModel.cpp.
|
signal |
Signal that the MarbleModel has started to create a new set of tiles.
- Parameters
-
HttpDownloadManager * Marble::MarbleModel::downloadManager | ( | ) |
Return the downloadmanager to load missing tiles.
- Returns
- the HttpDownloadManager instance.
Definition at line 396 of file MarbleModel.cpp.
const HttpDownloadManager * Marble::MarbleModel::downloadManager | ( | ) | const |
Definition at line 401 of file MarbleModel.cpp.
ElevationModel * Marble::MarbleModel::elevationModel | ( | ) |
Definition at line 699 of file MarbleModel.cpp.
const ElevationModel * Marble::MarbleModel::elevationModel | ( | ) | const |
Definition at line 704 of file MarbleModel.cpp.
FileManager * Marble::MarbleModel::fileManager | ( | ) |
Definition at line 447 of file MarbleModel.cpp.
QAbstractItemModel * Marble::MarbleModel::groundOverlayModel | ( | ) |
Definition at line 427 of file MarbleModel.cpp.
const QAbstractItemModel * Marble::MarbleModel::groundOverlayModel | ( | ) | const |
Definition at line 432 of file MarbleModel.cpp.
void Marble::MarbleModel::home | ( | qreal & | lon, |
qreal & | lat, | ||
int & | zoom | ||
) | const |
get the home point
- Parameters
-
lon the longitude of the home point. lat the latitude of the home point. zoom the default zoom level of the home point.
Definition at line 376 of file MarbleModel.cpp.
|
signal |
QTextDocument * Marble::MarbleModel::legend | ( | ) |
Definition at line 645 of file MarbleModel.cpp.
GeoSceneDocument * Marble::MarbleModel::mapTheme | ( | ) |
Definition at line 221 of file MarbleModel.cpp.
const GeoSceneDocument * Marble::MarbleModel::mapTheme | ( | ) | const |
Definition at line 226 of file MarbleModel.cpp.
QString Marble::MarbleModel::mapThemeId | ( | ) | const |
Return the name of the current map theme.
- Returns
- the identifier of the current MapTheme. To ensure that a unique identifier is being used the theme does NOT get represented by its name but the by relative location of the file that specifies the theme:
Example: maptheme = "earth/bluemarble/bluemarble.dgml"
quint64 Marble::MarbleModel::persistentTileCacheLimit | ( | ) | const |
Returns the limit in kilobytes of the persistent (on hard disc) tile cache.
- Returns
- the limit of persistent tile cache in kilobytes.
Definition at line 487 of file MarbleModel.cpp.
QAbstractItemModel * Marble::MarbleModel::placemarkModel | ( | ) |
Definition at line 417 of file MarbleModel.cpp.
const QAbstractItemModel * Marble::MarbleModel::placemarkModel | ( | ) | const |
Definition at line 422 of file MarbleModel.cpp.
QItemSelectionModel * Marble::MarbleModel::placemarkSelectionModel | ( | ) |
Definition at line 437 of file MarbleModel.cpp.
const Planet * Marble::MarbleModel::planet | ( | ) | const |
Returns the planet object for the current map.
- Returns
- the planet object for the current map
Definition at line 574 of file MarbleModel.cpp.
QString Marble::MarbleModel::planetId | ( | ) | const |
Definition at line 462 of file MarbleModel.cpp.
QString Marble::MarbleModel::planetName | ( | ) | const |
Definition at line 457 of file MarbleModel.cpp.
qreal Marble::MarbleModel::planetRadius | ( | ) | const |
Definition at line 452 of file MarbleModel.cpp.
const PluginManager * Marble::MarbleModel::pluginManager | ( | ) | const |
Definition at line 564 of file MarbleModel.cpp.
PluginManager * Marble::MarbleModel::pluginManager | ( | ) |
Definition at line 569 of file MarbleModel.cpp.
PositionTracking * Marble::MarbleModel::positionTracking | ( | ) | const |
Definition at line 442 of file MarbleModel.cpp.
void Marble::MarbleModel::removeGeoData | ( | const QString & | key | ) |
Remove the file or raw data from the treeModel.
- Parameters
-
key either the file name or the key for raw data
Definition at line 666 of file MarbleModel.cpp.
RoutingManager * Marble::MarbleModel::routingManager | ( | ) |
Definition at line 605 of file MarbleModel.cpp.
const RoutingManager * Marble::MarbleModel::routingManager | ( | ) | const |
Definition at line 610 of file MarbleModel.cpp.
void Marble::MarbleModel::setClockDateTime | ( | const QDateTime & | datetime | ) |
Definition at line 615 of file MarbleModel.cpp.
void Marble::MarbleModel::setClockSpeed | ( | int | speed | ) |
Definition at line 630 of file MarbleModel.cpp.
void Marble::MarbleModel::setClockTimezone | ( | int | timeInSec | ) |
Definition at line 635 of file MarbleModel.cpp.
void Marble::MarbleModel::setHome | ( | qreal | lon, |
qreal | lat, | ||
int | zoom = 1050 |
||
) |
Set the home point.
- Parameters
-
lon the longitude of the new home point. lat the latitude of the new home point. zoom the default zoom level for the new home point.
Definition at line 382 of file MarbleModel.cpp.
void Marble::MarbleModel::setHome | ( | const GeoDataCoordinates & | homePoint, |
int | zoom = 1050 |
||
) |
Set the home point.
- Parameters
-
homePoint the new home point. zoom the default zoom level for the new home point.
Definition at line 389 of file MarbleModel.cpp.
void Marble::MarbleModel::setLegend | ( | QTextDocument * | document | ) |
Definition at line 650 of file MarbleModel.cpp.
void Marble::MarbleModel::setMapThemeId | ( | const QString & | mapThemeId | ) |
Set a new map theme to use.
- Parameters
-
mapThemeId the identifier of the new map theme
This function sets the map theme, i.e. combination of tile set and color scheme to use. If the map theme is not previously used, some basic tiles are created and a progress dialog is shown.
The ID of the new maptheme. To ensure that a unique identifier is being used the theme does NOT get represented by its name but the by relative location of the file that specifies the theme:
Example: maptheme = "earth/bluemarble/bluemarble.dgml"
Definition at line 240 of file MarbleModel.cpp.
|
slot |
Set the limit of the persistent (on hard disc) tile cache.
- Parameters
-
bytes The limit in kilobytes, 0 means no limit.
Definition at line 537 of file MarbleModel.cpp.
|
slot |
Change the placemark tracked by this model.
Definition at line 553 of file MarbleModel.cpp.
void Marble::MarbleModel::setWorkOffline | ( | bool | workOffline | ) |
Definition at line 689 of file MarbleModel.cpp.
SunLocator * Marble::MarbleModel::sunLocator | ( | ) |
Definition at line 477 of file MarbleModel.cpp.
const SunLocator * Marble::MarbleModel::sunLocator | ( | ) | const |
Definition at line 482 of file MarbleModel.cpp.
|
signal |
Signal that the map theme has changed, and to which theme.
- Parameters
-
mapTheme the identifier of the new map theme.
- See also
- mapTheme
- setMapTheme
const GeoDataPlacemark * Marble::MarbleModel::trackedPlacemark | ( | ) | const |
Returns the placemark being tracked by this model or 0 if no placemark is currently tracked.
Definition at line 559 of file MarbleModel.cpp.
|
signal |
Emitted when the placemark tracked by this model has changed.
- See also
- setTrackedPlacemark(), trackedPlacemark()
GeoDataTreeModel * Marble::MarbleModel::treeModel | ( | ) |
Return the list of Placemarks as a QAbstractItemModel *.
- Returns
- a list of all Placemarks in the MarbleModel.
Definition at line 407 of file MarbleModel.cpp.
const GeoDataTreeModel * Marble::MarbleModel::treeModel | ( | ) | const |
Definition at line 412 of file MarbleModel.cpp.
|
slot |
Definition at line 671 of file MarbleModel.cpp.
quint64 Marble::MarbleModel::volatileTileCacheLimit | ( | ) | const |
Returns the limit of the volatile (in RAM) tile cache.
- Returns
- the cache limit in kilobytes
bool Marble::MarbleModel::workOffline | ( | ) | const |
|
signal |
Property Documentation
|
readwrite |
Definition at line 102 of file MarbleModel.h.
|
readwrite |
Definition at line 103 of file MarbleModel.h.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 22:38:56 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.