Template:Parliament diagram/doc: Difference between revisions
Jump to navigation
Jump to search
en>Aréat (cf change of the model. the little sizes made the diagrams comically tiny, in particular when used on top of larger election result tables, as usually done) |
m (1 revision imported) |
(No difference)
|
Latest revision as of 19:33, 17 April 2023
Arguments
This template uses Lua: |
{{Parliament diagram |width=O |height=O |caption=O |show=O |background=#fff |n1= |c1=C |p1=A |b1=O |n2= |c2=C |p2=A |b2=O }}
- Width
- Width in pixels of the created image; the corresponding height is calculated automatically. Predefined values: 1–28 seats, 280px; 29–100 seats, 300px; over 101 seats, 350px.
- Height
- Height in pixels of the created image, the width is calculated automatically. The parameter is ignored if width is defined.
- Show
- If value of 1, the summary data of seats is shown (colored box & number); if value of 2 a list with colored box, party name, and number is shown; dafault value is 0.
- Background
- Defines the background color using a hex color.
- n1, n2, ...
- Number of seats of each group or party
- c1, c2, ...
- Color of the seats for each group or party, indicated as a hex color (3- or 6-digits). Predefined value: #CCC.
- p1, p2, ...
- Name of the party to use the Module:Political party template (automatic loading of the color)
- b1, b2, ...
- Eventual color of the circle borders
Use examples
{{Parliament diagram |n1=522|c1=#E89600 |n2=152|c2=#59B1AA |n3= 20|c3=#D64757 }}
{{Parliament diagram |n1=60|p1=Historical Far Left |n2=620|p2=Historical Left (Italy) |n3=620|p3=Historical Right (Italy) |caption=Table caption |show=1 }}
{{Parliament diagram |n1=60|p1=Historical Far Left|c1=#A61022 |n2=620|p2=Historical Left (Italy)|c2=#0000FF |n3=620|p3=Historical Right (Italy)|c3=#000000 |caption=Table caption |show=1 }}
{{Parliament diagram |background=#eee |n1=60|p1=Historical Far Left |n2=620|p2=Historical Left (Italy) |n3=620|p3=Historical Right (Italy) |caption=Table caption |show=2 }}