CSS class for "Paragraph" text

If I use the source editor, the <p> stuff generated in the WYSIWYG editor does not have a class associated with it. Is there a way to associate a class with the "Paragraph" style? The reason is, when I use the scroll PDF exporter, I want to modify the font/size *only* for text generated as the Paragraph type in the WYSIWYG editor. If I modify it for all <p> tags, it obviously formats things I don't want it to. I'd like to be able to specify attributes for something like p.confluence.

Yes, I know I can change this with the source editor, but that's potentially doing hundreds or thousands of modifications for each document. I'd like the WYSIWYG editor to put it in automatically.

2 answers

0 votes
Sean Curtis Atlassian Team Apr 04, 2013

In lieu of adding a class to all paragraphs in the content what about just being more specific in selecting them? Something like:

.wiki-content &gt; p {
  ...
}

That will only target paragraphs that are at the "top level" (ie not in a macro). You may need to extend it to match other things like:

.wiki-content &gt; ul &gt; li &gt; p {
  ...
}

Where would I add this? In the CSS for the Scroll PDF exporter?

Sean Curtis Atlassian Team Apr 05, 2013
Yup. You may need to boost the specificity - I'm not familiar with the Scroll PDF exporter but it should work. Try it and see :)

For the Scroll PDF Exporter you can put it into Content Formatting panel of your template as described here: http://www.k15t.com/display/PDF/Formatting+the+Content.


@Stefan: Your link is dead because of the dot at the end.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 24, 2018 in Confluence

Atlassian Research opportunity with Confluence templates

Do you use templates with Confluence? Take part in a remote 1-hr workshop. You'll receive USD $100 for your time!   We're looking for people to participate in a   remote 1-hr workshop...

1,121 views 17 14
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you