Difference between revisions of "Module:Location map/data/Germany Neckar/doc"

From blackwiki
Jump to navigation Jump to search
blackwiki>Zyxw
(update examples)
Line 44: Line 44:
 
For a description of the parameters, see {{tl|Location map}} and {{tl|Location map skew}}.
 
For a description of the parameters, see {{tl|Location map}} and {{tl|Location map skew}}.
  
{{Location map
+
== Examples ==
| GermanyNeckar
+
=== Mannheim ===
| label = Heilbronn
+
The example on the left shows the correct placement of [[Mannheim]] when ''GermanyNeckar'' is used with {{tl|Location map skew}}. The example on the right shows the incorrect placement via {{tl|Location map}}.
| label_size = 90 <!-- percent 0-900% -->
+
 
| caption = Show "[[Heilbronn]]" on map
+
Note that the marker for "Mannheim" is west of the mark, due to narrow longitudes far north (on non-equirectangular map). Longitude lines converge to the center, so center towns would be positioned more accurately.  The "polar" skew factor should be used (as in [[Template:Location_map_skew]]) to scale longitude smaller near polar latitudes (relative to map height), and position longitudes from map center, rather than left-side base longitude (''see example below'').
| lat_deg = 49 | lat_min = 9
+
 
| lon_deg = 09 | lon_min = 13
+
{{Location map skew | GermanyNeckar
| background = #FFFF99
+
| width = 250 | float = left
| float = right
+
| caption = Example using ''Location map skew''
| width = 250
+
| label = Mannheim | label_size = 90
 +
| background = #CCCC11 | position = bottom
 +
| lat_deg = 49.4890
 +
| lon_deg = 8.4691
 
}}
 
}}
Example labeling "[[Heilbronn]]":<code>
+
{{Location map | GermanyNeckar
:<nowiki>{{Location map</nowiki>
+
| width = 250 | float = center
:<nowiki>| GermanyNeckar</nowiki>
+
| caption = Example using ''Location map''
:<nowiki>| label = Heilbronn</nowiki>
+
| label = Mannheim | label_size = 90
:<nowiki>| label_size = 90 <--percent 0-900%</nowiki>
+
| background = #CCCC11 | position = bottom
:<nowiki>| caption = Show "Heilbronn" on map</nowiki>
+
| lat_deg = 49.4890
:<nowiki>| lat_deg = 49 | lat_min = 9</nowiki>
+
| lon_deg = 8.4691
:<nowiki>| lon_deg = 09 | lon_min = 13</nowiki>
+
}}
:<nowiki>| background = #FFFF99</nowiki>
+
{{clear}}
:<nowiki>| float = right</nowiki>
+
<nowiki>{{</nowiki>Location map skew | GermanyNeckar
:<nowiki>| width = 250</nowiki>
+
| width = 250 | float = left
:<nowiki>}}</nowiki>
+
| caption = Example using ''Location map skew''
</code>
+
| label = Mannheim | label_size = 90
{{-}}
+
| background = #CCCC11 | position = bottom
 +
| lat_deg = 49.4890
 +
| lon_deg = 8.4691
 +
}}
 +
<nowiki>{{</nowiki>Location map | GermanyNeckar
 +
| width = 250 | float = center
 +
| caption = Example using ''Location map''
 +
| label = Mannheim | label_size = 90
 +
| background = #CCCC11 | position = bottom
 +
| lat_deg = 49.4890
 +
| lon_deg = 8.4691
 +
}}
  
<!-- ------------------------- Showing Rottweil-->
+
=== Rottweil ===
<hr/>
+
The example on the left shows the correct placement of [[Rottweil]] when ''GermanyNeckar'' is used with {{tl|Location map skew}}. The example on the right shows the incorrect placement via {{tl|Location map}}.
{{Location map
+
 
| GermanyNeckar
+
{{Location map skew | GermanyNeckar
| label = Rottweil  | position=right
+
| width = 250 | float = left
| label_size = 90 <!-- percent 0-900% -->
+
| caption = Example using ''Location map skew''
| caption = Show "Rottweil" on map
+
| label = Rottweil | label_size = 90
 +
| background = #FFCC66 | position = top
 
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
 
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
 
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
 
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
| background = <!--orange-->#FFCC66
 
| float = right
 
| width = 220
 
| AlternativeMap = <!-- none (use default map) -->
 
 
}}
 
}}
Example for orange "[[Rottweil]]" at bottom:
+
{{Location map | GermanyNeckar
<code>
+
| width = 250 | float = center
:<nowiki>{{Location map</nowiki>
+
| caption = Example using ''Location map''
:<nowiki>| GermanyNeckar</nowiki>
+
| label = Rottweil | label_size = 90
:<nowiki>| label=Rottweil | position=left</nowiki>
+
| background = #FFCC66 | position = top
:<nowiki>| label_size = 90  <--percent 0-900%</nowiki>
+
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
:<nowiki>| caption = Show "Rottweil" on map</nowiki>
+
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
:<nowiki>| lat_deg=48 | lat_min=10</nowiki>
+
}}
:<nowiki>| lon_deg=08 | lon_min=37</nowiki>
+
{{clear}}
:<nowiki>| background = <!--orange-->#FFCC66</nowiki>
+
<nowiki>{{</nowiki>Location map skew | GermanyNeckar
:<nowiki>| float = right</nowiki>
+
| width = 250 | float = left
:<nowiki>| width = 220</nowiki>
+
  | caption = Example using ''Location map skew''
:<nowiki>| AlternativeMap = <!--none(default)--></nowiki>
+
| label = Rottweil | label_size = 90
:<nowiki>}}</nowiki></code>
+
  | background = #FFCC66 | position = top
{{-}}
+
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
 +
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
 +
}}
 +
<nowiki>{{</nowiki>Location map | GermanyNeckar
 +
| width = 250 | float = center
 +
| caption = Example using ''Location map''
 +
| label = Rottweil | label_size = 90
 +
| background = #FFCC66 | position = top
 +
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
 +
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
 +
}}
  
<!-- ------------------------- Showing 2: Rottweil /Mannheim -->
+
=== Multiple markers on one map ===
<hr/>
+
The example on the left shows the correct placement of locations when ''GermanyNeckar'' is used with {{tl|Location map skew}}. The example on the right shows the incorrect placement via {{tl|Location map many}}.
Two examples, showing "Rottweil" & "Mannheim" with map position aligned (by using parameters "float=left" and "float=right").
+
 
Note that the marker for "Mannheim" is west of the mark, due to narrow longitudes far north (on non-equirectangular map).
+
{{Location map skew | GermanyNeckar
{{Location map | GermanyNeckar
+
| width = 250 | float = left
| label = Rottweil
+
| caption = Example using ''Location map skew''
   | label_size = <!-- 0-900%--> 110
+
| label = Mannheim | label_size = 110
   | lat_deg = 48 |lat_min = 10 |lat_sec = 05
+
  | bg = #CCCC11 | pos = bottom
   | lon_deg = 08 |lon_min = 37 |lon_sec = 29
+
  | lat_deg = 49.4890
| caption = Show "Rottweil" on map
+
  | lon_deg = 8.469
| background = <!--blue-->#5599EE
+
| label2 = Rottweil | label2_size = 100
| float = left | width = 250
+
   | bg2 = #66BBDD | pos2 = top
 +
   | lat2_deg = 48 | lat2_min = 10
 +
   | lon2_deg = 08 | lon2_min = 37.5
 +
| label3 = Heilbronn | label3_size = 90
 +
  | bg3 = #FFFF99 | pos3 = top
 +
  | lat3_deg = 49 | lat3_min = 9
 +
  | lon3_deg = 09 | lon3_min = 13
 
}}
 
}}
{{Location map | GermanyNeckar
+
{{Location map many | GermanyNeckar
| caption = Show "Mannheim"
+
| width = 250 | float = center
| skew=0.86
+
| caption = Example using ''Location map many''
| label = Mannheim | label_size = <!-- 0-900%--> 82
+
| label = Mannheim | label_size = 100
   | lat=49.4890 | long=8.4691
+
   | bg = #CCCC11 | pos = bottom
   | markhigh=8  | position=bottom
+
   | lat_deg = 49.4890
   | background = <!--gold-->#CCCC11
+
   | lon_deg = 8.469
| label2 = Rottweil | label2_size =103 | skew2=0.86
+
| label2 = Rottweil | label2_size = 100
   | lat2_deg = 48 |lat2_min = 10 | pos2=bottom
+
  | bg2 = #66BBDD | pos2 = top
   | lon2_deg = 08 |lon2_min = 37.5
+
   | lat2_deg = 48 | lat2_min = 10
  | bg2 = <!--bluegreen-->#66BBDD
+
   | lon2_deg = 08 | lon2_min = 37.5
| label3 = Anytown | label3_size =<!-- 0-900%--> 103
+
| label3 = Heilbronn | label3_size = 90
   | lat3_deg=49 | lat3_min=1.1 | pos3=left
+
  | bg3 = #FFFF99 | pos3 = top
   | lon3_deg=8.5 | lon3_min=0.0 | bg3 = <!--yellow-->#EEEE11
+
   | lat3_deg = 49 | lat3_min = 9
| float = right | width = 250
+
   | lon3_deg = 09 | lon3_min = 13
 
}}
 
}}
Longitude lines converge to the center, so center towns would be positioned more accurately. The "polar" skew factor should be used (as in [[Template:Location_map_skew]]) to scale longitude smaller near polar latitudes (relative to map height), and position longitudes from map center, rather than left-side base longitude (''see example below'').
+
{{clear}}
{{-}}
+
  <nowiki>{{</nowiki>Location map skew | GermanyNeckar
 +
| width = 250 | float = left
 +
| caption = Example using ''Location map skew''
 +
| label = Mannheim | label_size = 110
 +
  | bg = #CCCC11 | pos = bottom
 +
  | lat_deg = 49.4890
 +
  | lon_deg = 8.469
 +
| label2 = Rottweil | label2_size = 100
 +
  | bg2 = #66BBDD | pos2 = top
 +
  | lat2_deg = 48 | lat2_min = 10
 +
  | lon2_deg = 08 | lon2_min = 37.5
 +
| label3 = Heilbronn | label3_size = 90
 +
  | bg3 = #FFFF99 | pos3 = top
 +
  | lat3_deg = 49 | lat3_min = 9
 +
  | lon3_deg = 09 | lon3_min = 13
 +
}}
 +
<nowiki>{{</nowiki>Location map many | GermanyNeckar
 +
| width = 250 | float = center
 +
| caption = Example using ''Location map many''
 +
| label = Mannheim | label_size = 100
 +
  | bg = #CCCC11 | pos = bottom
 +
  | lat_deg = 49.4890
 +
  | lon_deg = 8.469
 +
| label2 = Rottweil | label2_size = 100
 +
  | bg2 = #66BBDD | pos2 = top
 +
  | lat2_deg = 48 | lat2_min = 10
 +
  | lon2_deg = 08 | lon2_min = 37.5
 +
| label3 = Heilbronn | label3_size = 90
 +
  | bg3 = #FFFF99 | pos3 = top
 +
  | lat3_deg = 49 | lat3_min = 9
 +
  | lon3_deg = 09 | lon3_min = 13
 +
}}
  
<!-- ------------------------- Showing: Rottweil /Mannheim -->
+
=== Rottweil on wrong map ===
<hr/>
+
The example on the left shows the correct placement of [[Rottweil]] on the default map image. The example on the right shows the incorrect placement when a map using different border coordinates is specified via the ''AlternativeMap'' parameter.
===Example skewing Rottweil/Mannheim===
 
Example showing "[[Rottweil]]" (and "[[Mannheim]]") on one map.
 
  
{{Location map skew<!--many--> | GermanyNeckar
+
{{Location map skew | GermanyNeckar
| caption = Show "Mannheim" & "Rottweil"
+
| width = 250 | float = left
| skew=0.86
+
| label = Rottweil | label_size = 110
| label = Mannheim | label_size = <!-- 0-900%--> 82
+
| position = top | background = #FFFF99
  | lat=49.4890 | long=8.469
+
| caption = "Rottweil" put on correct map
  | markhigh=8  | position=bottom
+
| lat_deg=48 | lat_min=10
  | bg = <!--gold-->#CCCC11
+
| lon_deg=08 | lon_min=37.5
| label2 = Rottweil | label2_size =103 | skew2=0.86
 
  | lat2_deg = 48 |lat2_min = 10 | pos2=bottom
 
  | lon2_deg = 08 |lon2_min = 37.5
 
  | bg2 = <!--bluegreen-->#66BBDD
 
| label3 = Anytown | label3_size =<!-- 0-900%--> 103
 
  | lat3_deg=49  | lat3_min=1.1 | pos3=top
 
  | lon3_deg=8.5 | lon3_min=0.0 | bg3 = <!--yellow-->#EEEE11
 
| float = right | width = 250
 
 
}}
 
}}
<code>
+
{{Location map skew | GermanyNeckar
:<nowiki>{{Location map skew | GermanyNeckar</nowiki>
+
| AlternativeMap = Karte Deutschland.png
:<nowiki>| Show "Mannheim" & "Rottweil"</nowiki>
+
| width = 250 | float = right
:<nowiki>| skew=0.86</nowiki>
+
| label = Rottweil | label_size = 110
:<nowiki>| label = Mannheim</nowiki>
+
| position = top | background = #FFFF99
::<nowiki>| label_size = <!-- 0-900%--> 82</nowiki>
 
::<nowiki>  | lat=49.489 | long=8.469</nowiki>
 
::<nowiki>  | marksize=7 | position=top</nowiki>
 
::<nowiki>  | bg = <!--gold-->#CCCC11</nowiki>
 
:<nowiki>| label2=Rottweil | label2_size=103</nowiki>
 
::<nowiki>| skew2=0.86 | pos2=bottom</nowiki>
 
::<nowiki>  | lat2_deg=48 |lat2_min=10</nowiki>
 
::<nowiki>  | lon2_deg=08 |lon2_min=37.5</nowiki>
 
::<nowiki>  | bg2 = <!--bluegreen-->#66BBDD</nowiki>
 
:<nowiki>| label3 = Anytown</nowiki>
 
::<nowiki>  | label3_size=93 | pos3=top</nowiki>
 
::<nowiki>  | lat3_deg=49  | lat3_min=1.1</nowiki>
 
::<nowiki>  | lon3_deg=8.5 | lon3_min=0.0</nowiki>
 
::<nowiki>  | bg3 = <!--yellow-->#EEEE11</nowiki>
 
:<nowiki>| float = right | width = 250</nowiki>
 
:<nowiki>}}</nowiki></code>
 
The map uses alternate [[Template:Location_map_skew]].
 
Note that the marker for "Mannheim" has been placed correctly now (had been ''west'' of the mark, due to narrow longitudes far north, on the non-equirectangular map).
 
{{-}}
 
<br clear=all/>
 
<div clear=all></div>
 
 
 
<!-- ---------------------------- Rottweil on Wrong Map -->
 
<hr/>
 
{{Location map
 
| GermanyNeckar
 
| label = Rottweil  | position = top
 
| label_size = <!--percent 0-900%--> 128
 
 
| caption = "Rottweil" put on wrong-scale map
 
| caption = "Rottweil" put on wrong-scale map
 
| lat_deg=48 | lat_min=10
 
| lat_deg=48 | lat_min=10
 
| lon_deg=08 | lon_min=37.5
 
| lon_deg=08 | lon_min=37.5
| background = #FFFF99
 
| float = right  | width = 200
 
| AlternativeMap = Karte Deutschland.png
 
 
}}
 
}}
Example labeling "[[Rottweil]]" on wrong-scale map:<code>
+
{{clear}}
:<nowiki>{{Location map</nowiki>
+
<nowiki>{{</nowiki>Location map skew | GermanyNeckar
:<nowiki>| GermanyNeckar</nowiki>
+
| width = 250 | float = left
:<nowiki>| label = Rottweil  | position = top</nowiki>
+
| label = Rottweil | label_size = 110
:<nowiki>| label_size = <!-- 0-900%--> 128</nowiki>
+
  | position = top | background = #FFFF99
:<nowiki>| caption = "Rottweil" put on wrong-scale map</nowiki>
+
| caption = "Rottweil" put on correct map
:<nowiki>| lat_deg=48 | lat_min=10</nowiki>
+
| lat_deg=48 | lat_min=10
:<nowiki>| lon_deg=08 | lon_min=37.5</nowiki>
+
| lon_deg=08 | lon_min=37.5
:<nowiki>| background = #FFFF99</nowiki>
+
}}
:<nowiki>| float = right</nowiki>
+
<nowiki>{{</nowiki>Location map skew | GermanyNeckar
:<nowiki>| width = 200</nowiki>
+
| AlternativeMap = Karte Deutschland.png
:<nowiki>| AlternativeMap = Karte Deutschland.png</nowiki>
+
| width = 250 | float = right
:<nowiki>}}</nowiki>
+
| label = Rottweil | label_size = 110
</code>
+
| position = top | background = #FFFF99
{{-}}
+
| caption = "Rottweil" put on wrong-scale map
 +
| lat_deg=48 | lat_min=10
 +
| lon_deg=08 | lon_min=37.5
 +
}}
  
 
== See also ==
 
== See also ==

Revision as of 20:15, 21 August 2011

Template:Location map GermanyNeckar is a location map definition used to overlay markers and labels on a map of Germany's Neckar River. It is used by "Template:Location map" when invoked with parameter "GermanyNeckar": {{Location map | GermanyNeckar | ...}}. The markers are placed by latitude and longitude coordinates on the default map or a similar map image.

Because the map is not equirectangular, the coordinates will need to be adjusted to match northern-area mapping, or use skewed coordinates with "Template:Location map skew".

[[Image:Template:Location map/data/Germany Neckar|left|thumb|200px|Location map for Template:Location map/data/Germany Neckar]]

Map parameters
name Template:Location map/data/Germany Neckar name used in default map caption
image Template:Location map/data/Germany Neckar file name of map image, without "Image:" or "File:"
top Template:Location map/data/Germany Neckar latitude at top of map
bottom Template:Location map/data/Germany Neckar latitude at bottom of map
left Template:Location map/data/Germany Neckar longitude at left edge of map
right Template:Location map/data/Germany Neckar longitude at right edge of map
skew Template:Location map/data/Germany Neckar to narrow longitudes; see {{Location map skew}}

Usage

For a description of the parameters, see {{Location map}} and {{Location map skew}}.

Examples

Mannheim

The example on the left shows the correct placement of Mannheim when GermanyNeckar is used with {{Location map skew}}. The example on the right shows the incorrect placement via {{Location map}}.

Note that the marker for "Mannheim" is west of the mark, due to narrow longitudes far north (on non-equirectangular map). Longitude lines converge to the center, so center towns would be positioned more accurately. The "polar" skew factor should be used (as in Template:Location_map_skew) to scale longitude smaller near polar latitudes (relative to map height), and position longitudes from map center, rather than left-side base longitude (see example below).

Template:Location map skew Lua error in Module:Location_map at line 501: Unable to find the specified location map definition: "Module:Location map/data/GermanyNeckar" does not exist.

{{Location map skew | GermanyNeckar
| width = 250 | float = left
| caption = Example using Location map skew
| label = Mannheim | label_size = 90
| background = #CCCC11 | position = bottom
| lat_deg = 49.4890
| lon_deg = 8.4691
}}
{{Location map | GermanyNeckar
| width = 250 | float = center
| caption = Example using Location map
| label = Mannheim | label_size = 90
| background = #CCCC11 | position = bottom
| lat_deg = 49.4890
| lon_deg = 8.4691
}}

Rottweil

The example on the left shows the correct placement of Rottweil when GermanyNeckar is used with {{Location map skew}}. The example on the right shows the incorrect placement via {{Location map}}.

Template:Location map skew Lua error in Module:Location_map at line 501: Unable to find the specified location map definition: "Module:Location map/data/GermanyNeckar" does not exist.

{{Location map skew | GermanyNeckar
| width = 250 | float = left
| caption = Example using Location map skew
| label = Rottweil | label_size = 90
| background = #FFCC66 | position = top
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
}}
{{Location map | GermanyNeckar
| width = 250 | float = center
| caption = Example using Location map
| label = Rottweil | label_size = 90
| background = #FFCC66 | position = top
| lat_deg = 48 | lat_min = 10 |lat_sec = 05
| lon_deg = 08 | lon_min = 37 |lon_sec = 29
}}

Multiple markers on one map

The example on the left shows the correct placement of locations when GermanyNeckar is used with {{Location map skew}}. The example on the right shows the incorrect placement via {{Location map many}}.

Template:Location map skew Lua error in Module:Location_map/multi at line 143: Unable to find the specified location map definition: "Module:Location map/data/GermanyNeckar" does not exist.

{{Location map skew | GermanyNeckar
| width = 250 | float = left
| caption = Example using Location map skew
| label = Mannheim | label_size = 110
  | bg = #CCCC11 | pos = bottom
  | lat_deg = 49.4890
  | lon_deg = 8.469
| label2 = Rottweil | label2_size = 100
  | bg2 = #66BBDD | pos2 = top
  | lat2_deg = 48 | lat2_min = 10
  | lon2_deg = 08 | lon2_min = 37.5
| label3 = Heilbronn | label3_size = 90
  | bg3 = #FFFF99 | pos3 = top
  | lat3_deg = 49 | lat3_min = 9
  | lon3_deg = 09 | lon3_min = 13
}}
{{Location map many | GermanyNeckar
| width = 250 | float = center
| caption = Example using Location map many
| label = Mannheim | label_size = 100
  | bg = #CCCC11 | pos = bottom
  | lat_deg = 49.4890
  | lon_deg = 8.469
| label2 = Rottweil | label2_size = 100
  | bg2 = #66BBDD | pos2 = top
  | lat2_deg = 48 | lat2_min = 10
  | lon2_deg = 08 | lon2_min = 37.5
| label3 = Heilbronn | label3_size = 90
  | bg3 = #FFFF99 | pos3 = top
  | lat3_deg = 49 | lat3_min = 9
  | lon3_deg = 09 | lon3_min = 13
}}

Rottweil on wrong map

The example on the left shows the correct placement of Rottweil on the default map image. The example on the right shows the incorrect placement when a map using different border coordinates is specified via the AlternativeMap parameter.

Template:Location map skew Template:Location map skew

{{Location map skew | GermanyNeckar
| width = 250 | float = left
| label = Rottweil | label_size = 110
| position = top | background = #FFFF99
| caption = "Rottweil" put on correct map
| lat_deg=48 | lat_min=10
| lon_deg=08 | lon_min=37.5
}}
{{Location map skew | GermanyNeckar
| AlternativeMap = Karte Deutschland.png
| width = 250 | float = right
| label = Rottweil | label_size = 110
| position = top | background = #FFFF99
| caption = "Rottweil" put on wrong-scale map
| lat_deg=48 | lat_min=10
| lon_deg=08 | lon_min=37.5
}}

See also