Skip to main content
Spectrum Writing
Inspiring
January 24, 2020
Question

Changing the formatting and layout of an autonumbered paragraph

  • January 24, 2020
  • 23 replies
  • 536 views

I am wanting to create four paragraph styles in my RH2019 (Version 10) project. Each style is to be autonumbered with text:

 

WARNING

CAUTION

TIP 

NOTE

 

I create a new paragraph style and in the Autonumber pane for the properties, I set the style to None, and the format to the text, for example, WARNING:.

 

When I apply this style to text in a topic, I do indeed get the expected autonumber, and then I can add the appropriate text after the autonumber. However, I want the autonumber to be in bold, and I want to decrease the space between the autonumber and the following text. Where can I adjust these properties for an autonumbered style? Because it is not a List style, but a Paragraph style that I am creating, I do not see these options. I don't want to have to create a List style to be able to accomplish this task, but. . . .

TIA,

 

TVB

This topic has been closed for replies.

23 replies

Peter Grainge
Community Expert
Community Expert
January 25, 2020

Got it. Add the two lines shown below as well. I have set an extreme gap to show it works. Change 24pt to whatever measurement you want.

 

p.warning::before {
--prefix-gap: 24pt;
margin-right: var(--prefix-gap);
counter-increment: p\.warning;
content: "WARNING";
font-weight: bold;
padding-right: 0.5rem;
}

 


www.grainge.org

Use the menu (bottom right) to mark the Best Answer or Highlight particularly useful replies. Found the answer elsewhere? Share it here.
Peter Grainge
Community Expert
Community Expert
January 25, 2020

I am not sure where Amber is seeing the arrow as I believe we are on different updates. However, open the CSS in RoboHelp and then click the Source view icon you will find your style looks something like this without the font-weight. Add that line.

 

p.warning {}
p.warning::before {
counter-increment: p\.warning;
content: "WARNING";
font-weight: bold;
padding-right: 0.5rem;
}

 

You should then see this.

 

 

I haven't been able to adjust the gap yet.


www.grainge.org

Use the menu (bottom right) to mark the Best Answer or Highlight particularly useful replies. Found the answer elsewhere? Share it here.
Community Expert
January 25, 2020

If you look at the p.Note style in your styesheet you should see it has an arrow. Click the arrow and you should see ::before. Click that and make your changes.