KDE 4.7 PyKDE API Reference

- KDE's Python API

# MarbleWidget Class Reference

`from PyKDE4.marble import *`

Inherits: QWidget → QObject
Namespace: Marble

## Detailed Description

A widget class that displays a view of the earth.

This widget displays a view of the earth or any other globe, depending on which dataset is used. The user can navigate the globe using either a control widget, e.g. the MarbleControlBox, or the mouse. The mouse and keyboard control is done through a MarbleWidgetInputHandler. Only some aspects of the widget can be controlled by the mouse and/or keyboard.

By clicking on the globe and moving the mouse, the position can be changed. The user can also zoom by using the scroll wheel of the mouse in the widget. The zoom value is not tied to any units, but is an abstract value without any physical meaning. A value around 1000 shows the full globe in a normal-sized window. Higher zoom values give a more zoomed-in view.

The MarbleWidget needs to be provided with a data model to work. This model is contained in the MarbleModel class, and it is painted by using a MarbleMap. The widget can also construct its own map and model if none is given to the constructor. A MarbleModel contains 3 separate 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.

In addition to navigating with the mouse, you can also use it to get information about items on the map. You can either click on a placemark with the left mouse button or with the right mouse button anywhere on the map.

The left mouse button opens up a menu with all the placemarks within a certain distance from the mouse pointer. When you choose one item from the menu, Marble will open up a dialog window with some information about the placemark and also try to connect to Wikipedia to retrieve an article about it. If there is such an article, you will get a mini-browser window with the article in a tab.

The right mouse button controls a distance tool. The distance tool is implemented as a menu where you can choose to either create or remove so called Measure Points. Marble will keep track of the Measure Points and show the total distance in the upper left of the widget. Measure Points are shown on the map as a little white cross.

See also:
  MarbleControlBox

See also:
  MarbleMap

See also:
  MarbleModel

## Signals
| distanceChanged (QString distanceString)
| framesPerSecond (float fps)
| mouseClickGeoPosition (float lon, float lat, Marble.GeoDataCoordinates.Unit a2)
| mouseMoveGeoPosition (QString a0)
| pluginSettingsChanged ()
| projectionChanged (Marble.Projection a0)
| renderPluginInitialized (Marble.RenderPlugin renderPlugin)
| themeChanged (QString theme)
| tileLevelChanged (int level)
| visibleLatLonAltBoxChanged (Marble.GeoDataLatLonAltBox visibleLatLonAltBox)
| zoomChanged (int zoom)
## Methods
| __init__ (self, QWidget parent=0)
| addLayer (self, Marble.LayerInterface layer)
bool | animationsEnabled (self)
float | centerLatitude (self)
float | centerLongitude (self)
| centerOn (self, Marble.GeoDataCoordinates point, bool animated=0)
| centerOn (self, Marble.GeoDataLatLonBox box, bool animated=0)
| centerOn (self, float lon, float lat, bool animated=0)
| centerOn (self, Marble.GeoDataPlacemark placemark, bool animated=0)
| changeEvent (self, QEvent event)
| clearVolatileTileCache (self)
| connectNotify (self, QString signal)
| creatingTilesStart (self, Marble.TileCreator creator, QString name, QString description)
| customPaint (self, Marble.GeoPainter painter)
Marble.AngleUnit | defaultAngleUnit (self)
QFont | defaultFont (self)
| disconnectNotify (self, QString signal)
float | distance (self)
float | distanceFromRadius (self, float radius)
float | distanceFromZoom (self, float zoom)
QString | distanceString (self)
| downloadRegion (self, QString sourceDir, QVector a1)
Marble.AbstractFloatItem | floatItem (self, QString nameId)
[Marble.AbstractFloatItem] | floatItems (self)
| flyTo (self, Marble.GeoDataLookAt lookAt, Marble.FlyToMode mode=Marble.Automatic)
Marble.GeoDataCoordinates | focusPoint (self)
bool | geoCoordinates (self, int x, int y, float lon, float lat, Marble.GeoDataCoordinates.Unit a4=Marble.GeoDataCoordinates.Degree)
| goHome (self, Marble.FlyToMode mode=Marble.Automatic)
| leaveEvent (self, QEvent event)
Marble.GeoDataLookAt | lookAt (self)
Marble.MapQuality | mapQuality (self, Marble.ViewContext a0=Marble.Still)
QRegion | mapRegion (self)
QPixmap | mapScreenShot (self)
QString | mapThemeId (self)
int | maximumZoom (self)
int | minimumZoom (self)
Marble.MarbleModel | model (self)
| moveDown (self, Marble.FlyToMode mode=Marble.Automatic)
| moveLeft (self, Marble.FlyToMode mode=Marble.Automatic)
| moveRight (self, Marble.FlyToMode mode=Marble.Automatic)
float | moveStep (self)
| moveUp (self, Marble.FlyToMode mode=Marble.Automatic)
| notifyMouseClick (self, int x, int y)
| paintEvent (self, QPaintEvent event)
Marble.Projection | projection (self)
int | radius (self)
float | radiusFromDistance (self, float distance)
| readPluginSettings (self, QSettings settings)
| reloadMap (self)
| removeLayer (self, Marble.LayerInterface layer)
[Marble.RenderPlugin] | renderPlugins (self)
| resetFocusPoint (self)
| resizeEvent (self, QResizeEvent a0)
| rotateBy (self, float deltaLon, float deltaLat, Marble.FlyToMode mode=Marble.Instant)
bool | screenCoordinates (self, float lon, float lat, float x, float y)
| setAnimationsEnabled (self, bool enabled)
| setCenterLatitude (self, float lat, Marble.FlyToMode mode=Marble.Instant)
| setCenterLongitude (self, float lon, Marble.FlyToMode mode=Marble.Instant)
| setDefaultAngleUnit (self, Marble.AngleUnit angleUnit)
| setDefaultFont (self, QFont font)
| setDistance (self, float distance)
| setFocusPoint (self, Marble.GeoDataCoordinates focusPoint)
| setInputEnabled (self, bool a0)
| setMapQualityForViewContext (self, Marble.MapQuality quality, Marble.ViewContext viewContext)
| setMapThemeId (self, QString maptheme)
| setProjection (self, int projection)
| setProjection (self, Marble.Projection projection)
| setPropertyValue (self, QString name, bool value)
| setRadius (self, int radius)
| setSelection (self, QRect region)
| setShowAtmosphere (self, bool visible)
| setShowBackground (self, bool visible)
| setShowBorders (self, bool visible)
| setShowCities (self, bool visible)
| setShowCityLights (self, bool visible)
| setShowClouds (self, bool visible)
| setShowCompass (self, bool visible)
| setShowCrosshairs (self, bool visible)
| setShowFrameRate (self, bool visible)
| setShowGrid (self, bool visible)
| setShowIceLayer (self, bool visible)
| setShowLakes (self, bool visible)
| setShowOtherPlaces (self, bool visible)
| setShowOverviewMap (self, bool visible)
| setShowPlaces (self, bool visible)
| setShowRelief (self, bool visible)
| setShowRivers (self, bool visible)
| setShowScaleBar (self, bool visible)
| setShowSunInZenith (self, bool visible)
| setShowSunShading (self, bool visible)
| setShowTerrain (self, bool visible)
| setShowTileId (self, bool visible)
| setViewContext (self, Marble.ViewContext viewContext)
| setVolatileTileCacheLimit (self, long kiloBytes)
bool | showAtmosphere (self)
bool | showBackground (self)
bool | showBorders (self)
bool | showCities (self)
bool | showCityLights (self)
bool | showClouds (self)
bool | showCompass (self)
bool | showCrosshairs (self)
bool | showFrameRate (self)
bool | showGrid (self)
bool | showIceLayer (self)
bool | showLakes (self)
bool | showOtherPlaces (self)
bool | showOverviewMap (self)
bool | showPlaces (self)
bool | showRelief (self)
bool | showRivers (self)
bool | showScaleBar (self)
bool | showSunInZenith (self)
bool | showSunShading (self)
bool | showTerrain (self)
int | tileZoomLevel (self)
Marble.ViewContext | viewContext (self)
Marble.ViewportParams | viewport (self)
long | volatileTileCacheLimit (self)
[Marble.AbstractDataPluginItem] | whichItemAt (self, QPoint curpos)
| writePluginSettings (self, QSettings settings)
int | zoom (self)
float | zoomFromDistance (self, float distance)
| zoomIn (self, Marble.FlyToMode mode=Marble.Automatic)
| zoomOut (self, Marble.FlyToMode mode=Marble.Automatic)
| zoomView (self, int zoom, Marble.FlyToMode mode=Marble.Instant)
| zoomViewBy (self, int zoomStep, Marble.FlyToMode mode=Marble.Instant)

## Signal Documentation

distanceChanged | ( | QString | distanceString
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("distanceChanged(const QString&)"), target_slot)`

framesPerSecond | ( | float | fps
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("framesPerSecond(qreal)"), target_slot)`

mouseClickGeoPosition | ( | float | lon,
|  | float | lat,
|  | Marble.GeoDataCoordinates.Unit | a2
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("mouseClickGeoPosition(qreal, qreal, Marble::GeoDataCoordinates::Unit)"), target_slot)`

mouseMoveGeoPosition | ( | QString | a0
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("mouseMoveGeoPosition(const QString&)"), target_slot)`

pluginSettingsChanged | ( |  | ) |

This signal is emit when the settings of a plugin changed.

Signal syntax:
  `QObject.connect(source, SIGNAL("pluginSettingsChanged()"), target_slot)`

projectionChanged | ( | Marble.Projection | a0
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("projectionChanged(Marble::Projection)"), target_slot)`

renderPluginInitialized | ( | Marble.RenderPlugin | renderPlugin
| ) |  |  |

Signal that a render item has been initialized

Signal syntax:
  `QObject.connect(source, SIGNAL("renderPluginInitialized(Marble::RenderPlugin*)"), target_slot)`

themeChanged | ( | QString | theme
| ) |  |  |

Signal that the theme has changed

Parameters:

  | theme | Name of the new theme.

Signal syntax:
  `QObject.connect(source, SIGNAL("themeChanged(const QString&)"), target_slot)`

tileLevelChanged | ( | int | level
| ) |  |  |

Signal syntax:
  `QObject.connect(source, SIGNAL("tileLevelChanged(int)"), target_slot)`

visibleLatLonAltBoxChanged | ( | Marble.GeoDataLatLonAltBox | visibleLatLonAltBox
| ) |  |  |

This signal is emitted when the visible region of the map changes. This typically happens when the user moves the map around or zooms.

Signal syntax:
  `QObject.connect(source, SIGNAL("visibleLatLonAltBoxChanged(const Marble::GeoDataLatLonAltBox&)"), target_slot)`

zoomChanged | ( | int | zoom
| ) |  |  |

Signal that the zoom has changed, and to what.

Parameters:

  | zoom | The new zoom value.

See also:
  zoomView()

Signal syntax:
  `QObject.connect(source, SIGNAL("zoomChanged(int)"), target_slot)`

## Method Documentation

__init__ | ( | self, |
|  | QWidget | parent=0
| ) |  |  |

Construct a new MarbleWidget.

Parameters:

  | parent | the parent widget

This constructor should be used when you will only use one MarbleWidget. The widget will create its own MarbleModel when created.

addLayer | ( | self, |
|  | Marble.LayerInterface | layer
| ) |  |  |

Add a layer to be included in rendering.

bool animationsEnabled | ( |  | self ) |

Retrieve whether travels to a point should get animated

float centerLatitude | ( |  | self ) |

Return the latitude of the center point.

Returns:
  The latitude of the center point in degree.

float centerLongitude | ( |  | self ) |

Return the longitude of the center point.

Returns:
  The longitude of the center point in degree.

centerOn | ( | self, |
|  | Marble.GeoDataCoordinates | point,
|  | bool | animated=0
| ) |  |  |

Center the view on a placemark according to the following logic: - if the placemark has a lookAt, zoom and center on that lookAt - otherwise use the placemark geometry's latLonAltBox

Parameters:

  | box | The GeoDataPlacemark to zoom and move the MarbleWidget to.

centerOn | ( | self, |
|  | Marble.GeoDataLatLonBox | box,
|  | bool | animated=0
| ) |  |  |

Center the view on a placemark according to the following logic: - if the placemark has a lookAt, zoom and center on that lookAt - otherwise use the placemark geometry's latLonAltBox

Parameters:

  | box | The GeoDataPlacemark to zoom and move the MarbleWidget to.

centerOn | ( | self, |
|  | float | lon,
|  | float | lat,
|  | bool | animated=0
| ) |  |  |

Center the view on a placemark according to the following logic: - if the placemark has a lookAt, zoom and center on that lookAt - otherwise use the placemark geometry's latLonAltBox

Parameters:

  | box | The GeoDataPlacemark to zoom and move the MarbleWidget to.

centerOn | ( | self, |
|  | Marble.GeoDataPlacemark | placemark,
|  | bool | animated=0
| ) |  |  |

Center the view on a placemark according to the following logic: - if the placemark has a lookAt, zoom and center on that lookAt - otherwise use the placemark geometry's latLonAltBox

Parameters:

  | box | The GeoDataPlacemark to zoom and move the MarbleWidget to.

changeEvent | ( | self, |
|  | QEvent | event
| ) |  |  |

Reimplementation of the changeEvent() function in QWidget to react to changes of the enabled state

clearVolatileTileCache | ( |  | self ) |

connectNotify | ( | self, |
|  | QString | signal
| ) |  |  |

creatingTilesStart | ( | self, |
|  | Marble.TileCreator | creator,
|  | QString | name,
|  | QString | description
| ) |  |  |

A slot that is called when the model starts to create new tiles.

Parameters:

  | creator | the tile creator object.
  | name | the name of the created theme.
  | description | a descriptive text that can be shown in a dialog.

See also:
  creatingTilesProgress

This function is connected to the models signal with the same name. When the model needs to create a cache of tiles in several different resolutions, it will emit creatingTilesStart once with a name of the theme and a descriptive text. The widget can then pop up a dialog to explain why there is a delay. The model will then call creatingTilesProgress several times until the parameter reaches 100 (100%), after which the creation process is finished. After this there will be no more calls to creatingTilesProgress, and the poup dialog can then be closed.

customPaint | ( | self, |
|  | Marble.GeoPainter | painter
| ) |  |  |

Enables custom drawing onto the MarbleWidget straight after the globe and before all other layers has been rendered.

Parameters:

  | painter |

Deprecated:
  implement LayerInterface and add it using addLayer()

Marble.AngleUnit defaultAngleUnit | ( |  | self ) |

QFont defaultFont | ( |  | self ) |

disconnectNotify | ( | self, |
|  | QString | signal
| ) |  |  |

float distance | ( |  | self ) |

Return the current distance.

float distanceFromRadius | ( | self, |
|  | float | radius
| ) |  |  |

Return the distance (km) at the given globe radius (pixel)

float distanceFromZoom | ( | self, |
|  | float | zoom
| ) |  |  |

Returns the distance (km) corresponding to the given zoom value

QString distanceString | ( |  | self ) |

Return the current distance string.

downloadRegion | ( | self, |
|  | QString | sourceDir,
|  | QVector | a1
| ) |  |  |

Marble.AbstractFloatItem floatItem | ( | self, |
|  | QString | nameId
| ) |  |  |

Returns the FloatItem with the given id

Returns:
  The pointer to the requested floatItem,

If no item is found the null pointer is returned.

[Marble.AbstractFloatItem] floatItems | ( |  | self ) |

Returns a list of all FloatItems on the widget

Returns:
  the list of the floatItems

flyTo | ( | self, |
|  | Marble.GeoDataLookAt | lookAt,
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Change the camera position to the given position.

Parameters:

  | lookAt | New camera position. Changing the camera position means that both the current center position as well as the zoom value may change
  | mode | Interpolation type for intermediate camera positions. Automatic (default) chooses a suitable interpolation among Instant, Lenar and Jump. Instant will directly set the new zoom and position values, while Linear results in a linear interpolation of intermediate center coordinates along the sphere and a linear interpolation of changes in the camera distance to the ground. Finally, Jump will behave the same as Linear with regard to the center position interpolation, but use a parabolic height increase towards the middle point of the intermediate positions. This appears like a jump of the camera.

Marble.GeoDataCoordinates focusPoint | ( |  | self ) |

Returns:
  The current point of focus, e.g. the point that is not moved when changing the zoom level. If not set, it defaults to the center point.

See also:
  centerLongitude centerLatitude setFocusPoint resetFocusPoint

bool geoCoordinates | ( | self, |
|  | int | x,
|  | int | y,
|  | float | lon,
|  | float | lat,
|  | Marble.GeoDataCoordinates.Unit | a4=Marble.GeoDataCoordinates.Degree
| ) |  |  |

Get the earth coordinates corresponding to a pixel in the widget.

Parameters:

  | x | the x coordinate of the pixel
  | y | the y coordinate of the pixel
  | lon | the longitude angle is returned through this parameter
  | lat | the latitude angle is returned through this parameter

Returns:
  true if the pixel (x, y) is within the globe

false if the pixel (x, y) is outside the globe, i.e. in space.

goHome | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Center the view on the default start point with the default zoom.

leaveEvent | ( | self, |
|  | QEvent | event
| ) |  |  |

Reimplementation of the leaveEvent() function in QWidget.

Marble.GeoDataLookAt lookAt | ( |  | self ) |

Return the lookAt

Marble.MapQuality mapQuality | ( | self, |
|  | Marble.ViewContext | a0=Marble.Still
| ) |  |  |

Retrieve the map quality depending on the view context

QRegion mapRegion | ( |  | self ) |

Return the projected region which describes the (shape of the) projected surface.

QPixmap mapScreenShot | ( |  | self ) |

Return a QPixmap with the current contents of the widget.

QString mapThemeId | ( |  | self ) |

Get the ID of the current map theme 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: mapThemeId = "earth/bluemarble/bluemarble.dgml"

int maximumZoom | ( |  | self ) |

Return the minimum zoom value for the current map theme.

int minimumZoom | ( |  | self ) |

Return the minimum zoom value for the current map theme.

Marble.MarbleModel model | ( |  | self ) |

Return the model that this view shows.

moveDown | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Move down by the moveStep.

moveLeft | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Move left by the moveStep.

moveRight | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Move right by the moveStep.

float moveStep | ( |  | self ) |

Return how much the map will move if one of the move slots are called.

Returns:
  The move step.

moveUp | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Move up by the moveStep.

notifyMouseClick | ( | self, |
|  | int | x,
|  | int | y
| ) |  |  |

Used to notify about the position of the mouse click

paintEvent | ( | self, |
|  | QPaintEvent | event
| ) |  |  |

Reimplementation of the paintEvent() function in QWidget.

Marble.Projection projection | ( |  | self ) |

Get the Projection used for the map

Returns:
  Spherical a Globe

Returns:
  Equirectangular a flat map

Returns:
  Mercator another flat map

int radius | ( |  | self ) |

Return the radius of the globe in pixels.

float radiusFromDistance | ( | self, |
|  | float | distance
| ) |  |  |

Return the globe radius (pixel) for the given distance (km)

readPluginSettings | ( | self, |
|  | QSettings | settings
| ) |  |  |

Reads the plugin settings from the passed QSettings. You shouldn't use this in a KDE application as these use KConfig. Here you could use MarblePart which is handling this automatically.

Parameters:

  | settings | The QSettings object to be used.

reloadMap | ( |  | self ) |

Re-download all visible tiles.

removeLayer | ( | self, |
|  | Marble.LayerInterface | layer
| ) |  |  |

Remove a layer from being included in rendering.

[Marble.RenderPlugin] renderPlugins | ( |  | self ) |

Returns a list of all RenderPlugins on the widget, this includes float items

Returns:
  the list of RenderPlugins

resetFocusPoint | ( |  | self ) |

Invalidate any focus point set with setFocusPoint.

See also:
  focusPoint setFocusPoint

resizeEvent | ( | self, |
|  | QResizeEvent | a0
| ) |  |  |

Reimplementation of the resizeEvent() function in QWidget.

rotateBy | ( | self, |
|  | float | deltaLon,
|  | float | deltaLat,
|  | Marble.FlyToMode | mode=Marble.Instant
| ) |  |  |

Rotate the view by the two angles phi and theta.

Parameters:

  |  | deltaLon an angle that specifies the change in terms of longitude
  |  | deltaLat an angle that specifies the change in terms of latitude

This function rotates the view by two angles, deltaLon ("theta") and deltaLat ("phi"). If we start at (0, 0), the result will be the exact equivalent of (lon, lat), otherwise the resulting angle will be the sum of the previous position and the two offsets.

bool screenCoordinates | ( | self, |
|  | float | lon,
|  | float | lat,
|  | float | x,
|  | float | y
| ) |  |  |

Get the screen coordinates corresponding to geographical coordinates in the widget.

Parameters:

  | lon | the lon coordinate of the requested pixel position
  | lat | the lat coordinate of the requested pixel position
  | x | the x coordinate of the pixel is returned through this parameter
  | y | the y coordinate of the pixel is returned through this parameter

Returns:
  true if the geographical coordinates are visible on the screen

false if the geographical coordinates are not visible on the screen

setAnimationsEnabled | ( | self, |
|  | bool | enabled
| ) |  |  |

Set whether travels to a point should get animated

setCenterLatitude | ( | self, |
|  | float | lat,
|  | Marble.FlyToMode | mode=Marble.Instant
| ) |  |  |

Set the latitude for the center point

Parameters:

  |  | lat the new value for the latitude in degree.
  |  | mode the FlyToMode that will be used.

setCenterLongitude | ( | self, |
|  | float | lon,
|  | Marble.FlyToMode | mode=Marble.Instant
| ) |  |  |

Set the longitude for the center point

Parameters:

  |  | lon the new value for the longitude in degree.
  |  | mode the FlyToMode that will be used.

setDefaultAngleUnit | ( | self, |
|  | Marble.AngleUnit | angleUnit
| ) |  |  |

setDefaultFont | ( | self, |
|  | QFont | font
| ) |  |  |

setDistance | ( | self, |
|  | float | distance
| ) |  |  |

Set the distance of the observer to the globe in km.

Parameters:

  |  | distance The new distance in km.

setFocusPoint | ( | self, |
|  | Marble.GeoDataCoordinates | focusPoint
| ) |  |  |

Change the point of focus, overridding any previously set focus point.

Parameters:

  | focusPoint | New focus point

See also:
  focusPoint resetFocusPoint

setInputEnabled | ( | self, |
|  | bool | a0
| ) |  |  |

setMapQualityForViewContext | ( | self, |
|  | Marble.MapQuality | quality,
|  | Marble.ViewContext | viewContext
| ) |  |  |

Set the map quality for the specified view context.

Parameters:

  | quality | map quality for the specified view context
  | viewContext | view context whose map quality should be set

setMapThemeId | ( | self, |
|  | QString | maptheme
| ) |  |  |

Set a new map theme

Parameters:

  | maptheme | 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"

setProjection | ( | self, |
|  | int | projection
| ) |  |  |

Set the Projection used for the map

Parameters:

  |  | projection projection type (e.g. Spherical, Equirectangular, Mercator)

setProjection | ( | self, |
|  | Marble.Projection | projection
| ) |  |  |

Set the Projection used for the map

Parameters:

  |  | projection projection type (e.g. Spherical, Equirectangular, Mercator)

setPropertyValue | ( | self, |
|  | QString | name,
|  | bool | value
| ) |  |  |

Sets the value of a map theme property

Parameters:

  |  | value value of the property (usually: visibility)

Later on we might add a "setPropertyType and a QVariant if needed.

setRadius | ( | self, |
|  | int | radius
| ) |  |  |

Set the radius of the globe in pixels.

Parameters:

  |  | radius The new globe radius value in pixels.

setSelection | ( | self, |
|  | QRect | region
| ) |  |  |

setShowAtmosphere | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the atmospheric glow is visible

Parameters:

  |  | visible visibility of the atmospheric glow

setShowBackground | ( | self, |
|  | bool | visible
| ) |  |  |

setShowBorders | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the borders visible

Parameters:

  |  | visible visibility of the borders

setShowCities | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the city place mark overlay is visible

Parameters:

  |  | visible visibility of the city place marks

setShowCityLights | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether city lights instead of night shadow are visible.

Parameters:

  |  | visible visibility of city lights

setShowClouds | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the cloud cover is visible

Parameters:

  |  | visible visibility of the cloud cover

setShowCompass | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the compass overlay is visible

Parameters:

  |  | visible visibility of the compass

setShowCrosshairs | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the crosshairs are visible

Parameters:

  |  | visible visibility of the crosshairs

setShowFrameRate | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the frame rate gets shown

Parameters:

  | visible | visibility of the frame rate

setShowGrid | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the coordinate grid overlay is visible

Parameters:

  |  | visible visibility of the coordinate grid

setShowIceLayer | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the ice layer is visible

Parameters:

  |  | visible visibility of the ice layer

setShowLakes | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the lakes are visible

Parameters:

  |  | visible visibility of the lakes

setShowOtherPlaces | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the other places overlay is visible

Parameters:

  |  | visible visibility of other places

setShowOverviewMap | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the overview map overlay is visible

Parameters:

  |  | visible visibility of the overview map

setShowPlaces | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the place mark overlay is visible

Parameters:

  |  | visible visibility of the place marks

setShowRelief | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the relief is visible

Parameters:

  |  | visible visibility of the relief

setShowRivers | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the rivers are visible

Parameters:

  |  | visible visibility of the rivers

setShowScaleBar | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the scale bar overlay is visible

Parameters:

  |  | visible visibility of the scale bar

setShowSunInZenith | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the sun is visible in the zenith.

Parameters:

  | visible | visibility of the sun in the zenith

setShowSunShading | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the night shadow is visible.

Parameters:

  |  | visibile visibility of shadow

setShowTerrain | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the terrain place mark overlay is visible

Parameters:

  |  | visible visibility of the terrain place marks

setShowTileId | ( | self, |
|  | bool | visible
| ) |  |  |

Set whether the is tile is visible NOTE: This is part of the transitional debug API and might be subject to changes until Marble 0.8

Parameters:

  | visible | visibility of the tile

setViewContext | ( | self, |
|  | Marble.ViewContext | viewContext
| ) |  |  |

Set the view context (i.e. still or animated map)

setVolatileTileCacheLimit | ( | self, |
|  | long | kiloBytes
| ) |  |  |

Set the limit of the volatile (in RAM) tile cache.

Parameters:

  |  | kilobytes The limit in kilobytes.

bool showAtmosphere | ( |  | self ) |

Return whether the atmospheric glow is visible.

Returns:
  The cloud cover visibility.

bool showBackground | ( |  | self ) |

bool showBorders | ( |  | self ) |

Return whether the borders are visible.

Returns:
  The border visibility.

bool showCities | ( |  | self ) |

Return whether the city place marks are visible.

Returns:
  The city place mark visibility.

bool showCityLights | ( |  | self ) |

Return whether the city lights are shown instead of the night shadow.

Returns:
  visibility of city lights

bool showClouds | ( |  | self ) |

Return whether the cloud cover is visible.

Returns:
  The cloud cover visibility.

bool showCompass | ( |  | self ) |

Return whether the compass bar is visible.

Returns:
  The compass visibility.

bool showCrosshairs | ( |  | self ) |

Return whether the crosshairs are visible.

Returns:
  The crosshairs' visibility.

bool showFrameRate | ( |  | self ) |

Return whether the frame rate gets displayed.

Returns:
  the frame rates visibility

bool showGrid | ( |  | self ) |

Return whether the coordinate grid is visible.

Returns:
  The coordinate grid visibility.

bool showIceLayer | ( |  | self ) |

Return whether the ice layer is visible.

Returns:
  The ice layer visibility.

bool showLakes | ( |  | self ) |

Return whether the lakes are visible.

Returns:
  The lakes' visibility.

bool showOtherPlaces | ( |  | self ) |

Return whether other places are visible.

Returns:
  The visibility of other places.

bool showOverviewMap | ( |  | self ) |

Return whether the overview map is visible.

Returns:
  The overview map visibility.

bool showPlaces | ( |  | self ) |

Return whether the place marks are visible.

Returns:
  The place mark visibility.

bool showRelief | ( |  | self ) |

Return whether the relief is visible.

Returns:
  The relief visibility.

bool showRivers | ( |  | self ) |

Return whether the rivers are visible.

Returns:
  The rivers' visibility.

bool showScaleBar | ( |  | self ) |

Return whether the scale bar is visible.

Returns:
  The scale bar visibility.

bool showSunInZenith | ( |  | self ) |

Return whether the sun is shown in the zenith.

Returns:
  visibility of sun in the zenith

bool showSunShading | ( |  | self ) |

Return whether the night shadow is visible.

Returns:
  visibility of night shadow

bool showTerrain | ( |  | self ) |

Return whether the terrain place marks are visible.

Returns:
  The terrain place mark visibility.

int tileZoomLevel | ( |  | self ) |

Marble.ViewContext viewContext | ( |  | self ) |

Retrieve the view context (i.e. still or animated map)

Marble.ViewportParams viewport | ( |  | self ) |

long volatileTileCacheLimit | ( |  | self ) |

Returns the limit in kilobytes of the volatile (in RAM) tile cache.

Returns:
  the limit of volatile tile cache

[Marble.AbstractDataPluginItem] whichItemAt | ( | self, |
|  | QPoint | curpos
| ) |  |  |

Returns all widgets of dataPlugins on the position curpos

writePluginSettings | ( | self, |
|  | QSettings | settings
| ) |  |  |

Writes the plugin settings in the passed QSettings. You shouldn't use this in a KDE application as these use KConfig. Here you could use MarblePart which is handling this automatically.

Parameters:

  | settings | The QSettings object to be used.

int zoom | ( |  | self ) |

Return the current zoom amount.

float zoomFromDistance | ( | self, |
|  | float | distance
| ) |  |  |

Returns the zoom value (no unit) corresponding to the given camera distance (km)

zoomIn | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Zoom in by the amount zoomStep.

zoomOut | ( | self, |
|  | Marble.FlyToMode | mode=Marble.Automatic
| ) |  |  |

Zoom out by the amount zoomStep.

zoomView | ( | self, |
|  | int | zoom,
|  | Marble.FlyToMode | mode=Marble.Instant
| ) |  |  |

Zoom the view to a certain zoomlevel

Parameters:

  |  | zoom the new zoom level.

The zoom level is an abstract value without physical interpretation. A zoom value around 1000 lets the viewer see all of the earth in the default window.

zoomViewBy | ( | self, |
|  | int | zoomStep,
|  | Marble.FlyToMode | mode=Marble.Instant
| ) |  |  |

Zoom the view by a certain step

Parameters:

  |  | zoomStep the difference between the old zoom and the new