QWhereaboutsCoordinate Class Reference
|
Constant | Value | Description |
---|---|---|
QWhereaboutsCoordinate::DecimalDegrees | 0 | Returns a string representation of the coordinates in decimal degrees format. |
QWhereaboutsCoordinate::DecimalDegreesWithHemisphere | 1 | Returns a string representation of the coordinates in decimal degrees format, using 'N', 'S', 'E' or 'W' to indicate the hemispheres of the coordinates. |
QWhereaboutsCoordinate::DegreesMinutes | 2 | Returns a string representation of the coordinates in degrees-minutes format. |
QWhereaboutsCoordinate::DegreesMinutesWithHemisphere | 3 | Returns a string representation of the coordinates in degrees-minutes format, using 'N', 'S', 'E' or 'W' to indicate the hemispheres of the coordinates. |
QWhereaboutsCoordinate::DegreesMinutesSeconds | 4 | Returns a string representation of the coordinates in degrees-minutes-seconds format. |
QWhereaboutsCoordinate::DegreesMinutesSecondsWithHemisphere | 5 | Returns a string representation of the coordinates in degrees-minutes-seconds format, using 'N', 'S', 'E' or 'W' to indicate the hemispheres of the coordinates. |
See also toString().
Defines the possible types for a coordinate.
Constant | Value | Description |
---|---|---|
QWhereaboutsCoordinate::InvalidCoordinate | 0 | The coordinate is neither a 2D nor 3D coordinate. |
QWhereaboutsCoordinate::Coordinate2D | 1 | The coordinate has valid latitude and longitude values. |
QWhereaboutsCoordinate::Coordinate3D | 2 | The coordinate has valid latitude, longitude and altitude values. |
Constructs a coordinate. The coordinate will be invalid until setLatitude() and setLongitude() have been called.
Constructs a coordinate with the given latitude and longitude.
Constructs a coordinate with the given latitude, longitude and altitude.
Constructs a coordinate from the contents of other.
Destroys the coordinate object.
Returns the altitude (meters above sea level).
See also setAltitude().
Returns the azimuth (or bearing) in degrees from this coordinate to the coordinate specified by other. Altitude is not used in the calculation.
The calculation does not take the aspects of the geoid into account.
Returns 0 if the type of this coordinate or the type of other is QWhereaboutsCoordinate::InvalidCoordinate.
Returns the distance (in meters) from this coordinate to the coordinate specified by other. Altitude is not used in the calculation.
This calculation returns the great-circle distance between the two coordinates, without taking the aspects of the geoid into account.
Returns 0 if the type of this coordinate or the type of other is QWhereaboutsCoordinate::InvalidCoordinate.
Returns true if no attributes have been set for this coordinate.
Returns the latitude, in decimal degrees. A positive latitude indicates the Northern Hemisphere, and a negative latitude indicates the Southern Hemisphere.
See also setLatitude().
Returns the longitude, in decimal degrees. A positive longitude indicates the Eastern Hemisphere, and a negative longitude indicates the Western Hemisphere.
See also setLongitude().
Sets the altitude (meters above sea level) to altitude.
See also altitude().
Sets the latitude (in decimal degrees) to latitude. The value should be in the WGS84 datum.
To be valid, the latitude must be between -90 to 90 inclusive.
See also latitude().
Sets the longitude (in decimal degrees) to longitude. The value should be in the WGS84 datum.
To be valid, the longitude must be between -180 to 180 inclusive.
See also longitude().
Returns this coordinate as a string in the specified format.
For example, if this coordinate latitude-longitude coordinates of (-27.46758°, 153.027892°), these are the strings that are returned depending on format:
format value | Returned string |
---|---|
DecimalDegrees | -27.46758°, 153.02789° |
DecimalDegreesWithHemisphere | 27.46758° S, 153.02789° E |
DegreesMinutes | -27° 28.054', 153° 1.673' |
DegreesMinutesWithHemisphere | 27° 28.054 S', 153° 1.673' E |
DegreesMinutesSeconds | -27° 28' 3.2", 153° 1' 40.4" |
DegreesMinutesSecondsWithHemisphere | 27° 28' 3.2" S, 153° 1' 40.4" E |
Returns the type of this coordinate.
Assigns other to this coordinate and returns a reference to this coordinate.
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt qtextended4.4 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com