Patrick R. Michaud
pmichaud at pobox.com
Thu Mar 9 18:39:06 CST 2006
On Thu, Mar 09, 2006 at 04:22:11PM -0700, H. Fox wrote:
> > In short, I think it makes sense for something like
> > %code% to identify things such as borders, background
> > color, font,
> Some of those might clash with a skin or two. (For example, imagine
> if someone tries a white-on-black page template. I once tried, but
> too much styling was hard-coded into PmWiki at the time.)
I don't think we can have a default that gets everything right
in every possible situation. :-) If someone installs a white-on-black
template, I don't think it's too much to ask that the admin
(or the skin.php) fix up the %code% style.
> In that case maybe we've come full circle, where
> Shouldn't produce a trailing blank line.
I've looked into it further, and now I've figured out where the
trailing blank line is coming from. I thought the code was
preserving the newline that is immediately before the @] ...
but couldn't figure out why it would disappear in the other
examples. That's not what is happening -- the trailing newline
(and whitespace) inside the [@...@] *is* being removed, it's
the newline that comes *after* the @] that is generating
the blank line, because it's in a (top-level) preformatted block.
That's why an initial %% or --> changes everything, because those
change the generation of the preformatted block.
I'll have to do some tests to see how to reliably get rid of
that extra line, as I agree it shouldn't be there. (There's
an outside chance it won't be possible without breaking a
lot of other stuff.)
More information about the pmwiki-users