public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: Albert Krewinkel <albert+pandoc-9EawChwDxG8hFhg+JK9F0w@public.gmane.org>
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: unwanted image captions
Date: Sat, 23 Sep 2017 18:38:36 +0200	[thread overview]
Message-ID: <87k20pcqur.fsf@zeitkraut.de> (raw)
In-Reply-To: <20170923162044.aoj7ciyfuidd7d4u-Ef207QMqB4M@public.gmane.org> (Clint Adams's message of "Sat, 23 Sep 2017 16:20:44 +0000")

Clint Adams <clint-8fiUuRrzOP0dnm+yROfE0A@public.gmane.org> writes:

> Text::Markdown will render
>
>     ![some text](https://example.org/img/onetwothree.jpg)
>
> to
>
>     <p><img src="https://example.org/img/onetwothree.jpg" alt="some text" /></p>
>
> This is what I want and expect.
>
> However, when transforming markdown to HTML with pandoc, the following
> is produced:
>
>     <div class="figure">
>     <img src="https://example.org/img/onetwothree.jpg" alt="some text" />
>     <p class="caption">some text</p>
>     </div>
>
> Is there a way to render the alt text but not a caption?  A quick look
> at the source code suggests that there is not.

Pandoc has an 'implicit_figures' extension which will treat paragraphs
containing just an image as figures. This feature can be turned off by
calling pandoc like this:

    pandoc -f markdown-implicit_figures -t html your-file.md

Does this solve your issue?


  parent reply	other threads:[~2017-09-23 16:38 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-09-23 16:20 Clint Adams
     [not found] ` <20170923162044.aoj7ciyfuidd7d4u-Ef207QMqB4M@public.gmane.org>
2017-09-23 16:38   ` Albert Krewinkel [this message]
     [not found]     ` <87k20pcqur.fsf-9EawChwDxG8hFhg+JK9F0w@public.gmane.org>
2017-09-23 17:33       ` Clint Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k20pcqur.fsf@zeitkraut.de \
    --to=albert+pandoc-9eawchwdxg8hfhg+jk9f0w@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).