OsmGpsMap.MapTrack¶
- Subclasses:
 None
Methods¶
- Inherited:
 - Structs:
 
class  | 
  | 
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
|
  | 
Virtual Methods¶
- Inherited:
 
Properties¶
Name  | 
Type  | 
Flags  | 
Short Description  | 
|---|---|---|---|
r/w/c  | 
alpha transparency of the track  | 
||
r/w  | 
color of the track  | 
||
r/w/c  | 
should this track be editable  | 
||
r/w/c  | 
width of the lines drawn for the track  | 
||
r/w/co  | 
list of points for the track  | 
||
r/w/c  | 
should this track be visible  | 
Signals¶
- Inherited:
 
Name  | 
Short Description  | 
|---|---|
The   | 
|
Fields¶
- Inherited:
 
Name  | 
Type  | 
Access  | 
Description  | 
|---|---|---|---|
parent  | 
r  | 
Class Details¶
- class OsmGpsMap.MapTrack(**kwargs)¶
 - Bases:
 - Abstract:
 No
- Structure:
 
- classmethod new()¶
 - Returns:
 New track
- Return type:
 
Create new track
New in version 0.7.0.
- add_point(point)¶
 - Parameters:
 point (
OsmGpsMap.MapPoint) – aOsmGpsMap.MapPointpoint to add
Add a point to track
New in version 0.7.0.
- get_color()¶
 - Returns:
 track color
- Return type:
 color:
Gdk.RGBA
Get track color
New in version 0.7.0.
- get_length()¶
 - Returns:
 the length of the track in meters.
- Return type:
 
Get track length in meters
New in version 1.1.0.
- get_point(pos)¶
 - Parameters:
 pos (
int) – Position of the point to get- Returns:
 - Return type:
 
Get a
OsmGpsMap.MapPointpoint at pos of given trackNew in version 1.1.0.
- get_points()¶
 - Returns:
 list of
OsmGpsMap.MapPoint- Return type:
 
Get list of points in the track
New in version 0.7.0.
- insert_point(np, pos)¶
 - Parameters:
 np (
OsmGpsMap.MapPoint) – aOsmGpsMap.MapPointpos (
int) – Position for the point
Instert point np at given postition pos
New in version 1.1.0.
- n_points()¶
 - Returns:
 the number of points in the track.
- Return type:
 
Get number of points in the track
New in version 1.1.0.
Signal Details¶
- OsmGpsMap.MapTrack.signals.point_added(map_track, arg1)¶
 - Signal Name:
 point-added- Flags:
 - Parameters:
 map_track (
OsmGpsMap.MapTrack) – The object which received the signalarg1 (
OsmGpsMap.MapPoint) – The addedOsmGpsMap.MapPoint
The
OsmGpsMap.MapTrack::point-addedsignal is emitted whenever aOsmGpsMap.MapPointis added to theOsmGpsMap.MapTrack.
- OsmGpsMap.MapTrack.signals.point_changed(map_track, object)¶
 - Signal Name:
 point-changed- Flags:
 - Parameters:
 map_track (
OsmGpsMap.MapTrack) – The object which received the signalobject (
int) –
- OsmGpsMap.MapTrack.signals.point_inserted(map_track, object)¶
 - Signal Name:
 point-inserted- Flags:
 - Parameters:
 map_track (
OsmGpsMap.MapTrack) – The object which received the signalobject (
int) –
- OsmGpsMap.MapTrack.signals.point_removed(map_track, object)¶
 - Signal Name:
 point-removed- Flags:
 - Parameters:
 map_track (
OsmGpsMap.MapTrack) – The object which received the signalobject (
int) –
Property Details¶
- OsmGpsMap.MapTrack.props.alpha¶
 - 
alpha transparency of the track
 
- OsmGpsMap.MapTrack.props.color¶
 - 
color of the track
 
- OsmGpsMap.MapTrack.props.editable¶
 - 
should this track be editable
 
- OsmGpsMap.MapTrack.props.line_width¶
 - 
width of the lines drawn for the track
 
- OsmGpsMap.MapTrack.props.track¶
 - Name:
 track- Type:
 - Default Value:
 - Flags:
 
list of points for the track