Conversion Toolshow to avoid pdfcrop from making unbalanced margins?

Information and discussion about output converters related to LaTeX (e.g. dvips, ps2pdf, ...)
Post Reply
latexian
Posts: 19
Joined: Wed Aug 05, 2009 7:57 am

how to avoid pdfcrop from making unbalanced margins?

Post by latexian »

Hello all,

I want to insert mathematics equations into my InDesign document.
To do that,

1. I create the equation in latex,
2. compile it to dvi using latex.exe,
3. convert it to ps using dvips.exe,
4. convert it to pdf using ps2pdf.exe,
5. trim the bounding margins using pdfcrop,
6. and finally import it from InDesign.


Here is my minimal code:

Code: Select all

\documentclass{minimal}
\usepackage{amsmath}
\begin{document}
\fbox{$\sin(a+b)=\sin a \cos b + \cos a \sin b$}%
\end{document}

And here is the corresponding output:
Image



My problem is:
Please see the figure above carefully.
Left margin width =/= right margin width.
Top margin width =/= bottom margin width.
how to avoid pdfcrop from making unbalanced margins?


Any suggestion is appreciated.

Thank you in advance.



regards,
LaTeXian

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
localghost
Site Moderator
Posts: 9201
Joined: Fri Feb 02, 2007 12:06 pm

how to avoid pdfcrop from making unbalanced margins?

Post by localghost »

Code: Select all

1. I create the equation in latex,      
2. compile it to dvi using latex.exe,       |
3. convert it to ps using dvips.exe,        |> replace with compilation by pdflatex
4. convert it to pdf using ps2pdf.exe,      |
5. trim the bounding margins using pdfcrop,
6. and finally import it from InDesign.
Set the margins to which the image shall be cropped manually.

Code: Select all

pdfcrop --help
You may have to test a little bit to find the right values.


Best regards
Thorsten
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes[/size]

¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
Post Reply