summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Chausse <benjamin@chausse.xyz>2022-09-13 17:12:54 -0400
committerBenjamin Chausse <benjamin@chausse.xyz>2022-09-13 17:12:54 -0400
commit1723f6c01d8faeceac2cb7b5bef4358ab49bb96d (patch)
tree417d9069bf6c773cb126248848586554f2492943
parent862b9bf55499f412918dfdcede5e259b6f78e6cf (diff)
Table/Figure is number correctly
-rw-r--r--document.sty6
1 files changed, 4 insertions, 2 deletions
diff --git a/document.sty b/document.sty
index 28f51f7..511d030 100644
--- a/document.sty
+++ b/document.sty
@@ -63,8 +63,10 @@
% Figures/Tables %
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~%
-% Count figure within sections (just like equations)
+% Count within sections (third table of section 5 would be Table 5.3)
\counterwithin{figure}{section}
-% Count table within sections (just like equations)
\counterwithin{table}{section}
+% Separate section number from fig/table with a hyphen (5-3 instead of 5.3)
+\renewcommand{\thefigure}{\thesection-\arabic{figure}}
+\renewcommand{\thetable}{\thesection-\arabic{table}}