更改附录图编号

更改附录图编号

如何将附录中的图号从图 4.2 改为图 A.2?我不想给章节标题编号,也不想让附录编号显示在目录中。谢谢!

\documentclass{dissertation}

\begin{document}

\include{title/title}

\mainmatter
\include{Abstract/Abstract}
\include{Acknowledgements/Acknowledgements}
\tableofcontents
\thumbtrue
\include{Introduction/Introduction}
\include{Methods/Methods}
\include{Results/Results}
\include{Discussion/Discussion}
\printbibliography
\include{Appendix/Appendix}

%% Use letters for the chapter numbers of the appendices.
%\appendix

%% Turn off thumb indices for unnumbered chapters.
\thumbfalse

\end{document}

附录文件如下:

\chapter*{Appendix}
\addcontentsline{toc}{chapter}{Appendix}

\setheader{Appendix}

\section*{Appendix A}

\begin{figure}[h]
    \centering
    \includegraphics[width=0.75\textwidth]{images/FIGURE1.png}
    \caption{Figure one.}
    \label{fig:fig1}
\end{figure}

答案1

使用论文文档类来自这里您可以将标记为 的行添加%<-----到附录中。这会将附录中图像的编号更改为 A.1、A.2……但附录之前图像的编号保持不变。

\documentclass{dissertation}

\begin{document}

\tableofcontents

\chapter{first chapter}
\begin{figure}[h]
    \centering
    \includegraphics[width=0.75\textwidth]{example-image}
    \caption{Figure one.}
    \label{fig:fig1}
\end{figure}


\chapter*{Appendix}
\addcontentsline{toc}{chapter}{Appendix}
\setheader{Appendix}
\setcounter{figure}{0}                       % <---------------
\renewcommand\thefigure{A.\arabic{figure}}   % <---------------

\section*{Appendix A}

\begin{figure}[h]
    \centering
    \includegraphics[width=0.75\textwidth]{example-image}
    \caption{Figure one.}
    \label{fig:fig1}
\end{figure}

\end{document}

相关内容