[pmwiki-users] vspace revisited
list_ob at gmx.net
Wed Jul 27 06:11:15 CDT 2011
Petko Yotov wrote:
>> Nevertheless the tons of class='vspace' are not exactly beautiful.
>> I talked to several very experienced web designers about using PmWiki
>> as a CMS, and most of them strongly disliked the lots of CSS
>> statements in the markup and the vspace handling.
>I'm not sure I completely understand what you want. I understand that you
>don't like how PmWiki handles vertical spaces, but what do you want?
First, I don't say that I generally dislike that PmWiki handles
vertical space. Not doing web design as main profession, I'm unbiased
and open. A sophisticated web designer may claim that today everything
has to be done in CSS because it's the "right way".
Currently I do not want to start a discussion whether PmWiki needs to
handle vertical space or not because I don't know enough about the
I mainly want to collect details about the presentation goals, and I'm
interested in constructs being difficult to handle "only with CSS".
But even looking unbiased at the code generated by PmWiki I see
several elements having vspace tags in _most_ cases (e.g. <p>), so I
wonder whether it wouldn't be nicer to suppress the top margin where
it's _not_ needed.
OTOH if there is a clean and simple "CSS only" solution, this question
>Do you want the HTML to not contain class="vspace" in <p> tags, and no empty
><div class="vspace"><div> ? If so, add to config.php such a line:
Maybe - I'm not yet ready to decide.
> Markup('disablevspace', '<<vspace><p>', '/<:*vspace>/', '');
>(If the page has a WikiStyle %p vspace%, it will still create <p
I use $HTMLVSpace = ''. Don't know how this differs from your
And I put it in the skin.php, this way I don't break other skins.
>> I started a test case http://www.pmwiki.org/wiki/Test/Vspace to
>> demonstrate the current PmWiki behaviour and "interesting" situations.
>This page can be seen with all <vspace> tags removed: go to
This doesn't work because if I suppress the PmWiki vspace handling,
the css has to take care about the margins.
I consider vspace handling being part of a "skin".
(misaligned results with monobook skin)
>This comes from different margins, paddings and/or line-heights in list
>containers, list items and paragraps, defined by the CSS of the skin. Removing
>the vspace doesn't change it:
sure. It was just an example that a well defined presentation goal and
testcases are useful if someone makes a new skin.
Finally, I think PmWiki makes a very good CMS, but experienced people
told me that the generated code has room for improvements.
Where it's little effort, it should be done. See
http://www.pmwiki.org/wiki/Cookbook/XHTMLStrict for example. I don't
know how much I missed in this collection, but it seems pretty easy to
me to avoid old constructs. Even if these will be handled by the
browsers, it's better to have less _unnecessary_ validation errors so
the real errors are noticed safely.
More information about the pmwiki-users