Andoza:Location map data documentation: Versiyalar orasidagi farq
Qiyofa
Programmer (munozara | hissa) Yaratildi: joy xaritalari hujjati andozasi |
Programmer (munozara | hissa) BASEPAGENAME ishlatildi (doc ostsahifalarida xatolik chiqmasligi uchun) |
||
| Qator 2: | Qator 2: | ||
{{{image|}}} | {{{image|}}} | ||
'''{{#titleparts:{{FULLPAGENAME}}|3}}''' is a location map definition used to overlay markers and labels on {{{projection|an [[equirectangular projection]]}}} map of {{{name|[[{{#invoke:Location map|data|{{#titleparts:{{ | '''{{#titleparts:{{FULLPAGENAME}}|3}}''' is a location map definition used to overlay markers and labels on {{{projection|an [[equirectangular projection]]}}} map of {{{name|[[{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|name}}]]}}}. The markers are placed by [[latitude]] and [[longitude]] coordinates on the default map or a similar map image. | ||
== Usage == | == Usage == | ||
These definitions are used by the following templates when invoked with parameter "{{#titleparts:{{ | These definitions are used by the following templates when invoked with parameter "{{#titleparts:{{BASEPAGENAME}}|1|3}}": | ||
* {{tlx|Location map | {{#titleparts:{{ | * {{tlx|Location map | {{#titleparts:{{BASEPAGENAME}}|1|3}} | ...}} | ||
* {{tlx|Location map many | {{#titleparts:{{ | * {{tlx|Location map many | {{#titleparts:{{BASEPAGENAME}}|1|3}} | ...}} | ||
* {{tlx|Location map+ | {{#titleparts:{{ | * {{tlx|Location map+ | {{#titleparts:{{BASEPAGENAME}}|1|3}} | ...}} | ||
* {{tlx|Location map~ | {{#titleparts:{{ | * {{tlx|Location map~ | {{#titleparts:{{BASEPAGENAME}}|1|3}} | ...}} | ||
== Map definition == | == Map definition == | ||
* <code>'''name''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''name''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|name}}</code> | ||
*: Name used in the default map caption | *: Name used in the default map caption | ||
* <code>'''image''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''image''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image}}]]</code> | ||
*: The default map image, without "Image:" or "File:" | *: The default map image, without "Image:" or "File:" | ||
{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}}| | ||
* <code>'''image1''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''image1''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}}]]</code> | ||
*: An alternative map image, usually a relief map, which can be displayed via the ''relief'' or ''AlternativeMap'' parameters | *: An alternative map image, usually a relief map, which can be displayed via the ''relief'' or ''AlternativeMap'' parameters | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image2}}| | ||
* <code>'''image2''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''image2''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image2}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image2}}]]</code>{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}| | ||
* <code>'''image3''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''image3''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}]]</code> | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image4}}| | ||
* <code>'''image4''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''image4''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image4}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image4}}]]</code> | ||
}} | }} | ||
*: Alternative map image{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | *: Alternative map image{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}|s}} which can be displayed via the ''AlternativeMap'' parameter | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}}| | ||
* <code>'''top''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''top''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}}</code> | ||
*: [[Latitude]] at top edge of map, in [[decimal degrees]] | *: [[Latitude]] at top edge of map, in [[decimal degrees]] | ||
* <code>'''bottom''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''bottom''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}}</code> | ||
*: Latitude at bottom edge of map, in decimal degrees | *: Latitude at bottom edge of map, in decimal degrees | ||
* <code>'''left''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''left''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}}</code> | ||
*: [[Longitude]] at left edge of map, in decimal degrees | *: [[Longitude]] at left edge of map, in decimal degrees | ||
* <code>'''right''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''right''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}}</code> | ||
*: Longitude at right edge of map, in decimal degrees | *: Longitude at right edge of map, in decimal degrees | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|x}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|y}}| | ||
* <code>'''x''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''x''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|x}}</code> | ||
*: An expression to calculate a location on the map via its [[longitude]]; evaluates as 0 along the left edge and 100 along the right edge | *: An expression to calculate a location on the map via its [[longitude]]; evaluates as 0 along the left edge and 100 along the right edge | ||
* <code>'''y''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''y''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|y}}</code> | ||
*: An expression to calculate a location on the map via its [[latitude]]; evaluates as 0 along the top edge and 100 along the bottom edge | *: An expression to calculate a location on the map via its [[latitude]]; evaluates as 0 along the top edge and 100 along the bottom edge | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|mark}}| | ||
* <code>'''mark''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''mark''' = [[:File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|mark}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|mark}}]] ([[File:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|mark}}|{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|mark}}|8px]])</code> | ||
*: The default mark image to display with this map. This can be overridden by the <code>mark</code> parameter in [[Template:Location map]], which would otherwise default to [[:File:Red pog.svg|Red pog.svg]] ([[File:Red pog.svg|8px]]). | *: The default mark image to display with this map. This can be overridden by the <code>mark</code> parameter in [[Template:Location map]], which would otherwise default to [[:File:Red pog.svg|Red pog.svg]] ([[File:Red pog.svg|8px]]). | ||
}}{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }}{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|marksize}}| | ||
* <code>'''marksize''' = {{#invoke:Location map|data|{{#titleparts:{{ | * <code>'''marksize''' = {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|marksize}}</code> | ||
*: The default mark size (in [[pixel]]s) for the mark image displayed with this map (should not include <code>px</code>, for example <code>marksize={{#invoke:Location map|data|{{#titleparts:{{ | *: The default mark size (in [[pixel]]s) for the mark image displayed with this map (should not include <code>px</code>, for example <code>marksize={{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|marksize}}</code>, not <code>marksize={{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|marksize}}px</code>). This can be overridden by the <code>marksize</code> parameter in [[Template:Location map]], which would otherwise default to 8. | ||
}} | }} | ||
{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image2}}| | ||
== Alternative map == | == Alternative map == | ||
The {{tl|Location map}}, {{tl|Location map many}}, and {{tl|Location map+}} templates have parameters to specify an alternative map image. {{#if:{{#invoke:Location map|data|{{#titleparts:{{ | The {{tl|Location map}}, {{tl|Location map many}}, and {{tl|Location map+}} templates have parameters to specify an alternative map image. {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}} | ||
| The map displayed as '''image1''' can be used with the ''relief'' or ''AlternativeMap'' parameters. | | The map displayed as '''image1''' can be used with the ''relief'' or ''AlternativeMap'' parameters. | ||
}} {{#if:{{#invoke:Location map|data|{{#titleparts:{{ | }} {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image2}} | ||
| The map{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | | The map{{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}|s}} displayed as '''image2''' {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image3}}|/ '''image3'''}} {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image4}}|/ '''image4'''}} can be used with the ''AlternativeMap'' parameter. | ||
}} Examples may be found below or in the following: | }} Examples may be found below or in the following: | ||
{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|image1}}| | ||
* [[Template:Location map#Relief parameter]] | * [[Template:Location map#Relief parameter]] | ||
* [[Template:Location map+/relief]] | * [[Template:Location map+/relief]] | ||
| Qator 75: | Qator 75: | ||
* [[Template:Location map+/AlternativeMap]] | * [[Template:Location map+/AlternativeMap]] | ||
}} | }} | ||
{{#if:{{#invoke:Location map|data|{{#titleparts:{{ | {{#if:{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}}{{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}}| | ||
== Precision == | == Precision == | ||
{{#if:{{{precision|}}}|{{{precision}}}| | {{#if:{{{precision|}}}|{{{precision}}}| | ||
[[Longitude]]: from West to East this map definition covers {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{ | [[Longitude]]: from West to East this map definition covers {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}} + 360 ) fmod 360 round 4}} degrees. | ||
* At an image width of 200 [[pixel]]s, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{ | * At an image width of 200 [[pixel]]s, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}} + 360 ) fmod 360 / 200 round 4}} degrees per pixel. | ||
* At an image width of 1000 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{ | * At an image width of 1000 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|right}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|left}} + 360 ) fmod 360 / 1000 round 4}} degrees per pixel. | ||
[[Latitude]]: from North to South this map definition covers {{#expr: {{#invoke:Location map|data|{{#titleparts:{{ | [[Latitude]]: from North to South this map definition covers {{#expr: {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}} round 4}} degrees. | ||
* At an image height of 200 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{ | * At an image height of 200 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}} ) / 200 round 4}} degrees per pixel. | ||
* At an image height of 1000 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{ | * At an image height of 1000 pixels, that is {{#expr: ( {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|top}} - {{#invoke:Location map|data|{{#titleparts:{{BASEPAGENAME}}|1|3}}|bottom}} ) / 1000 round 4}} degrees per pixel. | ||
}}}} | }}}} | ||
{{#if:{{{examples|}}}| | {{#if:{{{examples|}}}| | ||
2026-yil 27-oktyabr, 17:44 dagi koʻrinishi
| Tajriba oʻtkazish uchun qumloq va test sahifasidan foydalaning. Iltimos, turkumlarni hujjat sahifasiga va intervikilarni vikimaʼlumotlarga joylashtiring. Ushbu andoza ostsahifalari. |