如何更改图形标题中的文字大小和行间距?

如何更改图形标题中的文字大小和行间距?

我尝试改变文本大小和图形标题行之间的间隙,但没有效果。

我已经尝试过这些问题中人们给出的解决方案 如何调整同一子浮点数中的图形和标题之间的间隙

标题文字和标签大小仅为一个图形

但它们都对我不起作用。如果能提供一点帮助就太好了。

这是我正在使用的软件包的列表。

\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[a4paper,left=3.5cm,right=3.5cm,top=2.5cm]{geometry}
\renewcommand{\baselinestretch}{1.5} 
\renewcommand{\rmdefault}{phv} % Arial
\renewcommand{\sfdefault}{phv} % Arial
\usepackage{graphicx}
\usepackage{float}
\usepackage[demo]{graphicx}  
\usepackage[strict]{changepage}
\usepackage[justification=centering]{caption}
\usepackage[font=scriptsize]{caption}





\begin{figure}[H]
   \begin{adjustwidth}{-2cm}{-2cm}
\begin{minipage}[b]{0.49\linewidth}
   \includegraphics[width=\textwidth]{airmass_vs_ew_4854_87.pdf}
   \caption{\small The plot shows the difference of Equivalent width measured in two cases vs. Airmass. The red line shows the best linear fit.} 
\end{minipage}
\hfill
\begin{minipage}[b]{0.49\linewidth}
   \includegraphics[width=\textwidth]{airmass_vs_ew_by_ew4854_87.pdf}
   \caption{\small The plot shows ratio of the difference of Equivalent width  measured in two cases with Equivalent width measured using 2D blaze corrected spectra vs. Airmass. The red line shows the best linear fit.}
\end{minipage}
\end{adjustwidth}
\end{figure}

答案1

\documentclass[11pt]{article}
\usepackage[a4paper,left=3.5cm,right=3.5cm,top=2.5cm]{geometry}
\usepackage{setspace}
\setstretch{1.5} 
\renewcommand{\rmdefault}{phv} % Arial
\renewcommand{\sfdefault}{phv} % Arial
\usepackage{graphicx}
\usepackage{float}
\usepackage[strict]{changepage}
%\usepackage[justification=centering,font=scriptsize]{caption}




\begin{figure}[H]
   \begin{adjustwidth}{-2cm}{-2cm}
\begin{minipage}[b]{0.49\linewidth}
    \includegraphics[width=\textwidth]{example-image-a}
   \caption{\fontsize{8}{7}\selectfont The plot shows the difference of Equivalent width measured in two cases vs. Airmass. The red line shows the best linear fit.} 
\end{minipage}
\hfill
\begin{minipage}[b]{0.49\linewidth}
\includegraphics[width=\textwidth]{example-image-a}
  \caption{\fontsize{8}{7}\selectfont The plot shows ratio of the difference of Equivalent width  measured in two cases with Equivalent width measured using 2D blaze corrected spectra vs. Airmass. The red line shows the best linear fit.}
\end{minipage}
\end{adjustwidth}
\end{figure}


\end{document}

答案2

我建议使用floatrow略有不同的布局(在我看来,看起来更漂亮)。我还曾经setspace更改过 interlineskip,它与caption包配合使用,并helvetica用更完整的克隆替换TeX Gyre Heros

\documentclass[11pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[a4paper, hmargin=3.5cm, top=2.5cm]{geometry}
\usepackage{setspace}
\renewcommand{\rmdefault}{qhv} % TeX Gyre Heros (Helveticalclone)
\renewcommand{\sfdefault}{qhv} %
\usepackage[demo]{graphicx}
%\usepackage{float}
\usepackage[demo]{graphicx}
\usepackage[strict]{changepage}
\usepackage[justification=centering]{caption}
\usepackage[font=scriptsize]{caption}
\usepackage{floatrow}
\onehalfspacing

\begin{document}

  \begin{figure}
\captionsetup{font={footnotesize, singlespacing}, format=plain, justification=centerlast}
   \begin{adjustwidth}{-2cm}{-2cm}
\begin{floatrow}
\ffigbox
   {\includegraphics[width=0.49\linewidth]{airmass_vs_ew_4854_87.pdf}}{\caption{The plot shows the difference of Equivalent width measured in two cases vs. Airmass. The red line shows the best linear fit.}}

\ffigbox{\includegraphics[width=0.49\linewidth]{airmass_vs_ew_by_ew4854_87.pdf}}{\caption{The plot shows ratio of the difference of Equivalent width measured in two cases with Equivalent width measured using 2D blaze corrected spectra vs. Airmass. The red line shows the best linear fit.}}%
\end{floatrow}
\end{adjustwidth}
\end{figure}
Some text. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext. Some more ext.

\end{document}

在此处输入图片描述

相关内容