• Home
  • Random
  • Log in
  • Settings
  • About Safer nicotine wiki
  • Disclaimers
Safer nicotine wiki

Template:Annotation

  • Language
  • Watch
  • View source
Template documentation[view] [edit] [history] [purge]
CambrianOrdovicianSilurianDevonianCarboniferousPermianTriassicJurassicCretaceousPaleogeneNeogene
Marine extinction intensity during the Phanerozoic
%
Millions of years ago
(H)
K–Pg
Tr–J
P–Tr
Cap
Late D
O–S
CambrianOrdovicianSilurianDevonianCarboniferousPermianTriassicJurassicCretaceousPaleogeneNeogene
The Permian–Triassic extinction event, labelled "P-Tr" here, is the most significant extinction event in this plot for marine genera.

Creates an annotation for annotated images, for example in the diagram on the right the labels for the various extinctions are generated by Template:Annotation:

  • You specify the position within the image at which each annotations is to appear.
  • Annotations may be links, including wikilinks.

Usage

This template will malfunction unless used within the templates Annotated image or Annotated image 4.

{{Annotation | left (in px)| top (in px) | text | text-align=left | font-size=12 | font-weight=bold | font-family=Times New Roman | background-color=#ffcccee | color=blue |line-height=1}}
where:

  • There are no keywords for the top, left and text parameters, which are mandatory and must appear in the order given above. The other parameters are optional, must be identified by their keywords (e.g. font-size=...), and may appear in any order.
  • left and top specify the annotation's position relative to the top left corner of the box that contains the image. i.e. the box' top left corner is 0,0. The box will usually be larger than the actual image, to make room for the annotations.
  • text is the text that will be displayed.
  • text-align can be set to left, center or right, and is only noticeable when the annotation spans multiple lines.
  • font-size is in px (pixel) units – CSS relative sizes are not supported.
  • font-weight is bold or normal.
  • font-family is the CSS name for the font, e.g. Times New Roman or Verdana
  • background-color defaults to transparent.
  • color is the color of the text and defaults to black, which is the default text color in most Wikipedia style sheets. In particular, it's best to use blue only for links.
  • line-height set the line height, e.g. 80% or 0.8, and is only noticeable when the annotation spans multiple lines.

Extended parameter names for use in other templates

Some of the parameters have alternative names that are used by containing templates to call Template:Annotation. The alternative names are provided in case the containing templates call other templates that use similar parameters.

These alternative names are provided so that the containing templates can provide default values for the corresponding parameters in Template:Annotation, and should not be used for any other purpose. Values specified using the basic parameter names listed above will over-ride the alternative names that are used by containing templates.

Here are the alternative names and the basic Template:Annotation parameters for which they set defaults:

Alternative name Basic name
annot-text-align text-align
annot-font-size font-size
annot-font-weight font-weight
annot-font-family font-family
annot-background-color background-color
annot-color color
The above documentation is transcluded from Template:Annotation/doc. (edit | history)
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://safernicotine.wiki/mediawiki/index.php?title=Template:Annotation&oldid=25608"
Last edited on 4 December 2022, at 18:45
Cookies help us deliver our services. By using our services, you agree to our use of cookies.
More information

Languages

      This page is not available in other languages.

      Safer nicotine wiki
      • Creative Commons Attribution-ShareAlike
      • Powered by MediaWiki
      • Monitored by WikiApiary
      • ipv6 ready
      • Powered by Semantic MediaWiki
      • This page was last modified on 4 December 2022, at 18:45. Warning: Page may not contain recent updates.
      • Content is available under Creative Commons Attribution-ShareAlike unless otherwise noted.
      • Privacy policy
      • About Safer nicotine wiki
      • Disclaimers
      • Terms of Use
      • Desktop
      • Data access
      • Developers
      • Statistics
      • Cookie statement