ಟೆಂಪ್ಲೇಟು:Chapter heading
This template uses TemplateStyles: |
This template is for creating chapter headings (or titles) with some standard formatting. You may use either {{Chapter heading}} or the shorter {{ch}}.
Usage
[ಸಂಪಾದಿಸಿ]Defaults
[ಸಂಪಾದಿಸಿ]- Font size: 120% (equal to {{larger}})
- Text alignment: center
- Small caps: no
- Uppercase: yes
- Top margin: 2em
- Bottom margin: inherited
Uppercase?
[ಸಂಪಾದಿಸಿ]Uppercase text, especially in headings, is generally a typographic/stylistic choice, not a statement of emphasis. It is therefore better to type titles in title case and use CSS (via {{uc}} or this template) to style it.
Basic template
[ಸಂಪಾದಿಸಿ]This template is without the optional parameters.
{{ch|Content}}
Full template
[ಸಂಪಾದಿಸಿ]This template includes all optional parameters, except for the extra CSS styling parameter. Note that you may need to delete unused parameters for the template to work correctly.
Labeled:
{{ch|fontsize=|align=|sc=|uc=|margintop=|marginbottom=|Content}}
Parameters
[ಸಂಪಾದಿಸಿ]- 1: Content.
- 2 or fontsize: Size of the font, defined in %, em, px, pt, in or cm. See W3Schools for more possible definitions. Default: 120%
- 3 or align: Text alignment. left, center, right, justify. Default: center
- 4 or sc: Small caps. Use sc=yes for small caps. Cancels out uppercase effect. Default: null
- 5 or uc: Uppercase. Use uc=no for text as written. If sc=yes, then this parameter will be null. Default: uppercase
- 6 or margintop: Margin above the heading, defined in %, em, px, pt, in or cm. Default: 2em
- 7 or marginbottom: Margin below the heading, defined in %, em, px, pt, in or cm. Default: null
- style: CSS, which will override any styles defined before it. Remember to use semicolons to end statements.
Examples
[ಸಂಪಾದಿಸಿ]Default
[ಸಂಪಾದಿಸಿ]{{ch|The Wind at the Back of the House.}}
Produces:
Bold and italics
[ಸಂಪಾದಿಸಿ]Use can single quotes to define italics and bold as your normally would. (Or, if you know the CSS, you can use that as well.)
Bold
[ಸಂಪಾದಿಸಿ]{{ch|'''The Wind at the Back of the House.'''}}
Produces:
Italics
[ಸಂಪಾದಿಸಿ]{{ch|''The Wind at the Back of the House.''}}
Produces:
Bold italics
[ಸಂಪಾದಿಸಿ]{{ch|'''''The Wind at the Back of the House.'''''}}
Produces:
Font size
[ಸಂಪಾದಿಸಿ]{{ch|fontsize=200%|The Wind at the Back of the House.}}
Produces:
Alignment
[ಸಂಪಾದಿಸಿ]{{ch|align=left|The Wind at the Back of the House.}}
Produces:
Small caps
[ಸಂಪಾದಿಸಿ]{{ch|sc=yes|The Wind at the Back of the House.}}
Produce:
No uppercase
[ಸಂಪಾದಿಸಿ]{{ch|uc=no|The Wind at the Back of the House.}}
Produces:
Top and bottom margins (changed)
[ಸಂಪಾದಿಸಿ]Text before {{ch|margintop=1em|marginbottom=3em|The Wind at the Back of the House.}} Text after
Produces:
Text before
Text after
Styling with CSS
[ಸಂಪಾದಿಸಿ]{{ch|sc=yes|style=background-color:black; color:white; border:10px outset gray;|'''The Wind at the Back of the House.'''}}
Produces:
{{ch|uc=no|style=border-bottom:1px solid black|'''The Wind at the Back of the House.'''}}
Produces:
{{ch|sc=yes|style=font-weight:bold; font-style:italic;|The Wind at the Back of the House.}}
Produces: