Question


The counter-increment works in my code, but I want to start the counter at 100 on the first section, and 200 on the next.

This is what I got:

Chapter>Section>Subsec1>Subsec2>Tit {
    display: block;
    text-align: left;
    font-weight: bold;
    margin-top: 15px;
    font-size:16px;

    counter-increment: subsection2;
}

Is there a simple solution to this?

Was it helpful?

Solution

You can specify what the counter should be increased with by adding a number after the counter name, like this:

counter-increment: counter-name 100;

You can do the same thing with counter-reset, but since you want the first incrementation to be 100 you should start at 0

More info here: https://developer.mozilla.org/en-US/docs/Web/CSS/counter-increment

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top