Revision [297]

This is an old revision of ColorActionInfo made by YanB on 2006-11-19 09:13:05.

 

HomePage

Color/ Colour Action Documentation

This is the documentation page for the Color / Colour action(s).

Once the planned 'autodoc' feature for actions is "live", this page will contain the automatically-generated documentation by just including an action; for now, I've just manually created the text.



Documentation


Short description
Renders a string as colored text.

Parameters
nametyperequired?defaultdescription
textstringmandatory-the text you want to display colored
cstringoptional-(html)name or hex-value of the color for the text
bgstringoptional-(html)name or hex-value for the backgroundcolor
fgstringoptional-alias for 'c', introduced to fit with 'bg'
hexstringoptional-alias for 'c', kept for backwards-compatibility;


Long description
With the actions "color" and "colour" (the later one is a synonymon) you can specifiy the color either as one of HTML defined names or as a hex-value (with the former one taking priority). An optional background color can also be specified.

Note that you must add a text and either use "c" or "hex" for the color.

Usage:
{{color [text="This is my text"] [c="red"]}}


Examples:
{{color c="green" text="This is a test."}}
gives:
This is a test.

If you want to use hex values:

{{color hex="#DD0000" text="This is another test."}}
to give:
This is another test.

Alternatively, you can specify a foreground and background color using the fg and bg parameters (they accept both named and hex values):

{{color fg="#FF0000" bg="#000000" text="This is colored text on colored background"}}

This is colored text on colored background

{{color fg="lightgreen" bg="black" text="This is colored text on colored background"}}

This is colored text on colored background


Authors

CategoryEN
There are no comments on this page.
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki