Difference between revisions of "ColourPercentBG"
From NEC Retro
Line 4: | Line 4: | ||
|value={{{value|}}} | |value={{{value|}}} | ||
}}}}{{ | }}}}{{ | ||
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.88888888|{{ |
− | |||
− | |||
− | |||
− | |||
− | |||
#vardefine:startcolour|{{WikiColour|BG|magenta}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|magenta}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|redmagenta}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|redmagenta}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.88888888)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.77777777|{{ |
#vardefine:startcolour|{{WikiColour|BG|purple}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|purple}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|magenta}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|magenta}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.77777777)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.66666666|{{ |
#vardefine:startcolour|{{WikiColour|BG|blue}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|blue}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|purple}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|purple}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.66666666)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.55555555|{{ |
#vardefine:startcolour|{{WikiColour|BG|cyan}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|cyan}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|blue}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|blue}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.55555555)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.44444444|{{ |
#vardefine:startcolour|{{WikiColour|BG|green}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|green}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|cyan}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|cyan}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.44444444)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.33333333|{{ |
#vardefine:startcolour|{{WikiColour|BG|yellowgreen}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|yellowgreen}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|green}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|green}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.33333333)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.22222222|{{ |
#vardefine:startcolour|{{WikiColour|BG|yellow}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|yellow}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|yellowgreen}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|yellowgreen}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.22222222)*9}}}}|{{ |
− | #ifexpr:{{#var:colourvalue}} > 0. | + | #ifexpr:{{#var:colourvalue}} > 0.11111111|{{ |
#vardefine:startcolour|{{WikiColour|BG|orange}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|orange}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|yellow}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|yellow}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0. | + | #vardefine:newvalue|{{#expr:({{#var:colourvalue}}-0.11111111)*9}}}}|{{ |
#ifexpr:{{#var:colourvalue}} >= 0.0|{{ | #ifexpr:{{#var:colourvalue}} >= 0.0|{{ | ||
#vardefine:startcolour|{{WikiColour|BG|red}}}}{{ | #vardefine:startcolour|{{WikiColour|BG|red}}}}{{ | ||
#vardefine:endcolour|{{WikiColour|BG|orange}}}}{{ | #vardefine:endcolour|{{WikiColour|BG|orange}}}}{{ | ||
− | #vardefine:newvalue|{{#expr:{{#var:colourvalue}}* | + | #vardefine:newvalue|{{#expr:{{#var:colourvalue}}*9}}}}|}} |
− | + | }}}}}}}}}}}}}}}}{{ | |
#vardefine:rmin|{{Hex2Dec|{{#sub:{{#var:startcolour}}|0|2}}}}}}{{ | #vardefine:rmin|{{Hex2Dec|{{#sub:{{#var:startcolour}}|0|2}}}}}}{{ | ||
#vardefine:rmax|{{Hex2Dec|{{#sub:{{#var:endcolour}}|0|2}}}}}}{{ | #vardefine:rmax|{{Hex2Dec|{{#sub:{{#var:endcolour}}|0|2}}}}}}{{ |
Latest revision as of 14:14, 24 February 2022
0 | 10 | 20 | 30 | 40 | 50 | 60 | 70 | 80 | 90 | 100 |
128KB | 256KB | 384KB | 640KB | 1.6MB | 1.8MB | 2.0MB | 3.6MB | 5.6MB | 7.6MB |
8086 | 8086-2 | V30 | 286 | 386SX | 386DX | V30HL | i486SX | i486SX2 | i486DX2 | Pentium |
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 |
Pleasing multi-coloured background colours for tables. "Key" colours defined in Template:WikiColour.
{{ColourPercentBG|min=1|max=30|value=21}}
rgb(193.20689835172, 200.48275760069, 255)