mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-14 00:07:35 -04:00
More descriptive function help for area/length/perimeter functions
...which better clarify how project ellipsoid and unit settings are respected by the functions
This commit is contained in:
parent
fad0b1d15e
commit
c23e3096fe
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "$area",
|
||||
"type": "function",
|
||||
"description": "Returns the area of the current feature.",
|
||||
"description": "Returns the area of the current feature. The area calculated by this function respects both the current project's ellipsoid setting and area unit settings. Eg, if an ellipsoid has been set for the project then the calculated area will be ellipsoidal, and if no ellipsoid is set then the calculated area will be planimetric.",
|
||||
"examples": [ { "expression":"$area", "returns":"42"}]
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "$length",
|
||||
"type": "function",
|
||||
"description": "Returns the length of a linestring. If you need the length of a border of a polygon, use $perimeter instead.",
|
||||
"description": "Returns the length of a linestring. If you need the length of a border of a polygon, use $perimeter instead. The length calculated by this function respects both the current project's ellipsoid setting and distance unit settings. Eg, if an ellipsoid has been set for the project then the calculated length will be ellipsoidal, and if no ellipsoid is set then the calculated length will be planimetric.",
|
||||
"examples": [
|
||||
{ "expression":"$length", "returns":"42.4711"}
|
||||
]
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "$perimeter",
|
||||
"type": "function",
|
||||
"description": "Returns the perimeter length of the current feature.",
|
||||
"description": "Returns the perimeter length of the current feature. The perimeter calculated by this function respects both the current project's ellipsoid setting and distance unit settings. Eg, if an ellipsoid has been set for the project then the calculated perimeter will be ellipsoidal, and if no ellipsoid is set then the calculated perimeter will be planimetric.",
|
||||
"examples": [ { "expression":"$perimeter", "returns":"42"}
|
||||
]
|
||||
}
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "area",
|
||||
"type": "function",
|
||||
"description": "Returns the area of a geometry polygon object. Calculations are in the Spatial Reference System of this geometry.",
|
||||
"description": "Returns the area of a geometry polygon object. Calculations are always planimetric in the Spatial Reference System (SRS) of this geometry, and the units of the returned area will match the units for the SRS. This differs from the calculations performed by the $area function, which will perform ellipsoidal calculations based on the project's ellipsoid and area unit settings.",
|
||||
"arguments": [ {"arg":"geometry","description":"polygon geometry object"}],
|
||||
"examples": [ { "expression":"area(geom_from_wkt('POLYGON((0 0, 4 0, 4 2, 0 2, 0 0))'))", "returns":"8.0"}]
|
||||
}
|
||||
|
@ -9,7 +9,7 @@
|
||||
"examples": [ { "expression":"length('hello')", "returns":"5"} ] },
|
||||
{
|
||||
"variant": "Geometry variant",
|
||||
"variant_description": "Calculate the length of a geometry line object. Calculations are in the Spatial Reference System of this geometry.",
|
||||
"variant_description": "Calculate the length of a geometry line object. Calculations are always planimetric in the Spatial Reference System (SRS) of this geometry, and the units of the returned length will match the units for the SRS. This differs from the calculations performed by the $length function, which will perform ellipsoidal calculations based on the project's ellipsoid and distance unit settings.",
|
||||
"arguments": [ {"arg":"geometry","description":"line geometry object"}],
|
||||
"examples": [ { "expression":"length(geom_from_wkt('LINESTRING(0 0, 4 0)'))", "returns":"4.0"}]
|
||||
}]
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "perimeter",
|
||||
"type": "function",
|
||||
"description": "Returns the perimeter of a geometry polygon object. Calculations are in the Spatial Reference System of this geometry.",
|
||||
"description": "Returns the perimeter of a geometry polygon object. Calculations are always planimetric in the Spatial Reference System (SRS) of this geometry, and the units of the returned perimeter will match the units for the SRS. This differs from the calculations performed by the $perimeter function, which will perform ellipsoidal calculations based on the project's ellipsoid and distance unit settings.",
|
||||
"arguments": [ {"arg":"geometry","description":"polygon geometry object"}],
|
||||
"examples": [ { "expression":"perimeter(geom_from_wkt('POLYGON((0 0, 4 0, 4 2, 0 2, 0 0))'))", "returns":"12.0"}]
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user