* Convert Plain Element to Latex Code in LUA Filter
@ 2023-01-31 12:51 Frank Wisniewski
[not found] ` <76501da2-0d17-4aaa-9dfd-c236abd93de8n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Frank Wisniewski @ 2023-01-31 12:51 UTC (permalink / raw)
To: pandoc-discuss
[-- Attachment #1.1: Type: text/plain, Size: 666 bytes --]
I have the following Plain Element fron caption
Plain [Strong [Emph [Str "A"]],Str "dre",Emph [Str "ssen"],Space,Str
"Sa",Strong [Str "mm"],Str "lung"]
i would convert this to Latex Code:
'{\textbf{\emph{A}}dre\emph{ssen}'
Is there a function for this?
--
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/76501da2-0d17-4aaa-9dfd-c236abd93de8n%40googlegroups.com.
[-- Attachment #1.2: Type: text/html, Size: 997 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Convert Plain Element to Latex Code in LUA Filter
[not found] ` <76501da2-0d17-4aaa-9dfd-c236abd93de8n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2023-01-31 14:06 ` Bastien DUMONT
2023-02-01 7:12 ` Frank Wisniewski
0 siblings, 1 reply; 3+ messages in thread
From: Bastien DUMONT @ 2023-01-31 14:06 UTC (permalink / raw)
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw
Doesn't Pandoc do the conversion? What do you want, what do you do and what do you get?
Le Tuesday 31 January 2023 à 04:51:01AM, Frank Wisniewski a écrit :
> I have the following Plain Element fron caption
> Plain [Strong [Emph [Str "A"]],Str "dre",Emph [Str "ssen"],Space,Str
> "Sa",Strong [Str "mm"],Str "lung"]
> i would convert this to Latex Code:
> '{\textbf{\emph{A}}dre\emph{ssen}'
>
> Is there a function for this?
>
> --
> 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/76501da2-0d17-4aaa-9dfd-c236abd93de8n%40googlegroups.com.
>
> References:
>
> [1] mailto:pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> [2] https://groups.google.com/d/msgid/pandoc-discuss/76501da2-0d17-4aaa-9dfd-c236abd93de8n%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/Y9kgd69R5X9ac7Mc%40localhost.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Convert Plain Element to Latex Code in LUA Filter
2023-01-31 14:06 ` Bastien DUMONT
@ 2023-02-01 7:12 ` Frank Wisniewski
0 siblings, 0 replies; 3+ messages in thread
From: Frank Wisniewski @ 2023-02-01 7:12 UTC (permalink / raw)
To: pandoc-discuss
[-- Attachment #1.1: Type: text/plain, Size: 2843 bytes --]
I don't want to use longtabular, so I need to translate the table element
to plain latex to create a PDF.
Examples:
Before Filter
[CODE]
\begin{longtable}[]{@{}ll@{}}
\caption{\textbf{Adress}}\tabularnewline
\toprule\noalign{}
\textbf{Name} & \textbf{City} \\
\midrule\noalign{}
\endfirsthead
\toprule\noalign{}
\textbf{Name} & \textbf{City} \\
\midrule\noalign{}
\endhead
\bottomrule\noalign{}
\endlastfoot
NameOne & Bonn \\
NameTwo & Munich \\
NameThre & Cologne \\
\end{longtable}
[/CODE]
After LUA Filter
[CODE]
\begin{longtblr}[
theme=captionlinksbuendig,
caption = \textbf{Adress},
]{
colspec = {X[l]X[l]},
width = 1\linewidth,
rowhead = 1,
rowfoot = 0,
row{odd} = {shadecolor},
row{1} = {white},
}
\hline
\textbf{Name} & \textbf{City}\\
\hline
NameOne & Bonn\\
NameTwo & Munich\\
NameThre & Cologne\\
\hline
\end{longtblr}
[/CODE]
The captions are passed as inline elements which I have to convert to the
appropriate latex format.
EXAMPLE
[CODE]
Plain [Strong [Emph [Str "A"]],Str "dre",Emph [Str "ssen"]]
[/CODE]
must be convert to the Plain latex Code
[CODE]
\textbf{\emph{A....
[/CODE]
Bastien Dumont schrieb am Dienstag, 31. Januar 2023 um 15:06:56 UTC+1:
> Doesn't Pandoc do the conversion? What do you want, what do you do and
> what do you get?
>
> Le Tuesday 31 January 2023 à 04:51:01AM, Frank Wisniewski a écrit :
> > I have the following Plain Element fron caption
> > Plain [Strong [Emph [Str "A"]],Str "dre",Emph [Str "ssen"],Space,Str
> > "Sa",Strong [Str "mm"],Str "lung"]
> > i would convert this to Latex Code:
> > '{\textbf{\emph{A}}dre\emph{ssen}'
> >
> > Is there a function for this?
> >
> > --
> > 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-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> > To view this discussion on the web visit [2]
> https://groups.google.com/d/msgid/
> > pandoc-discuss/76501da2-0d17-4aaa-9dfd-c236abd93de8n%40googlegroups.com.
> >
> > References:
> >
> > [1] mailto:pandoc-discus...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> > [2]
> https://groups.google.com/d/msgid/pandoc-discuss/76501da2-0d17-4aaa-9dfd-c236abd93de8n%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/9c6c56a7-4b45-4d8f-8152-c85822932b6cn%40googlegroups.com.
[-- Attachment #1.2: Type: text/html, Size: 4820 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-02-01 7:12 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-31 12:51 Convert Plain Element to Latex Code in LUA Filter Frank Wisniewski
[not found] ` <76501da2-0d17-4aaa-9dfd-c236abd93de8n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-01-31 14:06 ` Bastien DUMONT
2023-02-01 7:12 ` Frank Wisniewski
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).