[pmwiki-users] Proposed Default Stylesheet (pmwiki.css)

Joachim Durchholz jo at durchholz.org
Sun Feb 19 13:25:04 CST 2006


Patrick R. Michaud schrieb:
> But going a bit further, I think this also means that every paragraph 
> (or partial paragraph that is enclosed in <p>...</p>) must be followed 
> by full paragraph whitespace, yes?  In other words, there's not a way 
> to use the settings you've just described and get something like
> what currently exists in the Cookbook.GeminiSkin page...?
> 
>     '''Colour Schemes'''
>     * Blue colours
>     * Sky colours
>     * Sky-Blue colours
>     * Sand colours
> 
> With the <p> elements having a full margin-bottom component, that 
> would mean that the list would end up with vertical whitespace between
> "Colour schemes" and the first item in the list,  yes?  How could
> we deal with that?

When collapsing margins, the most negative margin given is deducted from 
the most positive one. I.e. if a <p> is followed by a <ul>, and the <p> 
has a margin of 1em and the <ul> one of -1em, the two cancel each other out.

The bad thing is that two <ul> following each other will have a net 
margin of -1em, making them overlap. (IE will indeed produce the 
overlap. Firefox does not. I'm not sure which of them is right, but it 
confirms that using negative margins is probably not a good idea.)


I see to reasonable decisions at this time:
1) Punt on the issue, and always have that empty space between 
enumeration and normal text. That's how HTML was designed after all.
2) Detect the situation, and insert a paragraph with a 0.1 pixel height 
between adjacent <ul>s (and anything else that's paragraph-like in HTML 
but isn't in PmWiki). It's an ugly hack IMNSHO.




More information about the pmwiki-users mailing list