public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: Martin Hepp <mfhepp-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: missing figures in latex/pdf output
Date: Wed, 28 Sep 2022 03:11:49 +0200	[thread overview]
Message-ID: <1AF44C44-B3C7-4872-BA10-980739F20F72@gmail.com> (raw)
In-Reply-To: <D0DAD6A1-3B30-4F46-8FAB-5F484F65D700-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

In general, if you aim at multiple output formats, it’s best to use Markdown syntax / elements for the authoritative master document, and delegate required modifications to format-specific Pandoc filters (or writers, but less common).

There are quite some filters out there that try to translate HTML elements to TeX syntax (e.g. text color) and other formats, but this is typically second-best, in particular more difficult to implement in a robust way.

Except for tables, Markdown in the Pandoc flavor, is likely the best compromise for a output-format-agnostic representation of documents, in particular thanks to fenced divs support.

Best wishes
Martin

---------------------------------------
martin hepp
www:  https://www.heppnetz.de/


> On 27. Sep 2022, at 23:06, John MacFarlane <fiddlosopher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> 
> It’s not a bug.  Raw HTML is only passed through to formats that support it (e.g. Markdown, EPUB, and HTML).
> It isn’t parsed into a native Pandoc structure and then rerendered in the target format.
> 
>> On Sep 27, 2022, at 1:26 PM, Antonio Piccolboni <piccolbo-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>> 
>> Hi,
>> if one includes some graphics with the ![]() syntax, the graphics is present in the pdf output. But if one uses <figure>, no such luck. Both work with epub output. (I momentarily forgot why I am alternating between the two forms, I think I needed some extra control on image size). This is a minimal example. Markdown:
>> 
>> ```
>> ![Some image](assets/IBM650.jpg)
>> 
>> <figure>
>> <img src="assets/IBM650.jpg"></img>
>> <figcaption>Some image 2
>> </figcaption>
>> </figure>
>> ```
>> 
>> Tex output:
>> 
>> ```
>> \begin{figure}
>> \centering
>> \includegraphics{assets/IBM650.jpg}
>> \caption{Some image}
>> \end{figure}
>> 
>> Some image 2
>> ```
>> 
>> Of the second image, only the caption is left. Is this a bug or am I missing something? Thanks
>> 
>> 
>> 
>> Antonio
>> 
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
>> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/8bd75451-cad3-4a83-80e3-7a983091bcadn%40googlegroups.com.
> 
> -- 
> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/D0DAD6A1-3B30-4F46-8FAB-5F484F65D700%40gmail.com.

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/1AF44C44-B3C7-4872-BA10-980739F20F72%40gmail.com.


  parent reply	other threads:[~2022-09-28  1:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-27 20:26 Antonio Piccolboni
     [not found] ` <8bd75451-cad3-4a83-80e3-7a983091bcadn-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2022-09-27 21:06   ` John MacFarlane
     [not found]     ` <D0DAD6A1-3B30-4F46-8FAB-5F484F65D700-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2022-09-28  1:11       ` Martin Hepp [this message]
     [not found]         ` <1AF44C44-B3C7-4872-BA10-980739F20F72-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2022-09-28  3:41           ` Antonio Piccolboni
     [not found]             ` <c2b0c867-fb97-4aee-86f4-fcf160ff0303n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2022-09-28  6:04               ` John MacFarlane
     [not found]                 ` <ADAB9DB0-E0D5-4933-A83A-589C7EF14F61-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2022-09-28 15:48                   ` Antonio Piccolboni
     [not found]                     ` <C357174C-A074-4646-9149-B3102B6FAB8F-JxjfdnYl9jjeHsu01rjbxw@public.gmane.org>
2022-10-02 16:01                       ` 'Marek Stepanek' via pandoc-discuss

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=1AF44C44-B3C7-4872-BA10-980739F20F72@gmail.com \
    --to=mfhepp-re5jqeeqqe8avxtiumwx3w@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).