Class: QgsGeographicCoordinateNumericFormat¶
A numeric formatter which returns a text representation of a geographic coordinate (latitude or longitude).
Added in version 3.26.
Class Hierarchy¶
Base classes¶
A numeric formatter which returns a simple text representation of a value. |
|
Abstract base class for numeric formatters, which allow for formatting a numeric value for display. |
Enums
Angle format options. |
Methods
Returns the angle format, which controls how bearing the angles are formatted described in the returned strings. |
|
Sets the directional formatting option, which controls how bearing the angles are formatted described in the returned strings. |
|
Sets whether leading zeros for the degree values should be shown. |
|
Sets whether directional suffixes (e.g. "N") should be included. |
|
Sets whether leading zeros in the minutes or seconds values should be shown. |
|
Returns |
|
Returns |
|
Returns |
- class qgis.core.QgsGeographicCoordinateNumericFormat[source]¶
Bases:
QgsBasicNumericFormat
- __init__()
Default constructor
- __init__(a0: QgsGeographicCoordinateNumericFormat)
- Parameters:
- class AngleFormat(*values)¶
Bases:
IntEnum
Angle format options.
DegreesMinutesSeconds
: Degrees, minutes and seconds, eg 30 degrees 45’30DegreesMinutes
: Degrees and decimal minutes, eg 30 degrees 45.55’DecimalDegrees
: Decimal degrees, eg 30.7555 degrees
- DecimalDegrees = 2¶
- DegreesMinutes = 1¶
- DegreesMinutesSeconds = 0¶
- angleFormat(self) QgsGeographicCoordinateNumericFormat.AngleFormat [source]¶
Returns the angle format, which controls how bearing the angles are formatted described in the returned strings.
See also
- Return type:
- setAngleFormat(self, format: QgsGeographicCoordinateNumericFormat.AngleFormat)[source]¶
Sets the directional formatting option, which controls how bearing the angles are formatted described in the returned strings.
See also
- Parameters:
- setShowDegreeLeadingZeros(self, show: bool)[source]¶
Sets whether leading zeros for the degree values should be shown.
See also
- Parameters:
show (bool)
- setShowDirectionalSuffix(self, show: bool)[source]¶
Sets whether directional suffixes (e.g. “N”) should be included.
See also
- Parameters:
show (bool)
- setShowLeadingZeros(self, show: bool)[source]¶
Sets whether leading zeros in the minutes or seconds values should be shown.
See also
- Parameters:
show (bool)
- showDegreeLeadingZeros(self) bool [source]¶
Returns
True
if leading zeros for the degree values should be shown.See also
- Return type:
bool
- showDirectionalSuffix(self) bool [source]¶
Returns
True
if directional suffixes (e.g. “N”) should be included.See also
- Return type:
bool