I cannot make my table caption centered (it keeps staying on the left side) in a two-column manuscript. Here is the code I am using:
\documentclass[twocolumn]{autart}
\usepackage{graphicx}
\usepackage[utf8]{inputenc}
\usepackage{amsmath}
\usepackage[justification=centering]{caption}
\begin{document}
\begin{table}
\centering
\caption{Nomenclature used in the model.}
\label{nomenclature}
\vskip\baselineskip % Leave a vertical skip below the figure
\begin{tabular}{|cc|}
\hline
Col 1 & Col 2 \\
\hline
1 & 4 \\
2 & 5 \\
3 & 6 \\
\hline
\end{tabular}
\end{table}
\end{document}
Can someone help me fix this?
Best Answer
The following code is copied from the
autart.cls
file.This typesets the caption in a box over the complete horizontal space. Therefore
\centering
has no effect for your caption.You could change the code of the
autart.cls
file, but I would not recommend doing this, since the current style is probably required.If you insist doing this, you could add the following to your preamble.
The code is copied from
@makefigurecaption
. The caption will be centered if it fits on one line, otherwise it will be a justified paragraph. See the examples I provided.