[dokuwiki] Re: Custom vertical spacing

  • From: Chris G <cl@xxxxxxxx>
  • To: dokuwiki@xxxxxxxxxxxxx
  • Date: Wed, 20 Jul 2011 11:01:47 +0100

On Mon, Jul 18, 2011 at 07:01:59PM +0200, Håkan Sandell wrote:
> Although wikis are not the preferred platform for text layout it's
> possible to create vertical whitespace where needed by inserting
> <div>'s and connect them to CSS styling of your choice. Try the
> plugin:wrap together with some additional CSS.
> 
It turned out that the best solution to my problem was to use the
"adjacent sibling" syntax in CSS.  What I wanted was for an unsigned
list below a paragraph to have a smaller vertical gap than anything else
under a paragraph, so:-

    div.dokuwiki p + ul {
      margin-top: -0.8em;
      }

Does *exactly* what I need.  I know there are issues in some browsers
with -ve margins but this is just for my own use and I always use
Firefox where it works fine.

-- 
Chris Green
-- 
DokuWiki mailing list - more info at
http://www.dokuwiki.org/mailinglist

Other related posts: