User:Pee Tern/Sandbox/Template/autonumbered list/doc

From Wikipedia, the free encyclopedia

Function[edit]

Purpose[edit]

The {{autonumbered list}} template allows a list of items to be columnated and have a ranking or number scheme automatically calculated; however, it has exceeded template limits for higher item numbers.

For example:

1 Biggest Failed Bank Inc. $200,000,000,000
2 Bigger Failed Bank Pty. Ltd. $20,000,000,000
3 Big Failed Bank Ltd. $2,000,000,000
4 Small Failed Bank Pty. Ltd. $100,000,000

the data in which is produced by:

|#|Biggest Failed Bank Inc.
{{!}} $200,000,000,000
|#|Bigger Failed Bank Pty. Ltd.
{{!}} $20,000,000,000
|#|Big Failed Bank Ltd.
{{!}} $2,000,000,000
|#|Small Failed Bank Pty. Ltd.
{{!}} $100,000,000

The number can be single level, or include sub numbering up to a total of three levels of numbering.

By allowing automatic numbering, editors do not have to adjust the contents of many rows of data when numeric rankings change. The editor can simply add or remove items from the list of items, and the numeric ranking will be automatically recalculated.

One to five columnated fields of data can be included in each list item.

Comparison with "#" wikimarkup[edit]

While normal wikimarkup using "#"s will number items in a list, wikimarkup does not:

  • prefix parent numbers to sub numbers
  • allow for duplicted rankings to be skipped
  • allow data fields within list items to be columnated

Limitations[edit]

Number of list items is limited to 50[edit]

The template can only handle up to 50 list items at one time.

This can be worked around by using the continued and startat parameters in multiple inclusions of the template one exactly below the other on the page.

Parameter use for the continuation work around is:

  • The heading parameters should be used only on the first inclusion.
  • The startat parameter should be used on all but the first inclusion.
  • The continued parameter should be used on all but the last inclusion.
  • Parameters such as numberwidth, columnwidthN, and tablewidth should be set to the same values for all inclusions.
  • The columns parameter can also be used, and should also be kept the same in each inclusion, but readability might be reduced because list items will be columnated within each inclusion, not across all inclusions.

See Continuation from one list to another and Multiple fields examples below.

Number depth is limited to 3[edit]

The template can only handle up the three levels of numbering, that is:
1
1.1
1.1.1

There is no work around.

Number of columnated fields of data is limited to 5[edit]

The template can only handle up to five fields of data for each list item.

There is no workaround.

Deficiencies[edit]

Missing number level flags[edit]

The template is likely to behave unpredictably if a number level flag is missing, for example, parameter constructs such as:
|#|Stuff
|#.#.#|More stuff

(There is no second level number flag between the first and third level list item.)

or:
|#.#|First list item

(There is no first level number flag before the second level list item.)

Invalid number level flags[edit]

Unrecognised number level flags are ignored. The corresponding list item will still be displayed, but the automatic numbering behaves as though the list item does not exist.

Usage[edit]

Caution[edit]

This template and its sub templates push the wiki functions parser to its limits.

To minimise load on servers, it is best used when there are constant changes to ranked columnated lists, which would require frequent editing and extensive manual adjusting, and edit reviews, of tables.

If a ranking is static, or only ever gets added to at the bottom, then hard coded tables are much more efficient.

Skeleton[edit]

{{autonumbered list
|columns = 
|halfbackground  = 
|prefix  = 
|suffix  = 
|skip    = 
|numberwidth  = 
|numberheading = 
|tablewidth   = 
|columnwidth1 = 
 (...up to 5...)
|heading1 =
 (...up to 5...)
|startat      = 
|numberflag1
|listitemcontent1
 (...up to 50 pairs of number flag and list item content - unnamed parameters...)
|continued = 
}}

Examples[edit]

Number, sub number, and sub sub number, in two columns[edit]

1 One
1.1 One point one
1.1.1 One point one point one
1.1.2 One point one point two
1.2 One point two
1.2.1 One point two point one
1.2.2 One point two point two
2 Two
2.1 Two point one
2.1.1 Two point one point one
2.1.2 Two point one point two
2.2 Two point two
2.2.1 Two point two point one
2.2.2 Two point two point two
3 Three
3.1 Three point one
3.1.1 Three point one point one
3.1.2 Three point one point two
4 Four
4.1 Four point one
4.1.1 Four point one point one
4.1.2 Four point one point two
4.1.3 Four point one point three
4.1.4 Four point one point four
4.1.5 Four point one point five
4.1.6 Four point one point six
4.2 Four point two
4.2.1 Four point two point one
4.2.2 Four point two point two
4.2.3 Four point two point three
4.2.4 Four point two point four
4.2.5 Four point two point five
4.2.6 Four point two point six
4.2.7 Four point two point seven
4.2.8 Four point two point eight
4.2.9 Four point two point nine
4.2.10 Four point two point ten
4.2.11 Four point two point eleven
4.2.12 Four point two point twelve
5 Five
5.1 Five point one
5.1.1 Five point one point one
5.1.2 Five point one point two
6 Six
6.1 Six point one
6.1.1 Six point one point one
6.1.2 Six point one point two
7 Seven
8 Eight
9 Nine

Suffixed numbers[edit]

1: One
1.1: One point one
1.2: One point two
1.3: One point three
2: Two
3: Three
4: Four
4.1: Four point one
4.1.1: Four point one point one
4.1.2: Four point one point two

Prefixed and suffixed numbers, in four columns[edit]

(1) One
(2) Two
(3) Three
(4) Four
(5) Five
(6) Six
(7) Seven
(8) Eight
(9) Nine
(10) Ten
(11) Eleven
(12) Twelve
(13) Thrirteen
(14) Fourteen
(15) Fifteen
(16) Sixteen
(17) Seventeen
(18) Eighteen
(19) Nineteen
(20) Twenty
(21) Twenty-One
(22) Twenty-Two
(23) Twenty-Three
(24) Twenty-Four
(25) Twenty-Five
(26) Twenty-Six
(27) Twenty-Seven
(28) Twenty-Eight
(29) Twenty-Nine
(30) Thirty
(31) Thirty-One
(32) Thirty-Two
(33) Thirty-Three
(34) Thirty-Four
(35) Thirty-Five
(36) Thirty-Six
(37) Thirty-Seven
(38) Thirty-Eight
(39) Thirty-Nine
(40) Forty
(41) Forty-One
(42) Forty-Two
(43) Forty-Three
(44) Forty-Four
(45) Forty-Five
(46) Forty-Six
(47) Forty-Seven
(48) Forty-Eight
(49) Forty-Nine
(50) Fifty

Continuation from one list to another[edit]

Continuation would normally only be used for numbered lists greated than 50 (the template maximum) long. In this case, just for example, the first list only has 10 items in it.

1 One
2 Two
3 Three
4 Four
5 Five
6 Six
7 Seven
8 Eight
9 Nine
10 Ten
11 Eleven
12 Twelve
13 Thirteen
14 Fourteen
15 Fifteen
16 Sixteen
17 Seventeen
18 Eighteen
19 Nineteen
20 Twenty

Repeated number entries - repeated numbers not skipped[edit]

1 One
1 Duplicated one
2 Two
3 Three
3 Duplicated three
4 Four
4.1 Four point one
4.1 Duplicated four point one
4.1 Duplicated four point one
4.2 Four point two
4.2.1 Four point two point one
4.2.1 Duplicated four point two point one
4.2.2 Four point two point two

Repeated number entries - repeated numbers skipped[edit]

1 One
Duplicated one
3 Three
4 Four
Duplicated four
6 Six
6.1 Six point one
Duplicated six point one
Duplicated six point one
6.4 Six point four
6.4.1 Six point four point one
Duplicated six point four point one
6.4.3 Six point four point three

Multiple fields[edit]

Rank Name Sex Birth Age Country of Residence

1 Moloko Temo[20] F 4 de julho de 1874 149 years, 307 days South Africa
2 Maria Olívia da Silva[21] F 28 de fevereiro de 1880 144 years, 68 days Brazil
3 Tuti Yusupova[22] F 1 de julho de 1880 143 years, 310 days Uzbekistan
4 Juana Bautista de la Candelaria Rodríguez [23] F 2 de fevereiro de 1885 139 years, 94 days Cuba
5 Cliceria Gómez-Morales F 20 de setembro de 1885 138 years, 229 days Mexico
6 Ida Stewart [24] F 5 de novembro de 1886 137 years, 183 days Jamaica
7 Sadiq Sawut [25]] M 9 de agosto de 1887 136 years, 271 days China
8 Magomed Labazanov [26] M 1 de maio de 1890 134 years, 5 days Russia
9 Maikup Zhan[25] F 15 de junho de 1890 133 years, 326 days China
10 Ana María Pérez González[27] F 22 de junho de 1890 133 years, 319 days Mexico
11 Baji Safaorva F 3 de julho de 1890 133 years, 308 days Azerbaijan
12 Amai Cering[28] F 16 de março de 1891 133 years, 51 days China
13 Sóstenes Martínez[29] M 22 de abril de 1891 133 years, 14 days Mexico
14 Elias Athanasiades M 14 de maio de 1891 132 years, 358 days Germany
15 María Díaz Cortés[30] F 4 de janeiro de 1892 132 years, 123 days Spain
16 Rebecca Lanier [31] F 24 de março de 1892 132 years, 43 days United States
17 Elizabeth Johnson[32] F 25 de dezembro de 1892 131 years, 133 days United States
18 Richard Washington [33] M 13 de abril de 1893 131 years, 23 days United States
19 He Wenzhang[34] M 9 de abril de 1894 130 years, 27 days China
20 Tǎnase Tǎnase[35] M 15 de outubro de 1894 129 years, 204 days Romania
21 María Norberta Rivera-Ramírez[36] F 5 de junho de 1895 128 years, 336 days Mexico
22 Transito Ayala [37] F 13 de agosto 1895 128 years, 267 days Colombia
23 Susan Middleton [38] [3] F 19 de fevereiro de 1896 128 years, 77 days United States
24 Melinda Harris[39] F 4 de maio de 1896 128 years, 2 days United States
25 Katerina Heyman [40] F 8 de agosto de 1896 127 years, 272 days South Africa
26 Lake Dickson [3] F 19 de janeiro de 1897 127 years, 108 days United States
27 Ruby Muhammad [19] F 20 de março de 1897 127 years, 47 days United States
28 Ronnie Fairbanks[18] M 27 de maio de 1897 126 years, 345 days United States
29 Marianna Ostrowska[17] F 5 de agosto de 1897 126 years, 275 days Poland
30 Maria Pogonowska[16] F 30 de outubro de 1897 126 years, 189 days Israel
31 Delma Kollar [3] F 31 de outubro de 1897 126 years, 188 days United States
32 Teresa Dosaigües [15] F 13 de fevereiro de 1898 126 years, 83 days Spain
33 Eufrozyna Kaminski[14] F 7 de março de 1898 126 years, 60 days Canada
34 Marcelle Narbonne[13] F 24 de março de 1898 126 years, 43 days France
35 Elsie Freeman[12] F 13 de junho de 1898 125 years, 328 days United States
36 Kate Lowenthal[11] F 17 de setembro de 1898 125 years, 232 days United States
37 Andrew Hatch[10] M 7 de outubro de 1898 125 years, 212 days United States
38 Rosa Wilkes[9] F 10 de outubro de 1898 125 years, 209 days United States
39 Hagar Young[3] F 11 de outubro de 1898 125 years, 208 days United States
40 Alwine Werner[8] F November 10, 1898 125 years, 178 days Germany
41 Anthone Phipps[7] F 7 de dezembro de 1898 125 years, 151 days United States
42 Salome Korn[6] F 12 de dezembro de 1898 125 years, 146 days United States
43 Michalina Wasilewska[5] F 21 de dezembro de 1898 125 years, 137 days Poland
44 Juanita Elliott[4] F 24 de dezembro de 1898 125 years, 134 days United States
45 Lillian Leblanc F 26 de dezembro de 1898 125 years, 132 days United States
46 Gertrude Noone[3] F 30 de dezembro de 1898 125 years, 128 days United States
47 Doris Nash[2] F 19 de janeiro de 1899 125 years, 108 days United Kingdom
48 Marie-Jeanne Faure-Geors[1] F 31 de janeiro de 1899 125 years, 96 days France
49 Fannie Buten[42] F 1 de fevereiro de 1899 125 years, 95 days United States
50 Elizabeth Buhler[43] F 8 de fevereiro de 1899 125 years, 88 days Canada
Maude Buckley[44] F 8 de fevereiro de 1899 125 years, 88 days  Germany
52 Pearl Lutzko[45] F 15 de fevereiro de 1899 125 years, 81 days Canada
Mildred JaMais[46] F 15 de fevereiro de 1899 125 years, 81 days United States
54 Elspeth Wood[47] F 18 de fevereiro de 1899 125 years, 78 days United Kingdom
Anna Pendley[48] F 18 de fevereiro de 1899 125 years, 78 days  Germany
56 Santa Gennari[49] F 23 de fevereiro de 1899 125 years, 73 days Italy
Hillard Hudson[50] M 23 de fevereiro de 1899 125 years, 73 days United States
58 Margaret Fish[51] F 7 de março de 1899 125 years, 60 days United Kingdom
59 John "Jack" Campbell Ross[41] M 11 de março de 1899 125 years, 56 days Australia

Parameters[edit]

This template uses both named and unnamed parameters.

The number flag and the list item content for each list item are unnammed parameters.

Parameter Name Required Description Values
columns no Number of columns to display the items in. Defaults to 1. Number
halfbackground no If set to any value then every second item line has a background to allow easy eye sighting across the list. Any non blank value.
prefix no Text to appear before the number. Defaults to nothing. Any optionally linked text.
suffix no text to appear after the number. Defaults to nothing. Any optionally linked text.
skip no Set to any value to skip numbers if an item has a duplicate ranking to the previous item. The number is incremented but not displayed. Defaults to no skipping and reuse of the previous number. Any non blank value.
numberwidth no The percentage width to allocate to the list item number within the list item. Defaults to 15. Any number from 0 to 100.
numberheading no The heading to be displayed over the first column, of automatically generated numbers. Almost any wikitext. May include wiki table markup.
tablewidth no The percentage width to allocate to the table relative to the displayed page. Default is to minimise width. Any number from 0 to 100.
columnwidth1 no The percentage width to allocate to each field within the list item if there is more than one field. Columnwidth1 defaults to (100 - numberwidth) if not provided. Can be up to 5 fields. The sum of numberwidth and columnwidth1 through columnwidth5 should be 100. Any number from 0 to 100.
heading1 no The heading to be displayed over each column of fields within the list item. Almost any wikitext. may include wiki table markup, for example align=center {{!}} '''Field Heading'''giving
Field Heading
startat no The start number for the first list item. Is set then causes formatting of the list to allow list to appear as a seemless continuation of a previous list. Defaults to 1 and no continuation formatting of the list. Any number.
numberflag1 no Unnamed parameter. The flag to indicate the level and type of numbering required. Up to 50. Must be paired with listitemcontent1.
Flag Effect
# 1
2
3
etc.
(Parameter value left blank.) Indicates a duplicate ranking or numbering at the # level. Behaviour is defined by the skip parameter.
#.# 1.1
1.2
1.3
etc.
#. Indicates a duplicate ranking or numbering at the #.# level. Behaviour is defined by the skip parameter.
#.#.# 1.1.1
1.1.2
1.1.3
etc.
#.#. Indicates a duplicate ranking or numbering at the #.#.# level. Behaviour is defined by the skip parameter.
Text == one of the 6 flag values.
listitemcontent1 no Unnamed parameter. The content of the list item. Up to 5 fields of data can be provided. To provide more than one field use standard wikitable syntax BUT replace single and double pipes with {{!}} and {{!!}} respectively. Up to 50. If there is more than one field in the list item then columnwidths must be set for each field. Nearly any wikimarked text.
continued no If set to any value then causes the formatting of the list to allow the list to be seemlessly followed by another list.

Notes for template editors[edit]

Wiki function parser limit[edit]

This template relies on a subtemplate, {{colevel/count things}}. The {{colevel/count_things}} template reaches one or more nested function depth limits, and is extensively coded to get around this problem. It is probably not viable to increase the number of list items processable by this template unless the {{colevel/count things}} template's algorithm can be completely redesigned to use a much flatter structure.

Structure of template call relationships[edit]

Sub calls[edit]

{{autonumbered list}}
{{colevel/headings}} {{colevel/item set}}

Para calls[edit]

{{colevel/item set}} {{colevel/find last}}
{{autonumbered list/number}} {{colevel/count things}}
{{colevel/column style}}
{{colevel/headings}} {{colevel/column style}}

Reflist[edit]

  1. ^ Notícia do 110º aniversário de Marie-Jeanne Faure-Geors
  2. ^ Notícia do 110º aniversário de Doris Nash
  3. ^ a b c d e http://www.grg.org/Adams/E.HTM tabela EE da GRG
  4. ^ Notícia do 110º aniversário de Juanita Elliott
  5. ^ Notícia do 110º aniversário de Michalina Wasilewska
  6. ^ Notícia do 110º aniversário de Salome Korn
  7. ^ Notícia do 110º aniversário de Anthone Phipps
  8. ^ Notícia do 110º aniversário de Alwine Werner
  9. ^ Notícia do 110º aniversário de Rosa Wilkes
  10. ^ Notícia do 110º aniversário de Andrew Hatch
  11. ^ Notícia de Kate Lowenthal com 110 anos
  12. ^ Notícia do 110º aniversário de Elsie Freeman
  13. ^ Notícia do 110º aniversário de Marcelle Narbonne (in French)
  14. ^ http://www.ottawacitizen.com/Family+fêtes+long+life+filled+with+love/1368243/story.html Notícia do 111º aniversário de Eufrozyna Kaminski]
  15. ^ Notícia de Teresa Dosaigües com 110 anos
  16. ^ http://www.jpost.com/servlet/Satellite?cid=1192380711167&pagename=JPost/JPArticle/ShowFull
  17. ^ [1]
  18. ^ Notícia do 111º aniversário de Ronnie Fairbanks
  19. ^ Notícia de Ruby Muhammad com 111 anos
  20. ^ Notícia do 134º aniversário de Moloko Temo
  21. ^ Notícia do 129º aniversário de Maria Olívia da Silva
  22. ^ G1- "Uzbequistão diz ter a mulher mais velha do mundo"
  23. ^ Notícia da Agência Cubana de Notícias sobre Juana B. C. Rodríguez
  24. ^ Notícia sobre Ida Stewart
  25. ^ a b [http://noticias.uol.com.br/ultnot/efe/2008/10/07/ult1766u28235.jhtm
  26. ^ [2]
  27. ^ Notícia de Ana Maria Pérez González com 117 anos
  28. ^ Notícia do 117º aniversário de Amai Cering
  29. ^ http://notizie.virgilio.it/gallery/la_giornata_mondiale_dei_guinness.html,zoom=245681.html
  30. ^ Notícia do 117º aniversário de María Díaz Cortés
  31. ^ Notícia do 116º aniversário de Rebecca Lanier
  32. ^ [3]
  33. ^ Notícia do 115º aniversário de Richard Washington
  34. ^ [4]
  35. ^ Tudor, Paula Anastasia (15/07/2007). "Cel mai bătrăn bărbat din lume". Jurnalul National (in Romanian). {{cite news}}: Check date values in: |date= (help)
  36. ^ MacBeath, Manuel Mora. "Vive 3 siglos". Periódico AM.
  37. ^ [http://www.elespacio.com.co/publicaciones/mod.php?mod=userpage&color=1&page_id=17224
  38. ^ Notícia do 112º aniversário de Susan Middleton
  39. ^ Notícia do 112º aniversário de Melinda Harris
  40. ^ Notícia do 112º aniversário de Katerina Heyman
  41. ^ do 110º aniversário de John Ross
  42. ^ Notícia do 110º aniversário de Fannie Buten
  43. ^ Notícia do 110º aniversário de Elizabeth Buhler
  44. ^ Notícia do 110º aniversário de Maude Buckley
  45. ^ Notícia do 110º aniversário de Pearl Lutzko
  46. ^ Notícia do 110º aniversário de Mildred JaMais
  47. ^ Notícia do 110º aniversário de Elspeth Wood
  48. ^ Notícia do 110º aniversário de Anna Pendley
  49. ^ Notícia do 110º aniversário de Santa Gennari
  50. ^ Notícia do 110º aniversário de Hillard Hudson
  51. ^ Notícia do 110º aniversário de Margaret Fish