[pmwiki-users] PmWiki/ConditionalMarkup

H. Fox haganfox at users.sourceforge.net
Thu Mar 9 15:58:01 CST 2006

On 3/9/06, Patrick R. Michaud <pmichaud at pobox.com> wrote:
> On Thu, Mar 09, 2006 at 12:34:46PM -0700, H. Fox wrote:
> > Earlier in the week I asked Pm to make the first two examples on that
> > page look the same, but he declined for now because it might break
> > existing content.
> Yes, but I'm beginning to dislike the inconsistency.  My
> suggestion is to start formatting things in the way that will
> work best *for authors*, and then we'll adjust the [@...@]
> markup to make it look right in skins.

As an author, I'd like the second example to not include the newline. 
The reason is because I want to have an easy way to style preformatted

Note that the indent doesn't matter.  Try the various ?skin= links on
this page to see the effect:


If there's another easy (best for authors) way to style preformatted
blocks, such as the proposed %code% wikistyle, then this isn't as

> > I think the last one would be a reasonable default wikistyle so we could use
> >
> > %code% [@
> > Bla bla
> > @]
> >
> > Is that any more author-friendly than
> >
> > -> [@
> > Yadda yadda
> > @]
> >
> > though?  In one way it is.  An author can more easily add additional
> > style attributes to the wikistyle version.  (Otherwise it
> > double-applies the wikistyle.)
> We can always do "-> %code% [@ ... @]" -- it double-applies
> the wikistyle if %code% has "apply=block" in it.

I don't understand... Since the left margin is already there (in the
%code& wikistyle definition), why would someone do "-> %code% [@ ...
@]"?  Why not just do "code margin-left=70px[@ ... @]" instead?

> Apply=block
> means to apply the style to any HTML block element on the line,
> and since that includes both <div> and <pre> (as well as lists),
> it makes it appear as though it's being applied twice.  Define %code%
> with apply=div or apply=pre and it should be applied only once.

If I try replacing this working wikistyle definition (the one I'm
proposing for the core)

    %define=code block padding:4px margin-left:30px%

with any of these

   %define=code pre padding:4px margin-left:30px%
   %define=code apply=pre padding::4px margin-left:30px%
   %define=code block apply=pre padding:4px margin-left:30px%

it stops working properly


More information about the pmwiki-users mailing list