Template:Coltit
Revision as of 14:27, 6 December 2019 by imported>Crissov ({{number sign}})
This template might be used to color the background of a table cell; by the second parameter the text color can be specified. When the mouse pointer is located at the cell, the background color hex code triplet is displayed as a tooltip.
Contents
Usage
{{Coltit|RGB hex triplet of background color|RGB hex triplet of color|alignment letter|x=individual text}}
The template needs the colors hex code RGB or RRGGBB (not the color name); the 2nd parameters default value is 000 (black); possible alignement letters are: l (left), r (right) with default value center.
The parameter x= specifies a title text header different from its default value (color #).
Example
{| class="wikitable"
|{{Coltit|F00|0FF}}'''red''' and complementary color
|{{Coltit|#0ff|#f00}}'''turq''' and complementary color
|{{Coltit|rgb=12,34,56|color=75%,50%,25%}} using absolute 8-bit decimal and percentage RGB notation
|{{Coltit}} no parameters, all defaults
|{{Coltit|ffee11|x=yellow background colour}}
|-
| colspan=5 title="background color: #FB2" bgcolor=#FB2 style="color:#FB2;text-align:center" | '''The background should be <u>light orange</u>, not black   <small>(Internet Explorer ''short form bug'')'''</small>
|}
results in
| title="color TEMPLATE:NUMBER SIGNF00" style="background: Template:Number signF00; color: Template:Number sign0FF; text-align: auto"| red and complementary color | title="color TEMPLATE:NUMBER SIGN#0FF" style="background: Template:Number sign#0ff; color: Template:Number sign#f00; text-align: auto"| turq and complementary color | using absolute 8-bit decimal and percentage RGB notation | title="color TEMPLATE:NUMBER SIGNFFF" style="background: Template:Number signFFF; color: Template:Number sign000; text-align: auto"| no parameters, all defaults | title="yellow background colour" style="background: Template:Number signffee11; color: Template:Number sign000; text-align: auto"| |
| The background should be light orange, not black (Internet Explorer short form bug) | ||||
Move the mouse pointer to the table cell to see the background color value
See also
- {{Color}}
- {{Colors}}
- {{Background color}}
- {{Font color}}
- {{Resize}}
Sibling projects
{{Coltit}}(some differences, in German Wikipedia){{Coltit}}(more differences, in Wikimedia Commons)
| The above documentation is transcluded from Template:Coltit/doc. (edit | history) Editors can experiment in this template's sandbox (edit | diff) and testcases (edit) pages. Please add categories to the /doc subpage. Subpages of this template. |