PDF Export omits text from the code macro

We use Confluence to provide technical support documentation and the code macro is used on many pages to display code examples.

Just noticed that some of the examples in the exported PDF made no sense at all. On investigation it became clear that when the example included a long line of hyphens (a comment to break up the text in the configuration file), some of the subsequent lines of code were simply omitted from the exported document. No idea why this is happening or how many other topics might be affected but not good behaviour.

The wiki text:


# JAVA ANALYSIS -------------------------------------------------------------------------------------




# Maintainability



Appears as expected in the browser but appears in the PDF as:







2 answers

1 accepted

0 votes
Accepted answer

On investigation, this turns out to be a problem only with my customized PDF stylesheet. If I delete my stylesheet and revert to the default Confluence PDF stylesheet then there is no problem (not a long-term option).

The workaround was to make sure that the lines of hyphens were shorter and did not wrap in the export.

Something went wrong with my pdf reader. I wanna convert pdf into text first. Any suggestion will be appreciated. Thanks in advance. How about the abovementioned one?




Related: pdf conversion to text

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Organizing your space just got easier - Page Tree Drag & Drop is here

Hi Community! I’m Elaine, Confluence Product Manager. You may have read my earlier post about page tree in space navigation sidebar. I'm excited to share another improvement that helps you organize ...

63 views 3 2
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