Template:Convert/doc/range separator list: Difference between revisions
From Zoophilia Wiki
< Template:Convert | doc
meta>DePiep No edit summary |
meta>DePiep No edit summary |
||
Line 8: | Line 8: | ||
|- | |- | ||
| <code>-</code> | | <code>-</code> | ||
| <code><nowiki>{{convert|3|-|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|-|6|ft}}</nowiki></code> | ||
| {{convert|3|-|6|ft}} | |||
| rowspan=2 | input can be hyphen (-) or [[Dash#En dash|en dash]] (–), output uses en dashes | | rowspan=2 | input can be hyphen (-) or [[Dash#En dash|en dash]] (–), output uses en dashes | ||
|- | |- | ||
| {{hidden sort key|-}}<code>–</code> <small>(en dash)</small> | | {{hidden sort key|-}}<code>–</code> <code>&ndash;</code><small>(en dash)</small> | ||
| <code><nowiki>{{convert|3|–|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|–|6|ft}}</nowiki></code> | ||
| {{convert|3|–|6|ft}} | |||
|- | |- | ||
| <code>and</code> | | <code>and</code> | ||
| <code><nowiki>{{convert|3|and|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|and|6|ft}}</nowiki></code> | ||
| {{convert|3|and|6|ft}} | |||
|- | |- | ||
| {{hidden sort key|and&}}<code>&</code> | | {{hidden sort key|and&}}<code>&</code> | ||
| <code><nowiki>{{convert|3|&|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|&|6|ft}}</nowiki></code> | ||
| {{convert|3|&|6|ft}} | |||
| Same as <code>and</code> | | Same as <code>and</code> | ||
|- | |- | ||
| <code>and(-)</code> | | <code>and(-)</code> | ||
| <code><nowiki>{{convert|3|and(-)|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|and(-)|6|ft}}</nowiki></code> | ||
| {{convert|3|and(-)|6|ft}} | |||
| rowspan=2 | {{para|abbr|on}} alters the punctuation | | rowspan=2 | {{para|abbr|on}} alters the punctuation | ||
|- | |- | ||
| <code>and(-)|abbr=on</code> | | <code>and(-)|abbr=on</code> | ||
| <code><nowiki>{{convert|3|and(-)|6|ft|abbr=on}}</nowiki></code> | | <code><nowiki>{{convert|3|and(-)|6|ft|abbr=on}}</nowiki></code> | ||
| {{convert|3|and(-)|6|ft|abbr=on}} | |||
|- | |- | ||
| <code>or</code> | | <code>or</code> | ||
| <code><nowiki>{{convert|3|or|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|or|6|ft}}</nowiki></code> | ||
| {{convert|3|or|6|ft}} | |||
|- | |- | ||
| <code>to</code> | | <code>to</code> | ||
| <code><nowiki>{{convert|3|to|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|to|6|ft}}</nowiki></code> | ||
| {{convert|3|to|6|ft}} | |||
|- | |- | ||
| <code>to(-)</code> | | <code>to(-)</code> | ||
| <code><nowiki>{{convert|3|to(-)|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|to(-)|6|ft}}</nowiki></code> | ||
| {{convert|3|to(-)|6|ft}} | |||
| rowspan=2 | {{para|abbr|on}} alters the punctuation | | rowspan=2 | {{para|abbr|on}} alters the punctuation | ||
|- | |- | ||
| <code>to(-)|abbr=on</code> | | <code>to(-)|abbr=on</code> | ||
| <code><nowiki>{{convert|3|to(-)|6|ft|abbr=on}}</nowiki></code> | | <code><nowiki>{{convert|3|to(-)|6|ft|abbr=on}}</nowiki></code> | ||
| {{convert|3|to(-)|6|ft|abbr=on}} | |||
|- | |- | ||
| <code>to about</code> | | <code>to about</code> | ||
| <code><nowiki>{{convert|3|to about|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|to about|6|ft}}</nowiki></code> | ||
| {{nowrap|{{convert|3|to about|6|ft}}}} | |||
|- | |- | ||
| <code>+/-</code> | | <code>+/-</code> | ||
| <code><nowiki>{{convert|3|+/-|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|+/-|6|ft}}</nowiki></code> | ||
| {{convert|3|+/-|6|ft}} | |||
| rowspan=2 | uses "<code>&nbsp;±&nbsp;</code>" | | rowspan=2 | uses "<code>&nbsp;±&nbsp;</code>" | ||
|- | |- | ||
| {{hidden sort key|1=+/-}}<code>±</code> | | {{hidden sort key|1=+/-}}<code>±</code> <code>&plusmn;</code> | ||
| <code><nowiki>{{convert|3|±|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|±|6|ft}}</nowiki></code> | ||
| {{convert|3|±|6|ft}} | |||
|- | |- | ||
| <code>+</code> | | <code>+</code> | ||
| <code><nowiki>{{convert|3|+|6|ft}}</nowiki></code> | | <code><nowiki>{{convert|3|+|6|ft}}</nowiki></code> | ||
| {{convert|3|+|6|ft}} | |||
|- | |- | ||
| <code>,</code> | | <code>,</code> | ||
Line 68: | Line 82: | ||
| <code>x</code> | | <code>x</code> | ||
| <code><nowiki>{{convert|3|x|6|ft}}</nowiki></code> || {{convert|3|x|6|ft}} || | | <code><nowiki>{{convert|3|x|6|ft}}</nowiki></code> || {{convert|3|x|6|ft}} || | ||
uses "<code> <nowiki>×&nbsp;</nowiki></code>" | |||
|- | |||
| <code>×</code> <code>&times;</code> | |||
| <code><nowiki>{{convert|3|×|6|ft}}</nowiki></code> || {{convert|3|x|6|ft}} || | |||
uses "<code> <nowiki>×&nbsp;</nowiki></code>" | uses "<code> <nowiki>×&nbsp;</nowiki></code>" | ||
|- | |- |
Revision as of 13:13, 13 November 2014
Separator | Convert | Result | Notes |
---|---|---|---|
-
|
{{convert|3|-|6|ft}}
|
3–6 feet (0.91–1.83 m) | input can be hyphen (-) or en dash (–), output uses en dashes |
Template:Hidden sort key– – (en dash)
|
{{convert|3|–|6|ft}}
|
3–6 feet (0.91–1.83 m) | |
and
|
{{convert|3|and|6|ft}}
|
3 and 6 feet (0.91 and 1.83 m) | |
Template:Hidden sort key&
|
{{convert|3|&|6|ft}}
|
3 &[convert: unknown unit] | Same as and
|
and(-)
|
{{convert|3|and(-)|6|ft}}
|
3 and 6 feet (0.91–1.83 m) | |abbr=on alters the punctuation
|
and(-)|abbr=on
|
{{convert|3|and(-)|6|ft|abbr=on}}
|
3 and 6 ft (0.91–1.83 m) | |
or
|
{{convert|3|or|6|ft}}
|
3 or 6 feet (0.91 or 1.83 m) | |
to
|
{{convert|3|to|6|ft}}
|
3 to 6 feet (0.91 to 1.83 m) | |
to(-)
|
{{convert|3|to(-)|6|ft}}
|
3 to 6 feet (0.91–1.83 m) | |abbr=on alters the punctuation
|
to(-)|abbr=on
|
{{convert|3|to(-)|6|ft|abbr=on}}
|
3 to 6 ft (0.91–1.83 m) | |
to about
|
{{convert|3|to about|6|ft}}
|
3 to about 6 feet (0.91 to about 1.83 m) | |
+/-
|
{{convert|3|+/-|6|ft}}
|
3 ± 6 feet (0.91 ± 1.83 m) | uses " ± "
|
Template:Hidden sort key± ±
|
{{convert|3|±|6|ft}}
|
3 ± 6 feet (0.91 ± 1.83 m) | |
+
|
{{convert|3|+|6|ft}}
|
3 + 6 feet (0.91 + 1.83 m) | |
,
|
{{convert|3|,|6|ft}} |
3, 6 feet (0.91, 1.83 m) | uses ", "
|
, and
|
{{convert|3|, and|6|ft}} |
3, and 6 feet (0.91, and 1.83 m) | |
, or
|
{{convert|3|, or|6|ft}} |
3, or 6 feet (0.91, or 1.83 m) | |
by
|
{{convert|3|by|6|ft}} |
3 by 6 feet (0.91 by 1.83 m) | |
x
|
{{convert|3|x|6|ft}} |
3 by 6 feet (0.91 m × 1.83 m) |
uses " |
× ×
|
{{convert|3|×|6|ft}} |
3 by 6 feet (0.91 m × 1.83 m) |
uses " |
x|abbr=on
|
{{convert|3|x|6|ft|abbr=on}} |
3 ft × 6 ft (0.91 m × 1.83 m) | Scientific notation.|abbr=on alters the punctuation
|
xx
|
|xx| is deprecated. Use |x| instead | ||
*
|
|*| is deprecated. Use |x| instead |
Later more
The following ranges provide different output when units are abbreviated.
Convert | Output |
---|---|
{{convert|3|and(-)|6|ft|abbr=on}} |
3 and 6 ft (0.91–1.83 m) |
{{convert|3|to(-)|6|ft|abbr=on}} |
3 to 6 ft (0.91–1.83 m) |
{{convert|3|x|6|ft|abbr=on}} |
3 ft × 6 ft (0.91 m × 1.83 m) |
Ranges can use more than two values.
Convert | Output |
---|---|
{{convert|3|x|4|x|24|in}} |
3 by 4 by 24 inches (76 mm × 102 mm × 610 mm) |
{{convert|3|x|4|to|6+1/2|x|8+3/4|in}} |
3 by 4 to 6+1⁄2 by 8+3⁄4 inches (76 mm × 102 mm to 165 mm × 222 mm) |
Ranges can be specified in the first parameter.
Convert | Output |
---|---|
{{convert|3.2-7.5|ha}} |
3.2–7.5 hectares (7.9–18.5 acres) |
{{convert|3x4x24|in}} |
3 by 4 by 24 inches (76 mm × 102 mm × 610 mm) |
- From module
- convert/text
range_words = { '+/-', 'to(-)', 'xx', 'x', '*', 'to', 'or', 'by', '–' , '-' }
So:
- [convert: invalid number]
- to(-) [convert: invalid number]
- to(-) a [convert: invalid number]
- and(-) [convert: invalid number]
- 1 × 2 metres (3.3 × 6.6 ft)
- 1 by 2 metres (3.3 ft × 6.6 ft)
- a 1 m × 2 m (3.3 ft × 6.6 ft)
- [convert: invalid number]
- [convert: invalid number]
- [convert: invalid number]
- 1–2 metres (3.3–6.6 ft)
- 1–2 metres (3.3–6.6 ft)
- 1–2 metres (3.3–6.6 ft)