Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Setup vertical rhythm and later on create a less mixin based

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #145530
    Bogdaniel
    Participant

    i’ve been googling alot for vertical rhythm found some tutorials about it but i didn’t quite understand from those examples how to setup vertical rhythm in css based on font-size and so on. Can someone provide a good example using default font size (16) and explain a little better the math behind it ?

    So far what i understood is something like this:

    body {
        font-size: 100; /* 16px */
        line-height: 1.5em; /* math -  (16 * 1.5) / 16 */
    }
    //then
    p {
       line-height: 1.5em
       margin-top: 1.5em
       margin-bottom: 15.em
    }
    

    but from here i don’t understand how it works and what should i do next.

    #145655
    Bogdaniel
    Participant

    bump :D

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘CSS’ is closed to new topics and replies.