Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8895359
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T23:45:21+00:00 2026-06-14T23:45:21+00:00

In our project I’d like to style our doxygen output differently. Currently the generated

  • 0

In our project I’d like to style our doxygen output differently.
Currently the generated html looks like the following:

<html>
<body>
    <h1> Heading 1 </h1>

    <h2> Heading 2.1 </h2>
    <p> Paragraph 2.1.1 </p>
    <p> Paragraph 2.1.2 </p>
    <p> Paragraph 2.1.3 </p>

    <h2> Heading 2.2 </h2>
    <p> Paragraph 2.2.1 </p>
    <p> Paragraph 2.2.2 </p>
    <p> Paragraph 2.2.3 </p>
</body>
</html>

The <h2> is only styled with a font-size attribute and all <h2> and <p> tags are aligned on the left side of the document.

To let the content below any <h2> tag stand out visually I would like to indent the tags until the next <h2> tag.

What I tried so far is the following CSS rule:

h2 + * {
    margin-left: 10px;
}

The * is used since there are also other tags present besides <p> tags.
However, this rule only indents the first paragraph following the <h2> tag and not all tags up to the next <h2> tag.

It should also be mentioned that the structure of the html can not be changed to wrap each section inside of a <div> for example.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T23:45:22+00:00Added an answer on June 14, 2026 at 11:45 pm

    It sounds like you want to indent all siblings after the first h2 except other h2s, in which case this should do the job:

    h2 ~ *:not(h2) {
        margin-left: 10px;
    }
    

    See the general sibling combinator and the negation pseudo-class as well as a live demo on jsbin.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our project currently uses Crystal Reports for Visual Studio 2008. We need to upgrade
Our project constitutes of many modules (e.g. a HR management system containing modules like
In our project we use Zend Framework Model generator, which produces something like this
In our project we are following agile practices ( Sprint ). So every day
Our project has a dependency like <dependency> <groupId>apollo.components.cots</groupId> <artifactId>cots-wfs</artifactId> </dependency> And as far as
Our project's template html has a quirks declaration,which is <!DOCTYPE HTML PUBLIC -//W3C//DTD HTML
Our project has two application contexts: application-context.xml application-context-test.xml Currently each file has duplicate bean
In our project we have something like this: struct PointI { // methods for
We have our project stored in subversion in following way: trunk (main development goes
Our project is based on J2EE and we would like to know if there

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.