Template:Advert column style/doc
This is a documentation subpage for Template:Advert column style. It contains usage information, categories and other content that is not part of the original template page. |
This template creates the style tag needed to easily create uniform columns of adverts of the kind often found in magazine letter pages.
Usage
[edit]{{advert column style|align=|gap=|flip=|width=|style=}}
To be used in tables, to set the style. For example:
{| {{advert column style}} | Foo |- | Bar |- | Baz |}
Parameters
[edit]All parameters are optional.
- align: (1st unnamed parameter) Sets the alignment of the column, can be either
right
orleft
. (default:right
) - gap: (2nd unnamed parameter) Sets the margin around the column; ie. the gap between the column edge and the text. Measured in em, do not include the units. (default:
2
) - flip: If used, this will use the opposite alignment in the mainspace and use the given alignment in all other namespaces. This may be the only way to get separate columns to fit in the mainspace, although it does slightly undermine the faithfulness of the reproduction. 0=No, don't flip. 1=Yes, flip the alignment. (default:
0
) - width: Sets the width of the advert column. Measured in pixels, do not include units. (default:
250
) - size: Sets the height of the text in the advert column. Measured as a percentage, do not include the percentage sign. (default:
90
) - style: Any additional style settings not included as standard can be entered manually in this parameter.
Examples
[edit]{{advert column style}}
style="width: 250px; font-size: 90%; line-height: 95%; float: right; margin: 2em 0 2em 2em;"
Standard, right floating column style.
{{advert column style|left}}
style="width: 250px; font-size: 90%; line-height: 95%; float: left; margin: 2em 2em 2em 0;"
Left floating column style.
{{advert column style|flip=1}}
style="width: 250px; font-size: 90%; line-height: 95%; float: right; margin: 2em 0 2em 2em;"
This won't change here, producing a standard right floating style, but in the mainspace this would produce the left floating style.
{{advert column style|width=300|gap=1|style=border:1px solid black}}
style="width: 300px; font-size: 90%; line-height: 95%; float: right; margin: 1em 0 1em 1em;border:1px solid black;"
Right floating column style with additional parameters to change its appearance. This column will be wider, with a smaller margin, and a one-pixel border.
See also
[edit]- {{table style}}