Option to show tabs at start of paragraph

Tony Helinsky's Avatar

Tony Helinsky

31 Aug, 2015 06:20 AM

Sometimes when writing some people in some situations prefer to actually use tabs to indent all paragraphs but the first paragraph after a heading.

When previewing such a document in Marked 2 (and most other Markdown previewers) such a tab is removed.

it would be awesome if it would be possible to add a feature to Marked 2 to optionally select to keep tabs at start of paragraph when rendering.

Thanks for listening!

  1. Support Staff 1 Posted by Brett on 02 Sep, 2015 11:18 AM

    Brett's Avatar

    Leading indentation is always ignored in Markdown, and an empty line is
    required to start a new paragraph. It's not worth indenting the way you
    have in the original Markdown, you'd be far better served to add space
    between paragraphs and start text at the left edge. You can then modify
    the output using CSS. Either in a custom style or in the Additional CSS
    field in Style preferences, use something like:

    p {
       margin-top: 0;
       margin-bottom: 0;
       padding-bottom: 0;
    }
    p + p {
       text-indent: 2em;
    }

    -Brett

  2. 2 Posted by Tony Helinsky on 02 Sep, 2015 02:05 PM

    Tony Helinsky's Avatar

    Thanks for your reply.

    I know that what you are saying is the correct way to do it.

    It is just that for some type of writing this way of writing with indentation and without empty lines between paragraphs as it flows really well and is easier to follow. In some strange instances.

    It would be super duper amazingly fabulous if it was possible to optionally honor indentation, even though it is against the rules and the standard.

  3. 3 Posted by Tony Helinsky on 02 Sep, 2015 02:19 PM

    Tony Helinsky's Avatar

    Hi

    Thanks for your reply.

    I know that what you are saying is the correct way to do it.

    It is just that for some type of writing this way of writing with indentation and without empty lines between paragraphs as it flows really well and is easier to follow. In some strange instances.

    It would be super duper amazingly fabulous if it was possible to optionally honor indentation, even though it is against the rules and the standard.

    /Tony

  4. Support Staff 4 Posted by Brett on 02 Sep, 2015 02:21 PM

    Brett's Avatar

    It can't be done with Markdown, sorry. Marked was built to be flexible,
    though, so it can be extended via custom processors and custom styles to
    fit edge cases like this.

    -Brett

  5. 5 Posted by Tony Helinsky on 02 Sep, 2015 02:40 PM

    Tony Helinsky's Avatar

    Got it :-)

    Thanks!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Already uploaded files

  • Screenshot-2015-08-31-kl.-08.11.34-Marked-2-tab-preview.png 207 KB

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

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