1

I would like the figures in this document to simply be numbered as "Figure 1", "Figure 2" etc. Right now, they are numbered as "Figure 0.1", "Figure 0.2" etc, which I assume has got something to do with the fact that this document does not contain chapters. However, I can't find the setting within my template that defines the numbering.

How do I change the figure numbers?

\RequirePackage{fix-cm}
\documentclass[%
    twoside, openright, titlepage, numbers=noenddot,%
    cleardoublepage=empty,%
    abstractoff,%
    BCOR=5.5mm, paper=a5, fontsize=10pt,% A5 soft cover
]{scrreprt}
\usepackage{etex}
\reserveinserts{10}

\usepackage[final]{pdfpages}

\begin{document} \frenchspacing \raggedbottom%

\begin{figure}[t] \centering \resizebox{0.4\linewidth}{!}{% \input{test.tex} } \caption{\textbf{Title}. Content.} \end{figure}

\begin{figure}[t] \centering \resizebox{0.4\linewidth}{!}{% \input{test.tex} } \caption{\textbf{Title}. Content.} \end{figure}

\end{document}

Nereus
  • 283

3 Answers3

1

It depends on the type of document. You can type article, and the enumeration will come out as you want.

  • 2
    As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers in the help center. – Community May 20 '23 at 23:04
1
  • You should make your MWE (Minimal Working Example) compilable ... we haven't your files, consequently in my MWE I use example image, which are available to anyone.
  • It is not clear, what is structure of your document, Is it divided on chapters and you have some images before first chapter, where you like to have figure numbering as you ask?
  • Document classes report and book default numbering is <chapter num>.<figure num>. This deliberately select for simpler navigate where are some image in document.
  • That numberoin start with 0 means, that you image are before \chapter{ chapter title}
  • If you not like to have chapters, than please use ˙articleor in your casescrarticle` document class. Using them figure numbering will be as you like to have
  • In the case, that you like to have chapters in your document, and like change default numbering of figures, just redefine \thefigure. For example \renewcommand\thefigure{\arabic{figure}}
  • in MWE below is (for now) considered, that all figures in your report haw the same way of numbering, as you ask in question:
\RequirePackage{fix-cm}
\documentclass[%
    twoside, openright, titlepage, numbers=noenddot,%
    cleardoublepage=empty,%
    abstractoff,%
    BCOR=5.5mm, paper=a5, fontsize=10pt,% A5 soft cover
                ]{scrreprt}

\usepackage{graphicx} \renewcommand\thefigure{\arabic{figure}} % <----

\begin{document} \frenchspacing \raggedbottom%

\begin{figure}[ht] \centering \includegraphics[width=0.4\linewidth]{example-image-a} \caption{\textbf{Title}. Content.} \end{figure}

\begin{figure}[ht] \centering \includegraphics[width=0.4\linewidth]{example-image-b} \caption{\textbf{Title}. Content.} \end{figure}

\end{document}

enter image description here

Zarko
  • 296,517
1

I don't get “0.1” and ”0.2”, because scrreprt omits the chapter number if it's 0.

On the other hand, I get “1.1” and “1.2” if a chapter is started.

I guess you want the figures to be numbered consecutively across chapters, so you need

\counterwithout{figure}{chapter}

enter image description here

Full code. Look at the comments I added. Also [t] is not a good option: better [tp] or [htp].

\RequirePackage{fix-cm}
\documentclass[
  twoside,
%  openright, % <--- omitted just for showing the result
  titlepage,
  numbers=noenddot,
  cleardoublepage=empty,
  abstract=false, % <--- abstractoff is deprecated
  BCOR=5.5mm,
  paper=a5,
  fontsize=10pt,% A5 soft cover
]{scrreprt}

%\usepackage{etex} % <--- no longer needed, better not use it %\reserveinserts{10} % <--- no longer needed, and invalid without etex

\usepackage[final]{pdfpages}

\counterwithout{figure}{chapter}

\frenchspacing \raggedbottom % <--- not good with twoside

\begin{document}

\chapter{Test A}

\begin{figure}[htp] \centering \resizebox{0.4\linewidth}{!}{% ABCDEF } \caption{\textbf{Title}. Content.} \end{figure}

\begin{figure}[htp] \centering \resizebox{0.4\linewidth}{!}{% ABCDEF } \caption{\textbf{Title}. Content.} \end{figure}

\chapter{Test B}

\begin{figure}[htp] \centering \resizebox{0.4\linewidth}{!}{% ABCDEF } \caption{\textbf{Title}. Content.} \end{figure}

\begin{figure}[htp] \centering \resizebox{0.4\linewidth}{!}{% ABCDEF } \caption{\textbf{Title}. Content.} \end{figure}

\end{document}

egreg
  • 1,121,712