请问,什么控制图片底部和副标题的分离?

请问,什么控制图片底部和副标题的分离?
\documentclass{book} %
\usepackage[verbose]{geometry}
\usepackage[a4,frame,center]{crop}
\usepackage[explicit]{titlesec} %
\usepackage{titletoc} %
\usepackage[nottoc]{tocbibind}
\usepackage[fleqn]{amsmath} %
\usepackage{amsthm,amssymb} %
\usepackage[table]{xcolor} % define colors, color table, order important
    \definecolor{DarkCream}{rgb}{1.00,1.00,0.85} % FFFFFB
    \definecolor{DarkRed}{rgb}{0.45,0.00,0.00} % #880000
\usepackage[margin=10pt,
            font=normalsize,
            labelfont=bf,
            labelsep=space,
            position=below]{caption} %
\usepackage[position=below,
            textfont=normal,
            labelfont=bf]{subfig} %
\usepackage{graphicx}
\usepackage{tcolorbox}
\usepackage{bookmark}
\usepackage{hyperref}
%
\setlength{\unitlength}{1mm} % 1mm=2.834646pt; 1pt=0.3515mm
%
\captionsetup[subfigure]{labelformat=parens}

\begin{document}
\begin{figure}[h]\center
    \begin{tcolorbox}[width=105.8mm,toptitle=12pt,colframe=DarkRed,colback=DarkCream,top=4.8pt,bottom=4.8pt, left=0pt, right=0pt,arc=2pt,boxsep=0pt,boxrule=1.0pt,bottomtitle=26pt]
    \centering
\arrayrulecolor{blue!50!black}\renewcommand{\arraystretch}{1.2}%
\begin{tabular}{@{}c@{\hspace{4.8pt}}c@{}}
    \includegraphics[width=50mm]{example-image-a}
&
    \includegraphics[width=50mm]{example-image-b} \\
\parbox{50mm}{\captionof{subfigure}{Inequality region \label{fig:inequalityregion}}}
&
\parbox{50mm}{\captionof{subfigure}{Proof of inequality \label{fig:inequalityproof}}}
\end{tabular}
    \end{tcolorbox}
\vspace{-4pt}
    \caption{Region satisfying the inequality}
\label{fig:twodiminequalityregion}
\end{figure}
    \end{document}

答案1

在您的例子中,子标题放在表格环境中,因此您需要控制连续行之间的距离。这很容易做到

\\[<value>]

如果值为正,则增加距离,相反,负值减少它。请参阅下面的代码片段:

\begin{figure}[h]\center
    \begin{tcolorbox}[width=105.8mm,toptitle=12pt,
                      colframe=DarkRed,colback=DarkCream,
                      top=4.8pt,bottom=4.8pt,left=0pt,right=0pt, arc=2pt,boxsep=0pt,boxrule=1.0pt,
                      bottomtitle=26pt]
    \centering
\arrayrulecolor{blue!50!black}\renewcommand{\arraystretch}{1.2}%
\begin{tabular}{@{}c@{\hspace{4.8pt}}c@{}}
    \includegraphics[width=50mm]{example-image-a}
&
    \includegraphics[width=50mm]{example-image-b} 
        \\[-1em]%<--- for control distance between 
                % images and sub-captions: for increasing 
                % use positive value, for decreasing negative
\parbox{50mm}{\captionof{subfigure}{Inequality region \label{fig:inequalityregion}}}
&
\parbox{50mm}{\captionof{subfigure}{Proof of inequality \label{fig:inequalityproof}}}
\end{tabular}
    \end{tcolorbox}
\vspace{-4pt}%<--- in normal circumstances this vertical distance 
             % managed globally by option "skip"
    \caption{Region satisfying the inequality}
\label{fig:twodiminequalityregion}
\end{figure}

对于选定的-1em你应该得到下图:

在此处输入图片描述

并且1em距离增加(很多):

在此处输入图片描述

编辑: 手动减少每个图中图像和标题之间的距离并不是解决此问题的正确方法。更好的方法是使用标题选项全局设置此距离skip,例如:

\usepackage[margin=10pt,
            font=normalsize,
            labelfont=bf,
            labelsep=space,
            position=below,
            skip=6pt]{caption} %

有关详细信息,请阅读第 13 页标题部分 2.6 跳过的文档。

相关内容