Latex turn word

https://blog.csdn.net/ecnu18918079120/article/details/80322782

step:

1 Installation:

pandoc (http://pandoc.org/)

2 before conversion tex Note:

image:

Pictures and .tex files in the same folder, do not use \ graphicspath {{./pic/}} command in the sub-folders;
pictures before converting in \ includegraphics {0pic1} need to make up the suffix \ includegraphics command { 0pic1.png}
Another solution is added --default-image-extension = .png converted in the command
reference:

Reference .tex placed similarly to the same folder, followed by attention to add --bibliography = biblio.bib Compiled

pandoc -s document.tex -o document.doc --bibliography=biblio.bib
-s document.tex -o document.doc --bibliography=biblio.bib
Mathematical formula:

Remove \ notag option,
remove \ rm with \ text instead of the
conversion formula is missing the past number of reference solutions (test failure)
https://tex.stackexchange.com/questions/111868/pandoc-how-can-i-get -numbered-latex-equations-to- show-up-in-both-pdf-and-html-o

3 Conversion

Note tex files use notepad / sublime converted to utf-8 encoding, otherwise the following error occurs
pandoc: Cannot decode byte '\xa1': Data.Text.Internal.Encoding.decodeUtf8: Invalid UTF-8 stream

Open windows following powershell, go directly to the files they need to turn the latex directory, execute the following statement

pandoc -s bare_jrnl.tex -o a.docx --bibliography=biblio.bib -s bare_jrnl.tex -o a.docx --bibliography=biblio.bib

-s tex1207_utf8.tex -o 1207utf8.docx --bibliography=tsc2.bib --filter pandoc-eqnos```
Published 36 original articles · won praise 0 · views 20000 +

Guess you like

Origin blog.csdn.net/weixin_38102912/article/details/85291231