数字の後にコロンの代わりにピリオドを付けて太字の「表番号」を表示するにはどうすればよいでしょうか?

数字の後にコロンの代わりにピリオドを付けて太字の「表番号」を表示するにはどうすればよいでしょうか?

私のMWE:

\documentclass[12pt,twoside]{article} 
\usepackage{tabularx}
\begin{document}
\begin{table}[ht]
    \centering
    \caption{Results}
    \begin{tabularx}{14.36cm}{|c|c|c|c|c|c|}
        \hline
        Column  & c1 & c2 & c3 & c4 & c5 \\ 
        \hline
        r1 & 0 & 0 & 0 & 0 & 0 \\ 
        r2 & 0 & 0 & 0 & 0 & 0 \\ 
        \hline
    \end{tabularx}
\end{table}
\end{document}

出力には「表 1: 結果」という表の見出しが付けられます。

代わりに、私は「表1。結果"

答え1

私は次のようにパッケージを使用しますcaption:

\usepackage[labelfont=bf,labelsep=period]{caption}

\documentclass[12pt,twoside]{article} 
\usepackage{tabularx}
\usepackage[labelfont=bf,labelsep=period]{caption}
\begin{document}
\begin{table}[ht]
    \footnotesize
    \centering
    \caption{Results}
    \begin{tabularx}{14.36cm}{|c|c|c|c|c|c|}
        \hline
        Column  & c1 & c2 & c3 & c4 & c5 \\ 
        \hline
        r1 & 0 & 0 & 0 & 0 & 0 \\ 
        r2 & 0 & 0 & 0 & 0 & 0 \\ 
        \hline
    \end{tabularx}

\end{table}
\end{document}

降伏:

ここに画像の説明を入力してください


とにかく、@CarLaTeXが指摘したように、結果は醜いですが、 の使用が原因ではなくtabularx、主にテーブルが固定長でタイプセットされ、画面全体に収まるように右側に醜い列が生成されたためです。

私は、OP が投稿したものを少し変更して、より見栄えの良い表をタイプセットしたと思います。問題は解決したので、代替の解決策としてここに残しておきます。

基本的に、tabularxパッケージ (不要) とインクルードbooktabs(さまざまなルールのため) を削除しました。また、垂直セパレーター (印刷上見苦しい) を削除し、水平セパレーターを合理化しました。

また、追加データも含めました。表をより良くタイプセットするには、それらの列にタイプセットする内容についてもっと詳しく知る必要があると思いますが、それはこの回答で議論できるものではありません (少なくとも、議論することはできますが、トピック外です)。

私は OP に、(希望する場合)コードを試してみて、必要に応じて別の質問をすることをお勧めします。

コード:

\documentclass[12pt,twoside]{article} 
\usepackage[labelfont=bf,labelsep=period]{caption}
\usepackage{booktabs}
\begin{document}
\begin{table}
\centering
    \caption{Results}
    \begin{tabular}{cccccc}
        \toprule
        Column  & c1 & c2 & c3 & c4 & c5 \\ 
        \midrule
        r1 & 0 & 100 & 50 & text & 0 \\ 
        r2 & 0 & 0 & 0 & 0 & 0 \\ 
        \bottomrule
            \end{tabular}
\end{table}
\end{document}

結果:

ここに画像の説明を入力してください

関連情報