Difference between revisions of "Template:GraticuleV/Documentation"

From Geohashing
imported>Joannac
m (Oops, fixed how to use section)
m
 
(11 intermediate revisions by 4 users not shown)
Line 1: Line 1:
Usage:
+
<table style="float:right">
 +
<tr><td valign="top">
 +
{{GraticuleV
 +
|mapn=mapn
 +
|maps=maps
 +
|map=map
 +
|namen=namen
 +
|names=names
 +
|name=name
 +
|n=n
 +
|e=e
 +
|s=s
 +
|w=w
 +
|nw=nw
 +
|ne=ne
 +
|se=se
 +
|sw=sw
 +
|en=en
 +
|es=es
 +
|wn=wn
 +
|ws=ws
 +
|caption=Full Example
 +
}}
 +
</td><td valign="top">
 +
{{GraticuleV
 +
|map=map
 +
|name=name
 +
|n=n
 +
|e=e
 +
|s=s
 +
|w=w
 +
|nw=nw
 +
|ne=ne
 +
|se=se
 +
|sw=sw
 +
|caption=Minimal Example
 +
}}
 +
</td></tr>
 +
</table>
 +
{{GraticuleV
 +
|map=[[Image:Adelaide GraticuleN.png]]
 +
|name=Adelaide
 +
|n=[[Port Pirie, Australia|Port Pirie]]
 +
|ne=[[Aldermann, Australia|Aldermann]]
 +
|en=[[Mannum, Australia|Mannum]]
 +
|es=[[Murray Bridge, Australia|Murray Bridge]]
 +
|se=[[Kingston, Australia|Kingston]]
 +
|s=[[-36,138]]
 +
|sw=[[Cape Gantheaume, Australia|Cape Gantheaume]]
 +
|ws=[[Kingscote, Australia|Kingscote]]
 +
|wn=[[Maitland, Australia|Maitland]]
 +
|nw=[[Whyalla, Australia|Whyalla]]
 +
|caption=Real Example
 +
}}<noinclude>&lArr; [[Template:GraticuleV]]
  
<nowiki>{{graticuleV
+
</noinclude>A more ''awesome'' version of [[Template:Graticule]], designed for cities that occupy vertically adjacent graticules.
| map = <map lat="123" lon="-45" date="2005-05-21"/>
 
| nw = [[Smalltown, USA|Smalltown]]
 
| s = [[Hayfields, USA|Hayfields]]
 
}}</nowiki>
 
  
Make sure to not leave out the trailing slash on the <tt><nowiki><map... /></nowiki></tt>. Ideally, I'd like to avoid using <tt><nowiki><map></nowiki></tt> at all, but <tt><nowiki>{{#tag}}</nowiki></tt> doesn't seem to want to do the right thing here. [[User:Duskwolf|Duskwolf]] 00:22, 22 May 2008 (UTC)
+
Originally made by [[User:Joannac|Joannac]], rewritten and overcomplicated by [[User:Mattyk|Matty]].
  
Notes on usage:
+
==Parameters==
* You don't have to include neighbors that don't exist. The template will automatically insert a "-" for absent neighbors.
+
(refer to the ''Full Example'' at right to see where each parameter goes)
* You can automatically abbreviate links using the magic pipe: insert a | character at the end of the bracketed text: <tt><nowiki>[[Smalltown, USA|]]</nowiki></tt> is magically transformed (at save time) to <tt><nowiki>[[Smalltown, USA|Smalltown]]</nowiki></tt>.
+
;mapn, maps
* You can add a "<code><nowiki>| maponly = 1</nowiki></code>" if you just want the map without the links to the surrounding graticules.
+
:what to draw for the northern/southern map.
* This uses: nnw, n, nne, nw, ne, w, e, sw, s, se
+
;map
 +
:what to draw for the entire map.
 +
:Only used if both '''mapn''' and '''maps''' are left out.
 +
;maponly
 +
:''(optional)'' if specified, only draws the '''map''' and '''caption''' (if any).
 +
;namen, names
 +
:What to write in the northern/southern mid section of the legend.
 +
;name-both
 +
:A single name that fills the entire mid-section of the legend.  (Overrides '''namen''' and '''names''')
 +
;name
 +
:Default text to use, if '''namen''', '''names''', and '''name-both''' are all left out.
 +
:Automatically gets '''North''' and '''South''' appended where appropriate.
 +
;n, s
 +
;ne, nw, se, sw
 +
:Neighbouring graticules in the simple directions.
 +
;en, es, wn, ws
 +
:Neighbouring graticules to the east and west.
 +
:The second letter (''n'' or ''s'') determines weather the neighbour is adjacent to the northern or southern part of the twin graticule.
 +
;e, w
 +
:Default values for otherwise unspecified east/west graticules.
 +
;caption
 +
:Extra stuff to include at the bottom of the box, like the caption text of an Image.
  
 +
==Example==
 +
<pre><nowiki>
 +
{{GraticuleV
 +
|map=[[Image:Adelaide GraticuleN.png]]
 +
|name=Adelaide
 +
|n=[[Port Pirie, Australia|Port Pirie]]
 +
|ne=[[World's End, Australia|World's End]]
 +
|en=[[Waikerie, Australia|Waikerie]]
 +
|es=[[Murray Bridge, Australia|Murray Bridge]]
 +
|se=[[Kingston, Australia|Kingston]]
 +
|s=[[MMBU]]
 +
|sw=[[Cape Gantheaume, Australia|Cape Gantheaume]]
 +
|ws=[[Kingscote, Australia|Kingscote]]
 +
|wn=[[Moonta, Australia|Moonta]]
 +
|nw=[[Whyalla, Australia|Whyalla]]
 +
|caption=Real Example
 +
}}
 +
</nowiki></pre>
  
All articles using this template should use wikilink brackets (<nowiki>[[ and ]]</nowiki>) to link to the other neighboring graticules. Please don't change this article to link automatically, since neighboring graticules might have unwieldy names that would make more sense to be shortened (ie by using "<nowiki>[[Minneapolis SW, Minnesota|Minneapolis SW]]</nowiki>"). Work has been done to change existing articles to link to neighbors by the template user and not by the template. [[User:Ironiridis|Ironiridis]] 21:56, 22 May 2008 (UTC)
+
See Also: [[Template:Graticule]], [[Template:GraticuleH]], [[Template:GraticuleQ]]
 
 
----
 
 
 
[http://wiki.xkcd.com/wgh/index.php?title=Template:Graticule/Documentation&action=edit Edit the documentation] (it isn't part of the template page)
 

Latest revision as of 11:41, 3 March 2020

nw n ne
wn namen en
wsnames es
sw s se
mapn
maps
Full Example
nw n ne
w name North e
wname South e
sw s se
map
Minimal Example
Whyalla Port Pirie Aldermann
Maitland Adelaide North Mannum
KingscoteAdelaide South Murray Bridge
Cape Gantheaume -36,138 Kingston
Adelaide GraticuleN.png
Real Example

Template:GraticuleV

A more awesome version of Template:Graticule, designed for cities that occupy vertically adjacent graticules.

Originally made by Joannac, rewritten and overcomplicated by Matty.

Parameters

(refer to the Full Example at right to see where each parameter goes)

mapn, maps
what to draw for the northern/southern map.
map
what to draw for the entire map.
Only used if both mapn and maps are left out.
maponly
(optional) if specified, only draws the map and caption (if any).
namen, names
What to write in the northern/southern mid section of the legend.
name-both
A single name that fills the entire mid-section of the legend. (Overrides namen and names)
name
Default text to use, if namen, names, and name-both are all left out.
Automatically gets North and South appended where appropriate.
n, s
ne, nw, se, sw
Neighbouring graticules in the simple directions.
en, es, wn, ws
Neighbouring graticules to the east and west.
The second letter (n or s) determines weather the neighbour is adjacent to the northern or southern part of the twin graticule.
e, w
Default values for otherwise unspecified east/west graticules.
caption
Extra stuff to include at the bottom of the box, like the caption text of an Image.

Example

{{GraticuleV
|map=[[Image:Adelaide GraticuleN.png]]
|name=Adelaide
|n=[[Port Pirie, Australia|Port Pirie]]
|ne=[[World's End, Australia|World's End]]
|en=[[Waikerie, Australia|Waikerie]]
|es=[[Murray Bridge, Australia|Murray Bridge]]
|se=[[Kingston, Australia|Kingston]]
|s=[[MMBU]]
|sw=[[Cape Gantheaume, Australia|Cape Gantheaume]]
|ws=[[Kingscote, Australia|Kingscote]]
|wn=[[Moonta, Australia|Moonta]]
|nw=[[Whyalla, Australia|Whyalla]]
|caption=Real Example
}}

See Also: Template:Graticule, Template:GraticuleH, Template:GraticuleQ