Confluence
  1. Confluence
  2. CONF-22263

PDF export doesn't render the content of a code macro inside an include macro

    Details

    • Last commented by user?:
      true

      Description

      When you have two pages with the macro code and in one of them you insert a include macro pointing to the other page which contains the code macro renders correctly, but when you export the page, it doesn't show the include macro with the other page.

      Example: Page A contains

      test
      

      Page B contains

      {include:A}
      test2
      

      When you export page B to pdf, it will only show 'test2' and not 'test'

        Issue Links

          Activity

          Rodrigo Girardi Adami [Atlassian] created issue -
          Rodrigo Girardi Adami [Atlassian] made changes -
          Field Original Value New Value
          Description When you have two pages with the macro code and in one of them you insert a include macro pointing to the other page which contains the code macro renders correctly, but when you export the page, it doesn't show the include macro with the other page.

          Example: Page A contains
          {code}
          test
          {code}

          Page B constains
          {include:A}
          {code}
          test2
          {code}

          When you export page B to pdf, it will only show 'test2' and not 'test'
          When you have two pages with the macro code and in one of them you insert a include macro pointing to the other page which contains the code macro renders correctly, but when you export the page, it doesn't show the include macro with the other page.

          Example: Page A contains
          {code}
          test
          {code}

          Page B contains
          {include:A}
          {code}
          test2
          {code}

          When you export page B to pdf, it will only show 'test2' and not 'test'
          Vincent Choy [Atlassian] made changes -
          Status New [ 10034 ] Open [ 1 ]
          HengHwa Loi [Atlassian] made changes -
          Labels bugfix_support_backlog
          Mark Hrynczak [Atlassian] made changes -
          Summary PDF export doesn't render correctly when include and code macro are on same page PDF export doesn't render the content of a code macro inside an include macro
          Priority Minor [ 4 ] Critical [ 2 ]
          Mark Hrynczak [Atlassian] made changes -
          Link This issue is related to CONF-22669 [ CONF-22669 ]
          Matt Ryall [Atlassian] made changes -
          Workflow Conf Bug Quality Review WorkFlow [ 284412 ] Confluence Bug Workflow [ 333631 ]
          Hide
          Matthias added a comment -

          This also affects version 4.0

          Show
          Matthias added a comment - This also affects version 4.0
          Joseph Clark [Atlassian] made changes -
          Remote Link This issue links to "NCODE-187 (Web Link)" [ 11213 ]
          Joseph Clark [Atlassian] made changes -
          Remote Link This issue links to "ADVMACROS-226 (Web Link)" [ 11220 ]
          Hide
          Joseph Clark [Atlassian] added a comment -

          This is fixed in Advanced Macros Plugin version 2.0.30 available for download from plugins.atlassian.com - https://plugins.atlassian.com/plugin/details/145?versionId=767102

          Show
          Joseph Clark [Atlassian] added a comment - This is fixed in Advanced Macros Plugin version 2.0.30 available for download from plugins.atlassian.com - https://plugins.atlassian.com/plugin/details/145?versionId=767102
          Joseph Clark [Atlassian] made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Assignee Joseph Clark [Atlassian] [ jclark@atlassian.com ]
          Fix Version/s 4.0 [ 15862 ]
          Resolution Fixed [ 1 ]
          Hide
          Nata added a comment -

          I have found a workaround for the code bug.
          1) Disable the built-in code plugin.
          2) Create a new user macro with the name "code". It should generate wiki markup like this:

          {html}
          <div style="line-break:strict !important; white-space: pre !important; font-family:courier !important; border-style:dashed !important; padding:0px 10px 10px 10px !important; border-color:grey; border-width:1px; border-radius: 3px; overflow: auto;">
          <b style="position:relative; top: 0px;">$body</b>
          </div>{html}

          3) Define the style for code in PDF.

          Maybe this can help someone.

          Show
          Nata added a comment - I have found a workaround for the code bug. 1) Disable the built-in code plugin. 2) Create a new user macro with the name "code". It should generate wiki markup like this: {html} <div style="line-break:strict !important; white-space: pre !important; font-family:courier !important; border-style:dashed !important; padding:0px 10px 10px 10px !important; border-color:grey; border-width:1px; border-radius: 3px; overflow: auto;"> <b style="position:relative; top: 0px;">$body</b> </div>{html} 3) Define the style for code in PDF. Maybe this can help someone.
          Anatoli Kazatchkov [Administrative Account] made changes -
          Workflow Confluence Bug Workflow [ 333631 ] New Confluence Default Workflow [ 467325 ]

            People

            • Votes:
              4 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Last commented:
                2 years, 5 weeks, 5 days ago