Notice that the same error is reproduced using the following text:
\documentclass{article}
\usepackage{xcolor}
\usepackage{multirow}
\setlength{\parindent}{0pt}
\newcommand{\vstrut}[3][blue]{{\color{#1}\rule[-#2]{0.4pt}{#3}}}
\newcommand{\hstrut}[2][blue]{{\color{#1}\makebox[0pt][l]{\rule[-0.4pt]{#2}{0.4pt}}}}
\begin{document}
\begin{tabular}{|lll|}
\hline
A\vstrut{0ex}{5ex} & \multirow{2}{3cm}{%
\begin{minipage}[t]{3cm}
Trial \vstrut[red]{18pt}{18pt} text
\end{minipage}}
& A \\
A\vstrut{3ex}{3ex}\hstrut{1.65in} & {} & A \\
A & A & A \\
\hline
\end{tabular}
\end{document}
\multirow
creates a \vtop
box whose height and depth are set according to the rules for \vtop
and the height and depth of \@arstrutbox
. Now, \@arstrutbox
is a box set up when a tabular environment is create. It is set to be a box whose height and depth are \arraystretch
times the height and depth of a normal strut.
By playing with the visible struts in the above example, you can see the effects of how \multirow
creates the box for its content. For example, even though you can place a strut to extend the size of the second row, this does not prevent an overfull box error when the strut inside the \multirow
command force the contents of the box created by \multirow
to be too big.
So, one solution would be to reset the value of \arraystretch
. But that seems a bit of overkill: you probably don't want to change the \arraystretch
of the whole table to fix just one box.
Keeping in mind how \multirow
creates its box means a couple of things. Consider this next example where I tell \multirow
that I only need one row.
\begin{tabular}{|lll|}
\hline
A\vstrut{0ex}{5ex} & \multirow{1}{3cm}{%
\begin{minipage}[t][0pt]{3cm}
Trial \vstrut[red]{18pt}{18pt} text
\end{minipage}}
& A \\
A\vstrut{3ex}{3ex}\hstrut{1.65in} & {} & A \\
A & A & A \\
\hline
\end{tabular}
You can completely forgo using \multirow
by creating a top aligning minipage
of zero height.
\begin{tabular}{|lll|}
\hline
A\vstrut{0ex}{5ex} &%
{\begin{minipage}[t][0pt]{3cm}
Trial \vstrut[red]{18pt}{18pt} text
\end{minipage}}
& A \\
A\vstrut{3ex}{3ex}\hstrut{1.65in} & {} & A \\
A & A & A \\
\hline
\end{tabular}
Avoiding \multirow
, you can still achieve something more like your original example, you can write:
\begin{tabular}{|lll|}
\hline
A &%
{\begin{minipage}[t][0pt]{3cm}
\begin{tabular}{|l|l|}
\hline
A & \hfill 1\textsuperscript{st} \\
\hline
A & A \\
\hline
\end{tabular}
\end{minipage}}
& A \\
A & {} & A \\
A & A & A \\
\hline
\end{tabular}
It seems the benefits of using \multirow
is the ability to center its content with respect to the other rows it's supposed to straddle (see edit toward the end of this answer). So, here's an example that comes closer to what you want. (I've added a \hrule
to better show the misalignment of the horizontal lines.)
\begin{tabular}{|lll|}
\hline
A &%
\multirow{2}{*}%
{\begin{minipage}[c][0pt]{3cm}%
\begin{tabular}[c]{|l|l|}
\hline
A & \hfill 1\textsuperscript{st} \\
\hline
A & A \\
\hline
\end{tabular}%
\end{minipage}}
& A \\\hline
A & {} & A \\
A & A & A \\
\hline
\end{tabular}
Remember that tabular
environments, much like minipage
s, can be centered with respect to the line they fall on.
To get the horizontal lines to align properly, add a vertical strut inside the minipage
as follows (in this example, I use \raisebox
to create a box of zero total height+depth):
\begin{tabular}{|lll|}
\hline
A &%
\multirow{2}{*}%
{\raisebox{0pt}[0pt][0pt]{\begin{minipage}{3cm}\vspace{0.5pt}%
\begin{tabular}[c]{|l|l|}
%\hline % commented-out from original code b/c it slightly struts out at the top
A & \hfill 1\textsuperscript{st} \\
\hline
A & A \\
\hline
\end{tabular}%
\end{minipage}}}
& A \\\hline
A & {} & A \\
A & A & A \\
\hline
\end{tabular}

One additional point, you've got some whitespace creeping into your document at the end of the lines. This is causing widths to not quite be what you're defining them to be. I've eliminated a number of the more egregious occurrences.
EDIT
As @SašoŽivanović has pointed out, \multirow
doesn't center its content. But what I'm talking about regarding centering is that \multirow
will essentially center the contents of a box whose total height and depth is zero. This is because the contents of the \vtop
used in the definition of \multirow
are bracketted between \vfill
s resulting in content that is centered with respect to the expected height generated by the rows to be spanned.
Whitespace
In your original post you called
A & \multirow{2}{*}{
\begin{minipage}{3cm}
\begin{tabular}{|l|l|}
\hline
A & \hfill 1\textsuperscript{st}\bigstrut[t] \\
\hline
A & A \\
\hline
\end{tabular}
\end{minipage}
}
This is adding extra space at the line beginning \multirow...
and it's adding extra space at the end when you write \end{minipage}
. Look at my examples where I avoid this through placing %
or closing arguments earlier than you do.
For more details on this, I suggest reading @egreg's answers posted to When is it harmful to add percent character at end of lines in a \newcommand, or similar
pdflatex
(pdfTeX, Version 3.1415926-2.4-1.40.13
) and get 0 errors, 0 warnings, and 1 bad box. My default is letter (not A4) where I am right now, but I'd be surprised if that mattered.\multirow
is not correctly determined. Test this out by using the packagelipsum
and then replace the contents of theminipage
environment with just\lipsum[1]
Warning:
, still they belong to that category I think ;)