wiki:ColorMacro

Version 1 (modified by David Roussel, 17 years ago) (diff)

New hack ColorMacro, created by diroussel

Color Macro

Description

ColorMacro is a very simple macro that allows you to change the background color of a piece of text. Useful for highlighting, or RAG (red, amber, green) status reports.

Usage:

  [[Color( background-color, color , text )]]

or

  [[Color( color , text )]]

Where:

color
is a color keyword or hex color number recognised by your browser
text
any text or html you like

Bugs/Feature Requests

Existing bugs and feature requests for ColorMacro are here.

If you have any issues, create a new ticket.

Download

Download the zipped source from [download:colormacro here].

Source

You can check out ColorMacro from here using Subversion, or browse the source with Trac.

Example

Example:

  [[Color(red,This has a red background)]]
  [[Color(blue, green,This has a blue background and green text)]]
  [[Color(none,#bb0000,I'm using a hex color)]]

Giving:

<span style="background-color:red;padding: 0.1ex 0.4em;">This has a red background</span> <span style="background-color:blue;padding: 0.1ex 0.4em;color: green;">This has a blue background and green text</span> <span style="background-color:none;padding: 0.1ex 0.4em;color:#bb0000;">I'm using a hex color</span>

Recent Changes

15929 by rjollos on 2016-10-17 22:27:00
1.0: Change format of version metadata
15922 by rjollos on 2016-10-17 22:04:00
1.0: Format metadata
15901 by rjollos on 2016-09-20 21:10:25
1.0: Add plugin metadata
(more)

Author/Contributors

Author: diroussel
Contributors: