h1 line spacing

This topic contains 3 replies, has 7 voices, and was last updated by  Roland 5 years, 9 months ago.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #14432

    Roland
    Member

    Couldn’t find this in the forumg . . .

    When using a long subject line with h1 we experience larger than desired spacing between the lines of h1 text (see pic)

    This is code that I input into the parent theme in an attempt to correct it:
    }
    h1.entry-title {
    line-height: 1.000em;
    }

    but that didn’t adjust anything.

    Any suggestions?
    h1spacing.jpg

    Attachments:
    You must be logged in to view attached files.
    #18769

    Sushil Adhikari
    Moderator

    That selector with the .entry-title class is for post and page titles. For yours, I don’t know what your content source code looks like but if you have those three lines as H1, you will need to create your own custom class for the content being wrapped in an H1 tag, then style it with your font size and/or line height.

    content here

    #18771

    Roland
    Member

    Is there a tutorial on that?

    #14433

    Sushil Adhikari
    Moderator

    No tutorial, sorry. But for something like this, you would do your css like this:

    h1.myclass {line-height: 14pc;}

    Check out online tutorials for creating classes and other css to help out. One site to bookmark as a reference is http://www.w3schools.com

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.