From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/32363 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Amy_de_Buitl=C3=A9ir?= Newsgroups: gmane.text.pandoc Subject: Re: Is there this option to convert to slide and document? Date: Mon, 20 Mar 2023 12:13:23 -0700 (PDT) Message-ID: <0f00a9f9-fd1a-4534-8152-3e810f22da2fn@googlegroups.com> References: Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_2708_67868054.1679339603248" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13533"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBDR454V73YMRBVHA4KQAMGQEC2NVFWQ-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mon Mar 20 20:13:28 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-oo1-f58.google.com ([209.85.161.58]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1peKwh-0003M2-LO for gtp-pandoc-discuss@m.gmane-mx.org; Mon, 20 Mar 2023 20:13:27 +0100 Original-Received: by mail-oo1-f58.google.com with SMTP id e3-20020a4ad243000000b00536a31d36e6sf3867967oos.9 for ; Mon, 20 Mar 2023 12:13:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; t=1679339606; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :sender:from:to:cc:subject:date:message-id:reply-to; bh=6FVltZOKetqDfq3eAFaJBg0Srqk31BF2k4ydVwP+Ons=; b=ZrYUhs0g3fL12vSzn7EUHBz3f6liEzBUNRJR4Gvl4l3Z0wfiRP/kaqvvmWhJ5pk2id Vvh0SSgFD5a0AYzbL5W8R21Q+CmfJqceMqNUpCzXp/to/5qghUcAjLjsGw2ws23h5gJg D2TpAp7ISOTjCczUynzDHDywXcrnvrL7C5lG80K8M2NZpuGLKfbKHTUuIIKgM/6hnMVG Tp31RaG9ZuyGMaRYutntMpUtiXA1t+ZQjtpRYJkb8Ba+T2fBRAXoFVniQF0XepbemIHv S0nP4rINBxjGL/fr2JqKLAuU2tuc18Gu/sEoeAO6zFHlsE0IqZVEwT2Rhbs1EeDDV8xn x/Tw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nualeargais-ie.20210112.gappssmtp.com; s=20210112; t=1679339606; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=6FVltZOKetqDfq3eAFaJBg0Srqk31BF2k4ydVwP+Ons=; b=tEUw7lb7OfrbfdPjSSJmnPraWtpeE3itO9M8dMrAhcwUuJAcXidguGUnNiurR32Yn5 80+gHvvTvGapNmBRylcDP5+ZBvHEhEvmIegupq3/jTCvjkn4cDo6sTd3eDbiKOFrp8PY T1I+sYcIAHEUQ2K8OWhHZAyOgp3jrg7mcGY37NjQIbYkKRQEasakmv3xDZLeIIoNXTa4 i1y2s+qN1xnR3vG/dXsUzjkxXkOkzXhyNIw2HcjzVWsntUvlb1HukS8UoOhCxHODDqW4 EIJ6EWHhLCZ4mTwhDh6a63LtpTOeHUggIzCZIovrYIfnd46o+GYuo/n74RvV+9WtBy1Q Ga1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679339606; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-gm-message-state:sender:from:to:cc :subject:date:message-id:reply-to; bh=6FVltZOKetqDfq3eAFaJBg0Srqk31BF2k4ydVwP+Ons=; b=Cp9IEotxF3HZu/ae7S54Mw3d6WCcfv5iTfHCIapUs09X7GVjOTMZ83L98DcteFeoMS 2lOcFLefrbTQuWxhejndUGZDQiRwzli56y5CQs2lWiotqQWKKN/Qjkwru1Ip354BpIb8 VGBSi7RidN68zTWFbZLEYHEJprxJJaSeGmD/IdOQ2XQQgwsoIY59bF6740qZjPtUSoUK J4AQR98a5UlYz2E8pAjuoQ9ZWira/lsbUaSMRJJ4ZucZUliY17v+Mmdwnapz5aOPMrEC FwcEhTHJxNVpcmSMAWCQSY5S8zhcUfWrQtjDQK8o1kgVj2YywPBPFq0mLAxL8sYw/OTw Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AO0yUKUgk4yglkrcAO58X41HCuX29zCgNdL3P9ffUrmc1u6VFLSpZWPl wL4xSFKWKwP7VAvLZpV0bsA= X-Google-Smtp-Source: AK7set/Ty66UGJnIHODNOxC+1Y6aUHO2XHPo5xeEPR/lmV0CAsh/ah6F4efZtf66WgcsEyQIreeo6Q== X-Received: by 2002:a05:6808:3c6:b0:386:b836:2ace with SMTP id o6-20020a05680803c600b00386b8362acemr355457oie.9.1679339606357; Mon, 20 Mar 2023 12:13:26 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6870:2806:b0:17a:da3c:65bb with SMTP id gz6-20020a056870280600b0017ada3c65bbls4700204oab.7.-pod-prod-gmail; Mon, 20 Mar 2023 12:13:24 -0700 (PDT) X-Received: by 2002:a05:6871:4e0b:b0:177:7c7a:fcdb with SMTP id ui11-20020a0568714e0b00b001777c7afcdbmr2889495oab.1.1679339603844; Mon, 20 Mar 2023 12:13:23 -0700 (PDT) In-Reply-To: X-Original-Sender: amy-x92Y4IBCQKU6Cx7ujrKbww@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:32363 Archived-At: ------=_Part_2708_67868054.1679339603248 Content-Type: multipart/alternative; boundary="----=_Part_2709_663882329.1679339603248" ------=_Part_2709_663882329.1679339603248 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable One idea that might help, would be to put any conditional output in a div= =20 or span, and assign it a special class, e.g. "pdf-only". Then all you need is a pandoc filter that removes all divs or spans with=20 that class. That would be a generic filter that I think a lot of people=20 could find a use for, and it's just a few lines of code. On Monday, 20 March 2023 at 16:49:41 UTC Julien Dutant wrote: > If I understand well, the idea is to convert the following into two=20 > different outputs, depending on whether the output format is revealjs/ppt= x=20 > vs pdf? > =20 > ``` markdown > =20 > Text text !!important claim here!! text text text text text > text text text text text text text text text text > text text text text text > =20 > * Point 1 text text text text > * Point 2 text text text text > =20 > ``` > =20 > Would remain the same in pdf (or other document format) output, except=20 > that the `!! ... !!` content would be highlighted, while in slide output= =20 > formats it would be converted to the following: > =20 > Would be converted to the following in slide ouputs: > =20 > ``` markdown > important claim here > =20 > * Point 1 text text text text > * Point 2 text text text text > =20 > ::: notes > Text text important claim here text text text text text > text text text text text text text text text text > text text text text text > ::: > ``` > =20 > You'd have to write a Pandoc filter to do that (=20 > https://pandoc.org/lua-filters.html ). It would make your work easier to= =20 > use Span and Div markup rather than !! ... !!: > =20 > Text text [important claim here]{.imp} text text text text text > text text text text text text text text text text > text text text text text > =20 > For the document, there's only highlighting to be done, that's fairly=20 > easy. For the slides, you need some restructuring of content, that's less= =20 > trivial (replace the paragraphs with their important bits, saving the=20 > paragraphs along, and placing them at the end of the slide in a notes Div= )=20 > but it can be done. > =20 > What's not clear to me is whether many people would use it. It seems=20 > pretty rigid: keep all the lists, remove all the paragraphs unless marked= ,=20 > the slide text must be verbatim in the document text (instead of=20 > summarizing it, for instance. > =20 > Best,=20 > > Julien > > On Monday, March 20, 2023 at 1:08:28=E2=80=AFPM UTC Amy de Buitl=C3=A9ir = wrote: > >> Pandoc supports speaker's notes, if that's what you're looking for. See= =20 >> https://pandoc.org/MANUAL.html#speaker-notes >> >> On Sunday, 19 March 2023 at 13:19:57 UTC Aldo =E2=80=9CScias=E2=80=9D wr= ote: >> >>> =C2=BFExiste esta opci=C3=B3n para convertir a diapositiva y documento? >>> >>> *Markdown with markup for relevant parts within a paragraph. !!Text!!* >>> Markdown con marcado para partes relevantes dentro de un p=C3=A1rrafo.= =20 >>> !!Texto!! >>> [image: import.png] >>> >>> Slide with the important parts and the containing paragraph as speaker= =20 >>> notes. >>> Diapositiva con las partes importantes y el p=C3=A1rrafo contenedor com= o=20 >>> notas del orador.[image: presentation.png] >>> Text document with the document and the important parts without=20 >>> modifications. >>> Documento de texto con el documento y las partes importantes sin=20 >>> modificaciones. >>> [image: document.png] >>> Benefit: >>> One markdown for two documents. >>> Another option is to create options to convert the entire document or= =20 >>> for the summary or important parts of the content. >>> >>> Beneficio: >>> Un markdown para dos documentos. >>> Otra opcion es crear opciones para convertir el documento entero o para= =20 >>> el resumen o partes importantes del contenido.=20 >>> >>> --=20 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 e= mail 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/0f00a9f9-fd1a-4534-8152-3e810f22da2fn%40googlegroups.com. ------=_Part_2709_663882329.1679339603248 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
One idea that might help, would be to put any conditional output in a = div or span, and assign it a special class, e.g. "pdf-only".

Then all you need is a pandoc filter that removes all di= vs or spans with that class. That would be a generic filter that I think a = lot of people could find a use for, and it's just a few lines of code.

On Monday, 20 March 2023 at 16:49:41 UTC Julien Dutant wrote:
If I understand well, = the idea is to convert the following into two different outputs, depending = on whether the output format is revealjs/pptx vs pdf?
=C2=A0
``` mark= down
=C2=A0
Text text !!important claim here!! text text text text te= xt
text text text text text text text text text text
text text text t= ext text
=C2=A0
* Point 1 text text text text
* Point 2 text text = text text
=C2=A0
```
=C2=A0
Would remain the same in pdf (or ot= her document format) output, except that the `!! ... !!` content would be h= ighlighted, while in slide output formats it would be converted to the foll= owing:
=C2=A0
Would be converted to the following in slide ouputs:=C2=A0
``` markdown
important claim here
=C2=A0
* Point 1 text= text text text
* Point 2 text text text text
=C2=A0
::: notes
= Text text important claim here text text text text text
text text text t= ext text text text text text text
text text text text text
:::
```=
=C2=A0
You'd have to write a Pandoc filter to do that ( https://pandoc.org/lua-filters.h= tml ). It would make your work easier to use Span and Div markup rather= than !! ... !!:
=C2=A0
Text text [important claim here]{.imp} text t= ext text text text
text text text text text text text text text text
= text text text text text
=C2=A0
For the document, there's only hi= ghlighting to be done, that's fairly easy. For the slides, you need som= e restructuring of content, that's less trivial (replace the paragraphs= with their important bits, saving the paragraphs along, and placing them a= t the end of the slide in a notes Div) but it can be done.
=C2=A0
Wha= t's not clear to me is whether many people would use it. It seems prett= y rigid: keep all the lists, remove all the paragraphs unless marked, the s= lide text must be verbatim in the document text (instead of summarizing it,= for instance.
=C2=A0
Best,

Julien=

On Monday, March 20, 2023 at 1:08:28=E2=80=AFPM UTC Amy de Buitl=C3=A9= ir wrote:
Pandoc suppo= rts speaker's notes, if that's what you're looking for. See https://= pandoc.org/MANUAL.html#speaker-notes

=
On Sunday, 19 March 2023 at 13:19:57= UTC Aldo =E2=80=9CScias=E2=80=9D wrote:
=C2=BFExiste esta opci=C3=B3n para convertir a diapositi= va y documento?

Markdown w= ith markup for relevant parts within a paragraph. !!Text!!
Ma= rkdown con marcado para partes relevantes dentro de un p=C3=A1rrafo. !!Text= o!!
3D"impor=

Slide with the important parts and the cont= aining paragraph as speaker notes.
Diapositiva con las partes= importantes y el p=C3=A1rrafo contenedor como notas del orador.3D=
Text document with the document and the= important parts without modifications.
Documento de texto co= n el documento y las partes importantes sin modificaciones.
<= img alt=3D"document.png" width=3D"390px" height=3D"295px" src=3D"https://gr= oups.google.com/group/pandoc-discuss/attach/1b8779246c07a/document.png?part= =3D0.1&view=3D1">
Benefit:
One markdown fo= r two documents.
Another option is to create options to convert the enti= re document or for the summary or important parts of the content.
=

Beneficio:
Un markdown para dos documentos.
Otra = opcion es crear opciones para convertir el documento entero o para el resum= en o partes importantes del contenido.=C2=A0

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/0f00a9f9-fd1a-4534-8152-3e810f22da2fn%40googlegroups.= com.
------=_Part_2709_663882329.1679339603248-- ------=_Part_2708_67868054.1679339603248--