[pmwiki-users] :linebreaks: as wikistyle

Patrick R. Michaud pmichaud at pobox.com
Sat Sep 30 14:06:14 CDT 2006


On Sat, Sep 30, 2006 at 07:00:14PM +0200, Mike wrote:
> > But it ought to be doable with a (numbered) div:
> 
> Why does this work? What's the impact of the (:div999:) directive? It
> isn't defined anywhere, so I don't understand its impact. To me it seems
> that the blue color is achieved by the stuff in between the %% signs...

The %% signs are a wikistyle.  The "div" inside the %% means that we
want this wikistyle to apply to a div, instead of to the remainder
of the line.

The (:div999:) is just a special case of the (:div:) directive.
Normally, for a request such as yours, I would tell people to write
the following:

    >>color=blue<<
    This text is blue

However, the >>...<< will be closed by the next >>...<< or (:div:)
directive, whereas your request was that the color explicitly
extend to the end of the page.

It turns out that >>color=blue<< is just a convenient shortcut 
for writing

    (:div:) %color=blue div%

which creates a div.  But (:div:) by itself doesn't nest (as with
most things in PmWiki).  So, an author can suffix a (:div:) with a
number to distinguish one (:div:) markup from another, as in (:div1:),
(:div2:), (:div3:), etc.

So, in the case of (:div999:), I'm simply starting a new div that
won't be closed until the end of the page.  Any wikistyles applied
to that div will apply to the end of the page (or until the next
(:div999:) directive, which isn't likely to occur).

Pm




More information about the pmwiki-users mailing list