0

If you look around the TeX Stack Exchange, you'll see a lot of people asking how to omit section numbering. However, the problem I'm having with a particular conference paper template is that it is, by default, omitting section/subsection numbering, when in fact I need them to be displayed.

I honestly don't know where to look for a solution. I tried searching STY file for a clue, but since I have no experience with defining templates, I couldn't really tell.

Here are the section and subsection definitions for the template.

\renewcommand\section{\@startsection{section}{1}{\z@}%
                   {-6\p@ \@plus -4\p@ \@minus -4\p@}%
                   {0\p@ \@plus 4\p@ \@minus 4\p@}%
                   {\normalfont\XIIIPT\bfseries\boldmath
                    \rightskip=\z@ \@plus 8em\pretolerance=10000 }}

\renewcommand\subsection{\@startsection{subsection}{2}{\z@}%
                   {-6\p@ \@plus -4\p@ \@minus -4\p@}%
                   {0\p@ \@plus 4\p@ \@minus 4\p@}%
                   {\normalfont\normalsize\bfseries\boldmath
                    \rightskip=\z@ \@plus 8em\pretolerance=10000 }}

Any help would be deeply appreciated.

EDIT: For bevity's sake, here's a link to download the template in its entirety.

  • 1
    Is your template available somewhere? – samcarter_is_at_topanswers.xyz Mar 16 '18 at 14:32
  • 1
    Hi, welcome. We need more information about that template, if I try \documentclass{article} \newcommand\XIIIPT{} \makeatletter <your code> \makeatother \begin{document} \section{a} \subsection{b} \end{document} I do get numbered sections/subsections, so something you haven't showed us is causing the missing numbers. (For example, \setcounter{secnumdepth}{-1} would remove the numbering.) – Torbjørn T. Mar 16 '18 at 14:33
  • 1
    if the documentclass sets secnumdepth low enough sections won't be numbered, but it would be odd to change that in a document. If the house style for some publication is unnumbered sections then that's presumably what they want. – David Carlisle Mar 16 '18 at 14:39
  • Thank you for your comments! Should I paste the whole template, or just post a link to download it? – Danks C. Mar 16 '18 at 14:40
  • It looks like http://www.sbc.org.br/documentos-da-sbc/category/169-templates-para-artigos-e-capitulos-de-livros from the Sociedade Brasileira de Computação, is that it? – Marijn Mar 16 '18 at 14:43
  • @Marijn that's exactly right. I've edited the question to include a link to it. – Danks C. Mar 16 '18 at 14:44
  • They say in the example file that section numbering is optional, are you sure you want to have numbers? – Marijn Mar 16 '18 at 14:47
  • I do get numbered section if I compile the example file from your link. Can you make a minimal working example (MWE) which shows teh missing numbers? – samcarter_is_at_topanswers.xyz Mar 16 '18 at 14:49
  • That is odd, I don't :) did you take the article template or the book chapter template? – Marijn Mar 16 '18 at 14:50
  • @Marijn sbc-template.tex. Are there any other example? – samcarter_is_at_topanswers.xyz Mar 16 '18 at 14:51
  • I was able to solve the issue: it wasn't a problem with the template, it was an old bug with titlesec.sty. I fixed it by upgrading it to the most recent release. I don't have enough reputation to answer my own question yet, how should I procede? – Danks C. Mar 16 '18 at 14:57
  • 1
    So same as in https://tex.stackexchange.com/questions/299969/titlesec-loss-of-section-numbering-with-the-new-update-2016-03-15? Then we can close as duplicate. – Torbjørn T. Mar 16 '18 at 14:58
  • @TorbjørnT. Basically, yes. I apologize for wasting everyone's time. Since I'm using a template, I thought that could be the problem. It never crossed my mind that the problem could be in this particular package. – Danks C. Mar 16 '18 at 15:02
  • 1
    No worries, it happens. Glad you worked it out. – Torbjørn T. Mar 16 '18 at 15:04

0 Answers0