DokuWiki

It's better when it's simple

User Tools

Site Tools


plugin:cellbg

This is an old revision of the document!


Cell Background Plugin

Compatible with DokuWiki

rincewind, angua, adora belle, binky, 2014-09-29d

plugin Allows user-defined background colored cells in tables

Last updated on
2013-10-09
Provides
Syntax
Repository
Source
Conflicts with
block, note, sortablejs

This extension has not been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues.

Tagged with color, formatting, highlight, tables

Download and Installation

Download and install the plugin using the Plugin Manager using the URL given above. Refer to Plugins on how to install plugins manually.

Syntax and Usage

A background color is introduced by @ and ended by :.
You can use all names and color codes from HTML.
If you don't specify a color, yellow is used.
See examples below:

Examples

This code :

^  Header 1         ^  Header 2  ^  Header 3        ^
|  @lightgreen:**Span**         ||                  |
|  @#6495ed:Ligne 1 |  Oui       |  Oui, à valider  |
|  Ligne 2          |  Oui       |  @orange: Oui    |
|  @:Ligne 3        |  Oui       | @red:Non         |

looks like :
exemple 1 preview

This one :

|  @palegreen:Validé  |  @orange:À valider  |  @red:Non fonctionnel  |

looks like :
exemple 2 preview

Wikis using cellbg

Features

  • Uses HTML color codes and names HTML Color Code Chart
  • Works with other table formatting (alignment, bold, …)

Limitations

  • Doesn't work with header lines (^ character), so just don't use them if you want a specific color for these lines
  • May not work with plugins introducing a different syntax than the DokuWiki one for tables
  • If “@…:” pattern is found out of a table, it might disable other syntax inside it (not sure about that).

How it works

It's a hack that edit previously formatted text :

  • detect if in a table by looking for a <td…> markup in the previously formatted text ($renderer→doc) ;
  • edit the formatted text and add bgcolor= inside the previous <td> markup ;
  • if not in a table : add the text in the formatted text as is.

Changes

Bugs

@: syntax

@: syntax don't work with DokuWiki on Debian lenny : 0.0.20080505-4+lenny1
Bug : https://github.com/dr4Ke/cellbg/issues/issue/1

Automatic installation on 20080505 fails

Automatic installation on 20080505 fails with :

The plugin manager was unable to decompress the downloaded file. This maybe as a result of a bad download, in which case you should try again; or the compression format may be unknown, in which case you will need to download and install the plugin manually.

Manual installation works fine. Bug : https://github.com/dr4Ke/cellbg/issues/issue/2

Compatibility Issues

Please apply the patch from Richard MICHALOWICZ below. Otherwise the plugin bureaucracy will be broken under 2013-12-08 „Binky“. – Alois Hockenschlohe (2014/01/16)

In order to solve the problem related with the 2013-05-10a “Weatherwax” (ReferenceError: addInitEvent is not defined) you must change in the file <dokuwiki_install_dir>/lib/plugins/cellbg/script.js the last line as this:

  • old line: addInitEvent(plugin_cellbg_toolbar_picker);
  • new line: jQuery(plugin_cellbg_toolbar_picker);

That solved the Error and the compatibility between cellbg and the new Jquery motor is OK.
Richard MICHALOWICZ (2013/07/24)

Tried in “Weatherwax” (Release 2013-05-10) and I've nothing to report so far, it seems ok : — Adam Douglas 2013/07/10 09:32

Tried in “Adora Belle”, and I've nothing to report so far, it seams ok : — Andy 2012/11/30 01:03

Tried in “Anteater”, and I've nothing to report so far, it seams ok : — antoniomch 2011/04/05 13:11

Tried in “Rincewind” and I've nothing to report so far, it seems ok : — Philippe jourdren 2011/12/14 07:45

plugin/cellbg.1442159050.txt.gz · Last modified: 2015-09-13 17:44 by Aleksandr

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki