r2 - 16 Apr 2007 - 15:23:11 - TWikiAdminGroupYou are here: TWiki >  TWiki Web  > GluePlugin



This plugin will help you to write readable TWikiML by allowing tags and arguments to be formatted on multiple lines. This is done by removing whitespaces surrounding tilde characters at the beginning of a line and recombine consecutive lines again. Basically, there are two was of glueing and recombining lines by either removing all whitespaces between two lines or by removing all whitespaces and separateing lines with a single space. In addition, there's a helper character sequence that prevents the TWiki engine to interprete tags before the GluePlugin could reformat the text.


Line prefix Action
~~~<space> combine lines by removing all, insert one whitespaces
*~~<space> recombine lines by removing any whitespaces between them
%~~<space> escape tag interpretation

The <space> is a literal whitespace blank. The ~~~<space> and *~~<space> sequences are recognized only at the beginning of a line, whereas the %~~<space> escape sequence might appear everywhere. The basic anatomy of writing a TWiki tag using the GluePlugin is exemplified by

%~~ TAG{
~~~ key="
*~~      hello
~~~      world
*~~ "
~~~ }%
which will be recombined to
%<nop>TAG{ key="hello world" }%


You type:
This is a line
~~~ glued to another line.
You get (faked):
This is a line glued to another line.
You get if installed:
This is a line glued to another line.

You type:
*~~ Plugin
You get (faked):
You get if installed:

You type:




You get (faked):
Apples And Oranges
You get if installed:
Apples And Oranges

You type:
%~~ SEARCH{"GluePlugin"
~~~        nosearch="on" nosummary="on" nototal="on"
~~~        separator=", "
~~~        scope="topic"
~~~        format="$topic"
~~~ }%
You get (faked):
You get if installed:

Plugin Settings

  • Set SHORTDESCRIPTION = Enable TWikiML to span multiple lines

Plugin Installation Instructions

  • Download the ZIP file
  • Unzip it in your twiki installation directory. Content:
    File: Description:

  • (Dakar) Visit configure in your TWiki installation, and enable the plugin in the {Plugins} section.
  • If the plugin is installed correctly then the following two fruits will appear joined on one line: Apples and Oranges

Plugin Info

Plugin Author: TWiki:Main.MichaelDaum
Copyright ©: 2005-2006, Michael Daum
License: GPL (GNU General Public License)
Plugin Version: v1.51
Change History:  
28 Jul 2006: fixed MANIFEST; some minor docu updates; added use strict;
28 Aug 2005: changed glue syntax; added glue escape sequence to work arround tags been interpreted before lines are recombined
16 Aug 2005: properly support internal tags; performance improvements; fixed use if uninitialized value
15 Aug 2005: Initial version
TWiki Dependency: $TWiki::Plugins::VERSION 1.024
CPAN Dependencies: none
Other Dependencies: none
Perl Version: 5.005
TWiki:Plugins/Benchmark: GoodStyle nn%, FormattedSearch nn%, GluePlugin nn%
Plugin Home: TWiki:Plugins/GluePlugin
Feedback: TWiki:Plugins/GluePluginDev
Appraisal: TWiki:Plugins/GluePluginAppraisal

-- TWiki:Main.MichaelDaum - 28 Jul 2006

Edit | WYSIWYG | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r2 < r1 | More topic actions
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback
Note: Please contribute updates to this topic on TWiki.org at TWiki:TWiki.GluePlugin