public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: bruno.grenet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: Apply filter to beamer blocks
Date: Mon, 13 Mar 2023 13:00:01 +0100	[thread overview]
Message-ID: <22f6d608-baef-aa60-6fea-e3fb2d44d0c8@gmail.com> (raw)
In-Reply-To: <ZAsN61oTsAgxb3t2@localhost>

Thanks for your reply. Ideally, I'd like something which is not based on the command line options, but that's already a working solution.

Best,
Bruno

On 10/03/2023 12:00, Bastien DUMONT <bastien.dumont-VwIFZPTo/vqsTnJN9+BGXg@public.gmane.org> wrote:
> If you set the --slide-level option on the command line, you will be able to match the headers that are below this level, i.e. those that will be rendered as block headings. Example below:
> 
> ```
> BLOCK_LEVEL = PANDOC_WRITER_OPTIONS.slide_level - 1
> 
> function Header(header)
>    if header.level >= BLOCK_LEVEL then
>      print('**********\nIt works!\n**********\n')
>    end
> end
> ```
> 
> 
> Le Friday 10 March 2023 à 02:24:31AM, Bruno Grenet a écrit :
> > Dear all,
> >
> > My question is a rewrite of a previous question of mine (https://
> > groups.google.com/g/pandoc-discuss/c/wg3UIgI7G8I/m/V8GoGf9ACwAJ), with less
> > convoluted explanation.
> >
> > For conversion from markdown to beamer, is there a(n easy...) way to define a
> > lua filter that applies to headers that will become beamer blocks?
> >
> > The goal is to be able for instance to add classes and attributes to the header
> > becoming beamer blocks to control the display. A few examples include things
> > like "width = XX%", or ".centered" for the inside text to be centered, etc. Of
> > course, there are other ways to achieve such results, but the source file
> > become kind of ugly.
> >
> >
> > --
> > 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 [1]pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> > To view this discussion on the web visit [2]https://groups.google.com/d/msgid/
> > pandoc-discuss/e9bfa616-059a-4df7-9d92-d462ea6f3ed0n%40googlegroups.com.
> >
> > References:
> >
> > [1] mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> > [2] https://groups.google.com/d/msgid/pandoc-discuss/e9bfa616-059a-4df7-9d92-d462ea6f3ed0n%40googlegroups.com?utm_medium=email&utm_source=footer
> 
> 

-- 
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/22f6d608-baef-aa60-6fea-e3fb2d44d0c8%40gmail.com.


  reply	other threads:[~2023-03-13 12:00 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-10 10:24 Bruno Grenet
     [not found] ` <e9bfa616-059a-4df7-9d92-d462ea6f3ed0n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-03-10 11:00   ` Bastien DUMONT
2023-03-13 12:00     ` bruno.grenet-Re5JQEeQqe8AvxtiuMwx3w [this message]
     [not found]       ` <22f6d608-baef-aa60-6fea-e3fb2d44d0c8-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2023-03-13 13:01         ` Albert Krewinkel
     [not found]           ` <87cz5c7qfj.fsf-9EawChwDxG8hFhg+JK9F0w@public.gmane.org>
2023-03-13 13:06             ` bruno.grenet-Re5JQEeQqe8AvxtiuMwx3w

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=22f6d608-baef-aa60-6fea-e3fb2d44d0c8@gmail.com \
    --to=bruno.grenet-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).