Graphics, Figures & Tables ⇒ Changing figure caption from Fig 0.0.1. to Fig 1
-
- Posts: 128
- Joined: Wed Jul 04, 2012 5:34 pm
Changing figure caption from Fig 0.0.1. to Fig 1
How does one (no pun intended) accomplish this?
I'm using windows with LyX 2.0 and MiKTeX 2.9
I'm designing a book using the Koma-script class
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Changing figure caption from Fig 0.0.1. to Fig 1
\numberwithin
command from the amsmath package.-
- Posts: 128
- Joined: Wed Jul 04, 2012 5:34 pm
Re: Changing figure caption from Fig 0.0.1. to Fig 1
Thanks
I'm using windows with LyX 2.0 and MiKTeX 2.9
I'm designing a book using the Koma-script class
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Changing figure caption from Fig 0.0.1. to Fig 1

Changing figure caption from Fig 0.0.1. to Fig 1
There might be nothing as insipidtoast is using LyX...kaiserkarl13 wrote:Without aminimal working example of what is currently in your preamble[...]
Have a look at the chngcntr package. The number 0.0.1 stands for
<chapter>.<section>.<figure>
, probably.Code: Select all
\documentclass{scrbook}
% ----------
% this needs to be in the preamble:
\usepackage{chngcntr}
\counterwithout{figure}{chapter}
\counterwithout{figure}{section}
% ----------
\begin{document}
\listoffigures
\chapter{test}
\begin{figure}
\caption{test}
\end{figure}
\chapter{test}
\begin{figure}
\caption{test}
\end{figure}
\end{document}
-
- Posts: 128
- Joined: Wed Jul 04, 2012 5:34 pm
Changing figure caption from Fig 0.0.1. to Fig 1
This does the trick:
Code: Select all
\usepackage{chngcntr}
\counterwithout{figure}{chapter}
\counterwithout{figure}{section}
I'm using windows with LyX 2.0 and MiKTeX 2.9
I'm designing a book using the Koma-script class
-
- Posts: 707
- Joined: Tue Mar 25, 2008 5:02 pm
Changing figure caption from Fig 0.0.1. to Fig 1
There is always something in the preamble---LyX doesn't change that. But without knowing which packages are loaded and, more importantly, which document class is in use, I was a bit short on info.There might be nothing as insipidtoast is using LyX...
LyX is not some magical being that changes the way LaTeX works---it's a front-end.
Re: Changing figure caption from Fig 0.0.1. to Fig 1
What I meant was: it might be difficult to know what in the preamble is. LyX lets you add things to the preamble but doesn't show what it adds itself. One could of course tell LyX to show the whole source, which is pretty easy actually... (didn't think of that earlier, but then I'm not a LyX user).
Regards