HELP! Export to PDF destroy indentation

Andy's Avatar

Andy

Nov 30, 2016 @ 05:40 AM

This is my Markdown written using MacDown: http://imgur.com/a/x4MIa

How it looks like in Marked2: http://imgur.com/a/mRNJR

How it looks like after export to PDF and opened in Preview: http://imgur.com/a/p22Zv

The indentation is all gone. This problem never happened before I updated it to the latest Marked2. Please help

  1. Support Staff 1 Posted by Brett on Nov 30, 2016 @ 07:25 AM

    Brett's Avatar

    Which style are you using, and which syntax highlight theme? Can you test with a different theme for both and let me know if it's specific to a certain style?

    - Brett

  2. 2 Posted by laucherhan on Dec 01, 2016 @ 01:58 AM

    laucherhan's Avatar

    I tried, they are all the same even using Swiss. Guess is the same problem as

    http://support.markedapp.com/discussions/problems/132108-pdf-losing-spaces-in-code-block

    only happen with the new version of Marked2, was working fine before.

  3. Support Staff 3 Posted by Brett on Dec 01, 2016 @ 02:16 AM

    Brett's Avatar

    Yes, it's a known issue. Hope to have a fix tomorrow.

    - Brett

  4. Support Staff 4 Posted by Brett on Dec 01, 2016 @ 08:54 PM

    Brett's Avatar

    Ok, I've found and corrected the issue for the next update. Here's the temporary workaround:

    1. Go to Preferences -> Style
    2. Under the Theme section, click Additional CSS
    3. Add this line to the field:

      @media print { pre>code { white-space: pre!important; } }
      

    This will restore spaces in the code block output.

  5. Brett closed this discussion on Dec 01, 2016 @ 08:54 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac