Template:C: Difference between revisions

From VASP Wiki
(Created page with "{{#switch: {{{1}}} | vcyan = <span style="color:#2FB5AB">{{{2}}}</span> | vgrey = <span style="color:#808080">{{{2}}}</span> | vblue = <span style="color:#2C68FC">...")
 
mNo edit summary
 
Line 30: Line 30:
  {{C|#A8762C|Text colored in "#A8762C".}}</nowiki>
  {{C|#A8762C|Text colored in "#A8762C".}}</nowiki>
will produce
will produce
{{C|vcyan|Text colored in "vcyan".}}


{{C|vgrey|Text colored in "vgrey".}}
{{C|vcyan|Text colored in "vcyan".}}


{{C|vblue|Text colored in "vblue".}}
{{C|vgrey|Text colored in "vgrey".}}


{{C|vred|Text colored in "vred".}}
{{C|vblue|Text colored in "vblue".}}


{{C|vpurple|Text colored in "vpurple".}}
{{C|vred|Text colored in "vred".}}


{{C|#A8762C|Text colored in "#A8762C".}}
{{C|vpurple|Text colored in "vpurple".}}
 
{{C|#A8762C|Text colored in "#A8762C".}}
</noinclude>
</noinclude>

Latest revision as of 08:45, 8 October 2021

{{{2}}}

Purpose

This template colors text, given either predefined color names or hex values.

Parameters

 {{C|<color>|<text>}}
  • color: One of vcyan,vgrey,vblue,vred,vpurple, selects the color from the palette demonstrated in the examples below. Alternatively, pass a RGB color given in hex, e.g. #A8762C.
  • text: The text to be colored.

Examples

 {{C|vcyan|Text colored in "vcyan".}}

 {{C|vgrey|Text colored in "vgrey".}}

 {{C|vblue|Text colored in "vblue".}}

 {{C|vred|Text colored in "vred".}}

 {{C|vpurple|Text colored in "vpurple".}}

 {{C|#A8762C|Text colored in "#A8762C".}}

will produce

Text colored in "vcyan".

Text colored in "vgrey".

Text colored in "vblue".

Text colored in "vred".

Text colored in "vpurple".

Text colored in "#A8762C".