Have an account? Sign in
"*" indicates required fields
You agree that CreativePro Network may send you emails, including the newsletter selections above. You can unsubscribe at any time.
By signing in, you agree to our Terms of Use and acknowledge our Privacy Notice.
New user? Create an account
By signing in, you agree to our Terms of Use and acknowledge our Privacy Notice.
Over the years I used MathType to export the equations from Word as eps and import them in indesign with the help of a script to get the correct vertical alignment.
Recently I had to make two math books and I decided to implement a custom solution with open source software. It involves many steps but it works. For this solutions, Word equations must be made with the Word equations editors newer than version 3.
First I converted the word document to html via Pandoc with mathjax option (yes, it sounds weird). What you get is a text file with all the equations in LaTeX. Then convert this to .rtf (again via Pandoc) and place that file in indesign.
The second step involves a custom script that search with GREP for the equations delimiters \( \) or \[ \] and creates for each one a .tex file replacing the equation text in indesign with a marker text (example: <<eqn001.pdf>>; <<eqn002.pdf>>; etc.).
Now it’s time to process all the .tex files with a LaTeX compiler and get the equations rendered as pdf files. At this point it’s important to get the baseline shift displacement so when the pdf file is placed in indesign align correct within the text leading. As a quick but no elegant solution I made the .tex file wrote this value into the pdf “author” metadata.
With all the equations converted to pdf, it’s time to place them in indesign via another scripts that looks for every text marker <<eqn###.pdf>> and replace it with the pdf file of the same name. The vertical shift is applied to the anchored pdf file so it gets the correct vertical alignment.
And that it’s. It implies a lot of work, many tests with diferents LaTeX preambles and packages to get the desired result but it works for me.
Hope this serves as a starting point for anyone who wants to make a custom solution.
This site uses cookies, but not the kind you eat. We use cookies to remember log in details, provide secure log in, improve site functionality, and deliver personalized content. By continuing to browse the site, you accept cookies.