Jump to content

Template:Lighten/doc

From Wikipedia, the free encyclopedia

Usage

[edit]

Lightens a color. This template can be substituted (provided that the optional format template is substitutable).

Input
  • first 3 parameters: color to lighten as R, G, B color values, each numeric and in range 0..255
  • fourth parameter: amount by which to lighten in % (0 = no change, 100 = white)
  • optional format parameter: name of a template to format the RGB values (the default is {{Hex3}} an alternative is {{RGB}})
Output
  • lightened color as hexadecimal color code (if using Hex3)

Example

[edit]
  • {{Hex3|240|160|200}} gives #F0A0C8
  • {{Lighten|240|160|200| 0 }} gives #F0A0C8
  • {{Lighten|240|160|200| 20}} gives #F3B3D3
  • {{Lighten|240|160|200| 50}} gives #F8D0E4
  • {{Lighten|240|160|200| 80}} gives #FCECF4
  • {{Lighten|240|160|200|100}} gives #FFFFFF
  • {{subst:Hex3|240|160|200}} gives #F0A0C8
  • {{subst:Lighten|240|160|200| 20}} gives #F3B3D3
  • {{subst:Lighten|240|160|200| 50}} gives #F8D0E4
  • {{subst:Lighten|240|160|200| 80}} gives #FCECF4
  • {{subst:Lighten|240|160|200|100}} gives #FFFFFF
  • {{RGB|240|160|200}} gives rgb(240,160,200)
  • {{Lighten|240|160|200| 0 |format=RGB}} gives rgb(240,160,200)
  • {{Lighten|240|160|200| 20|format=RGB}} gives rgb(243,179,211)
  • {{Lighten|240|160|200| 50|format=RGB}} gives rgb(248,208,228)
  • {{Lighten|240|160|200| 80|format=RGB}} gives rgb(252,236,244)
  • {{Lighten|240|160|200|100|format=RGB}} gives rgb(255,255,255)
  • {{subst:RGB|240|160|200}} gives rgb(240,160,200)
  • {{subst:Lighten|240|160|200| 0 |format=RGB}} gives rgb(240,160,200)
  • {{subst:Lighten|240|160|200| 20|format=RGB}} gives rgb(243,179,211)
  • {{subst:Lighten|240|160|200| 50|format=RGB}} gives rgb(248,208,228)
  • {{subst:Lighten|240|160|200| 80|format=RGB}} gives rgb(252,236,244)
  • {{subst:Lighten|240|160|200|100|format=RGB}} gives rgb(255,255,255)

See also

[edit]