I'm using the following code to show two tikzpictures in a line.
\documentclass[11pt]{article}
\usepackage{tikz}
\usepackage[labelformat=empty]{caption}
\begin{document}
\begin{center}
\begin{minipage}[b]{.5\textwidth}
\centering
\begin{tikzpicture}
\draw (0,2) -- (0,-2);
\end{tikzpicture}
\captionof{figure}{
A non-essential apartment\\
of type $A_1$.}
\end{minipage}%
\begin{minipage}[b]{.5\textwidth}
\centering
\begin{tikzpicture}
\foreach \x in {0,0.6,1.2,1.8}
\draw (\x,2)--(\x,-2) (2,\x)--(-2,\x) (-\x,2)--(-\x,-2) (2,-\x)--(-2,-\x);
\end{tikzpicture}
\captionof{figure}{
A non-irreducible apartment\\
of type $A_1\times A_1$.}
\end{minipage}
\end{center}
\end{document}
However, it shows as following
Why the second captionof is not centered?
Update: shorten the text in second captionof to show the problem more clear.