[pmwiki-users] Re: Re: Modified (:markup:)

Patrick R. Michaud pmichaud at pobox.com
Sun Mar 20 16:20:52 CST 2005


On Sun, Mar 20, 2005 at 09:09:37PM +0100, chr at home.se wrote:
> > Er, no, if only because the order of operations is misplaced here.  The
> > current (:markup:) directive takes place very early in the sequence --
> > even before [=...=] is processed.
> 
> Oh... ok, I see. That's not exactly apparent btw...  I assume (:markup:) 
> is done before (:include:) as well? 

Yes, if only because [=...=] is done before (:include:).  This isn't to
say that (:markup:)'s position is optimal -- again, I just threw it in
during 2.0.develXX to get something going and planned to refine it later.
(I guess "later" has arrived and is now "now". :-)

> > And I *really* dislike the idea of directive markups that span multiple
> > lines in a single directive, as in
> 
> Mileage varies I guess... to me it's not that different from:
> 	[[This is the link text \
> 	  -> http://long.and.complicated.uri/much/too/long/in/fact]]
> 
> but that doesn't mean I like it of course.

The difference being that the \ at the end of each line is an explicit 
visual cue that things continue onto the next line -- (:markup ...:) 
across several lines doesn't have such a cue.

> Hmm... if (:markup:) is parsed before [=...=], couldn't the above simply
> be written as:
> 
> 	(:markup:)
> 	You can use [=...=] to escape things.
> 	(:markupend:)

Sure, and that's what I was doing.  The problem arose with

    (:markup:)
    [=
    The argument to the markup text.
    =]
    
which is currently valid in beta26 but would cause problems in
the new scheme if a (:markup:)...(:markupend:) arises later in the same
page.  That's why we need the restriction that a [=...=] argument to 
(:markup:) must start on the same line, to be able to differentiate
the two.

> > Then we can also allow (:markup:) with a single escaped string on the
> > same line.
> 
> Eh... with "the same line", do you mean:
> 	(:markup:) [=Bla bla [[link]] bla=]
> or
> 	(:markup:) [=
> 	Bla bla ...
> 	=]
> ?

Well, as far as PmWiki is concerned they're effectively the same.  :-)

> For instance, I've sometimes written "Wiki[==]Word" to prevent a word 
> from being treated as a wiki word (this was with pmwiki v1). What happens 
> on a line like this:
> 
> 	The Pm[==]Wiki [[engine]] is useful and allows Wiki[==]Words.
> 
> Would [[engine]] become a link or not?

Oops, you're right, this breaks.  Back to my drawing board.

Pm



More information about the pmwiki-users mailing list