The output of the following code is affected whether calc package is included or not:
\documentclass{article}
\usepackage{tabularx}
% \usepackage{calc}
\newsavebox{\testbox}
\newlength{\testlen}
\newcommand{\boxx}[1]{%
\savebox{\testbox}{#1}%
\ifdim\wd\testbox>\testlen \global\setlength{\testlen}{\wd\testbox}\fi
\parbox{\testlen}{#1}}%
\begin{document}
\begin{tabularx}{10cm}{|c|X|c|}
col 1 & col 2 & col 3 \\
\boxx{\mbox{}\hfill aaaaaaa\hfill\mbox{}} & xxxxxxxxxxxxx \par testlen value: \the\testlen & \boxx{bbbbbbbbbb} \\
\boxx{\mbox{}\hfill 50\hfill\mbox{}} & yyyyyyyyyyyy & \boxx{A\hfill1} \\
90 & zzzzzzzzz & B\hfill2
\end{tabularx}
\end{document}
I'm taking advantage of the three pass of tabularx to determine which cell has the widest text to set a global length with this value. On the second pass all cells will have a parbox using this length.
Without calc, everything works as expected. With calc the length is not globalized and has no effect opening parboxes on other cells.
What to do? I need calc.
The application of all this is 1. I'm solving this situation.
calc? – Mar 03 '16 at 17:43pboxpackage, which relies oncalcpackage. I'm the author of that class (factura). Also I do some artithmetic on lengths based oncalc, but the most important is thepboxpackage. – Emilio Lazo Mar 03 '16 at 17:55etexwhich is nowadays part of every tex engine it is easier to use\dimexprand\numexpr– Mar 03 '16 at 18:25