From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/23565 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Kopax Anderson Newsgroups: gmane.text.pandoc Subject: Converting from .docx to .pdf with pdflatex Date: Tue, 8 Oct 2019 15:19:39 -0700 (PDT) Message-ID: <67864477-398d-4310-804f-bd40e1b87908@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_3240_1128409191.1570573179856" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="243950"; mail-complaints-to="usenet@blaine.gmane.org" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBCJO5CHK4EJRBKP5QLWQKGQES2GNYHY-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Fri Oct 11 19:41:01 2019 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane.org Original-Received: from mail-ot1-f62.google.com ([209.85.210.62]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.89) (envelope-from ) id 1iIyuR-0011H4-L6 for gtp-pandoc-discuss@m.gmane.org; Fri, 11 Oct 2019 19:41:00 +0200 Original-Received: by mail-ot1-f62.google.com with SMTP id v51sf5262245otb.5 for ; Fri, 11 Oct 2019 10:40:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:date:from:to:message-id:subject:mime-version :x-original-sender:reply-to:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=w0JP0JMlaiEsYpBoUCIrLGWV595aVvvy2iQOlGdMdFY=; b=MICvP+9xpmDH/7ShfWYRniYSgYUtP4leHCLRjHamhEvh14+J0Z6hsIRX/jBe2lDWw6 2zZAc4gnSRbz8/WiapynRtWcYPg3oTp+IJ+72zxYbk8jLdTSfhUqhlCXcLceAUiKFSWY RWsXrFrE4B2Ngq2ohVJsBFhr3ed//1KramVuvk5cUZsnb33EwSrWzJpO+e1sMvvU9/gr JQf8ryAhXMUYtTvLuuY25hHNUdfRxv6jLbIDbLE459vkFNpRVTtJV+YuWGqY/7v2mFk9 v63uHmk14GUev5EgvyGIkr5dJ7s85+PfoFz75Phwc7RJiBtfqAVvj4+WJmfWJJPLjKRp MrfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:date:from:to:message-id:subject :mime-version:x-original-sender:reply-to:precedence:mailing-list :list-id:list-post:list-help:list-archive:list-subscribe :list-unsubscribe; bh=w0JP0JMlaiEsYpBoUCIrLGWV595aVvvy2iQOlGdMdFY=; b=sMcO/HXz6/+wYc8KdQ+qo8LTyOcUF116BDxZErf4nJOA2P3IUS/6w5hoQdfUokjCqG /sTOjFp2o4+78pJgGgOG2peKr3Qe7IcOYcCXWQtqEskmpbzK0pwoPq0OEJwvHwjD18wp CLaSDp3/qCbZM8lOHO1IID5Vqo2pnYpR5gvjybncQDftlJ0BSIXNAUJsPWpAs+i7NyJ5 K6IeH2EQjfpFAaQF2eEu7i6EyFWbRujN9tK+NFOhEw7x6lJPnvCzz0V+rDTqL5kG8hpZ al/h3L8XJI0rcizrHrB+zqKX+o1yyoF9CJXsB4hMVUtN7QJWe1nPsraSajb9LQrqzIVM aHWg== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: APjAAAWIJuDGjiCarQnGLg8qabNsVpZ1S0n8qInt9NPXLd89hnCkVFwe aCDFwbvQm+g0foFWMiJ0t40= X-Google-Smtp-Source: APXvYqyTRxboO8VyzRUrIjPeOD3ltnuV11Tv/Jw9PL6sVeO6hM50OSzq4lKQjgZeVXQhnEsvllDQ5g== X-Received: by 2002:a9d:6284:: with SMTP id x4mr4949539otk.281.1570815658314; Fri, 11 Oct 2019 10:40:58 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6830:1383:: with SMTP id d3ls1654616otq.0.gmail; Fri, 11 Oct 2019 10:40:57 -0700 (PDT) X-Received: by 2002:a05:6830:119a:: with SMTP id u26mr13831789otq.166.1570815657517; Fri, 11 Oct 2019 10:40:57 -0700 (PDT) Original-Received: by 2002:aca:ecc8:0:0:0:0:0 with SMTP id k191msoih; Tue, 8 Oct 2019 15:19:41 -0700 (PDT) X-Received: by 2002:aca:fc84:: with SMTP id a126mr5837718oii.65.1570573180603; Tue, 08 Oct 2019 15:19:40 -0700 (PDT) X-Original-Sender: d.kopriwa-Re5JQEeQqe8AvxtiuMwx3w@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.org gmane.text.pandoc:23565 Archived-At: ------=_Part_3240_1128409191.1570573179856 Content-Type: multipart/alternative; boundary="----=_Part_3241_120641128.1570573179858" ------=_Part_3241_120641128.1570573179858 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, I have tried two version of pandoc: - 1.7 - 2.7.3 Both time, I use *pdflatex* engine. My follow consist of: 1. Write a document on Google Doc 2. Generating the Table of Content on Google Doc 3. Downloading the file as `.docx` 4. Run pandoc and convert to pdf This is how my pandoc command look like: pandoc --output "WIP.pdf" --pdf-engine=3Dpdflatex --from docx --to latex --= number-sections --toc --toc-depth=3D2 -V documentclass=3Damsart "WIP.docx" I expect to have one single TOC, somebody give me a valid rendered file and= =20 it should look exactly like: - With pandoc 1.7, I can't produce the same result, the TOC title is on the= =20 down left corner. - With pandoc 2.7.3, I can't produce the same result, the TOC title is on= =20 the down left corner, and I still have the .docx table of content just=20 under the latex TOC. For instance, this is my Google Document: With pandoc 2.7.3, I run: pandoc --output "WIP.pdf" --pdf-engine=3Dpdflatex --from docx --to latex --= number-sections --toc --toc-depth=3D2 -V documentclass=3Damsart "WIP.docx" I have: [image: pdflatex] This is the .tex that is generated with pandoc 2.7.3: \begin{document} \maketitle { \setcounter{tocdepth}{2} \tableofcontents } \listoftables \LR{{\protect\hyperlink{ruxe9flexions-diverses}{R=C3=A9flexions d= iverses}\textbf{1}}} \begin{quote}\LR{{\protect\hyperlink{cas-pratique}{Cas pratique} 1}} \LR{{\protect\hyperlink{je-suis-un-oiseau}{Je suis un oiseau} 1}} \LR{\protect\hyperlink{je-suis-un-avion}{Je suis un avion} 1}\end{quote} \LR{} \LR{} \hypertarget{ruxe9flexions-diverses}{%\section{\texorpdfstring{\LR{R=C3=A9f= lexions diverses}}{R=C3=A9flexions diverses}}\label{ruxe9flexions-diverses}} \LR{Ceci est de la r=C3=A9flexion en tout sens.} \hypertarget{cas-pratique}{%\subsection{\texorpdfstring{\LR{Cas pratique}}{Cas pratique}}\label{cas-pratique}} \LR{Nous avons deux cas pratiques, oiseai et avion.} \LR{Il est utile de les d=C3=A9velopper.} \hypertarget{je-suis-un-oiseau}{%\subsubsection{\texorpdfstring{\LR{Je suis= un oiseau}}{Je suis un oiseau}}\label{je-suis-un-oiseau}} \LR{L'oiseau vol,} \LR{car il plane avec ses ailes.} \hypertarget{je-suis-un-avion}{%\subsubsection{\texorpdfstring{\LR{Je suis = un avion}}{Je suis un avion}}\label{je-suis-un-avion}} \LR{L'avion vol aussi,} \LR{car il plane avec ses ailes et =C3=A0 un moteur} \end{document} If I open the .docx, and I remove the TOC from the visible document, then I= =20 run again the command with Pandoc 2.7.3 I only get the first and valid one. I want to keep the TOC unique in both Google Doc and LaTeX PDF. 1. Is there a way to remove that second TOC? 2. Is there a way to place the title of the TOC in the middle center (as= =20 in my first screenshot, valid sample) --=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/67864477-398d-4310-804f-bd40e1b87908%40googlegroups.com. ------=_Part_3241_120641128.1570573179858 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

I have tried two version of pandoc:=

- 1.7
- 2.7.3

= Both time, I use pdflatex engine.

My follow= consist of:

  1. =C2=A0Write a document on Goo= gle Doc
  2. Generating the Table of Content on Google Doc
  3. Downl= oading the file as `.docx`
  4. Run pandoc and convert to pdf
<= div>This is how my pandoc command look like:

pandoc --output "WIP.pdf"=
; --pdf-engine=3Dpdflatex --from docx --to=
 latex --number-sections --toc --toc-depth=3D2 -V documentclass=3Damsart "WIP=
.docx"

I expect to have on= e single TOC, somebody give me a valid rendered file and it should look exa= ctly like:


- With pandoc 1.7, I can't produce the same r= esult, the TOC title is on the down left corner.
-=C2=A0With pandoc 2.7.3, I can= 't produce the same result, the TOC title is on the down left corner, a= nd I still have the .docx table of content just under the latex TOC.=

For instance, this is my Google Document:


With pandoc 2.7.3, I run:
=
pandoc --outp=
ut "WIP.pdf" --pdf-engine=3Dpd=
flatex --from docx --to latex --number-sections --toc --toc-depth=3D2 -V documentclass=3Damsart "WIP.docx"

I have:

3D"pdflatex"

This is the=C2=A0.tex=C2=A0that is generated with pandoc = 2.7.3:


\begin{document<=
span class=3D"pun" style=3D"font-style: inherit; font-variant: inherit; fon=
t-weight: inherit; font-stretch: inherit; line-height: inherit; font-family=
: inherit; vertical-align: baseline; box-sizing: inherit; color: rgb(159, 5=
7, 61);">}
        \maketitle

          {
    \setcounter{tocdepth<=
/span>}{2}
  \tableofcontents
  }
        \listoftables
          \LR{{\protect\=
hyperlink{ruxe9flexions-diverses}{R=C3=A9flexions diverses}<=
span class=3D"pln" style=3D"font-style: inherit; font-variant: inherit; fon=
t-weight: inherit; font-stretch: inherit; line-height: inherit; font-family=
: inherit; vertical-align: baseline; box-sizing: inherit; color: rgb(48, 51=
, 54);">
\textbf{1

\begin{quote}
\LR{{\protect\hyperlink<=
/span>{cas-pratique}{Cas pratique} 1}}

\LR{{\protect\hyperlink<=
/span>{je-suis-un-oiseau}{Je suis un oiseau} 1}}

\LR{\protect\hyperlink{je-suis-un-avion}{<=
span class=3D"pln" style=3D"font-style: inherit; font-variant: inherit; fon=
t-weight: inherit; font-stretch: inherit; line-height: inherit; font-family=
: inherit; vertical-align: baseline; box-sizing: inherit; color: rgb(48, 51=
, 54);">Je suis un avion} 1}
\end{quote

\LR{}

\LR{}

\hypertarget{ruxe9flexion=
s-diverses}{%
\section{\texorpdfstring=
{\LR{R=
=C3=A9flexions
diverses}}{R=C3=A9flexions diverses=
}}\label{ruxe9f=
lexions-diverses}}

\LR{Ceci est de la r=C3=
=A9flexion en tout sens.}

\hypertarget{cas-pratique=
}{%
\subsection{\texorpdfstr=
ing{\LR{}}{Cas pratique}=
}\label{cas-pratique}}

\LR{Nous avons deux cas p=
ratiques, oiseai et avion.}

\LR{Il est utile de les d=
=C3=A9velopper.}

\hypertarget{je-suis-un-o=
iseau}{%
\subsubsection{\texorpdf=
string{\LR{Je suis un
oiseau}}{Je suis un oiseau}}\label{je-suis-un-oise=
au}}

\LR{L'oiseau vol,}

\LR{car il plane avec ses=
 ailes.}

\hypertarget{je-suis-un-a=
vion}{%
\subsubsection{\texorpdf=
string{\LR{Je suis un
avion}}{Je suis un avion}=
}\label{je-suis-un-avion=
}}

\LR{L'avion vol aussi=
,}

\LR{car il plane avec ses=
 ailes et =C3=A0 un moteur}

        \end{document}


=

<= span style=3D"font-size: 15px;">If I open the .docx, and I remove the TOC f= rom the visible document, then I run again the command with Pandoc 2.7.3 I = only get the first and valid one.


I want to kee= p the TOC unique in both Google Doc and LaTeX PDF.


  1. Is there a way to remove that second TOC?
  2. Is there a way to place the title = of the TOC in the middle center (as in my first screenshot, valid sample)


=


--
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/67864477-398d-4310-804f-bd40e1b87908%40googlegroups.co= m.
------=_Part_3241_120641128.1570573179858-- ------=_Part_3240_1128409191.1570573179856--