Avatar

Suggestion: text color editor (Features)

by Alfie ⌂, Vienna, Austria, Sunday, April 22, 2007, 17:27 (6213 days ago) @ needhelp338
edited by Alfie, Monday, April 23, 2007, 00:49

Hi!

...it would be nice to have a COLOR option so that we can put certain text in RED or GREEN to draw attention to certain keywords in our post.

[color=rgb(0,128,0)]Is already implemented[/color] (see this post).

The BB-code syntax follows [ color=foo]bar[/color] (remove the blank after the first bracket), and translated into (X)HTML:

<span style="color:foo;">bar</span>

Accepted values for color are one of the defined (X)HTML named properties (aqua, black, blue, fuchsia, gray, green, lime, maroon, navy, olive, purple, red, silver, teal, white, yellow).
The additional 120 named Netscape colors (like [color=darkblue]darkblue[/color]) may work as well, but their interpretion is browser-dependent).
RGB-definitions, either as HEX-values from #000000 (black) to #FFFFFF (white) [not case-sensitive], or as an integer (0-255) e.g. [color=rgb(128,128,128)]rgb(128,128,128)[/color] for medium gray) will always work.

Examples:
[ color=red]test[/color]: test
[ color=darkorange]test[/color]: [color=darkorange]test[/color]
[ color=#FFCC00]test[/color]: [color=#FFCC00]test[/color]
[ color=rgb(128,128,128)]test[/color]: [color=rgb(128,128,128)]test[/color]

--
Cheers,
Alfie (Helmut Schütz)
BEBA-Forum (v1.8β)

locked
8825 views

Complete thread:

 RSS Feed of thread