I would like to remove the column heading "Page" from the table of contents. I have looked around and cannot seem to find an answer (or a similar question).
I would also like to add a period "." after only the sections in the table of contents. I have found and tried the following code which produces a period after every entry in the table of contents, not just the sections.
\let \savenumberline \numberline
\def \numberline#1{\savenumberline{#1.}}
Edit: Adding a MWE (hopefully). My document is actually made up of at least 10 separate latex files included by using \input and is still 11,500 lines long. I hope that I have included enough to be helpful. There are items that are commented out just so I didn't lose what "solutions" I had found so far. The foreword is commented out because it was including a list of tables, which was not desired.
I also wanted to add that I noticed that my table of contents is no longer hyperlinking. I'm wondering if this is because I chose "tableofcontents" instead of using the foreword command.
\documentclass[draft,wd,letterpaper]{isov2} % needed to change ; to , in order to compile
\let\ifpdf\relax % required to get rid of fatal error
% Latex Error: /usr/local/texlive/2013/texmf-dist/tex/generic/oberdiek/hobsub-generic.sty:3540 Package ifpdf Error: Name clash, \ifpdf is already defined.
%\usepackage[top=3cm, bottom=3cm, left=3cm, right=3cm]{geometry}
\usepackage{float}
% see http://tex.stackexchange.com/questions/46512/too-many-unprocessed-floats
\usepackage{morefloats}
% see http://www.tex.ac.uk/cgi-bin/texfaq2html?label=underscore
\usepackage{import} % file path
% see http://http://www.ctan.org/pkg/import
\usepackage{multicol}
% see http://www.ctan.org/pkg/multicol
\usepackage{tabularx}
\usepackage{longtable}
% table of contents hyperlinks
\usepackage{hyperref}
\hypersetup{
colorlinks,
citecolor=black,
filecolor=black,
linkcolor=black,
urlcolor=black
}
%\usepackage{lmodern}"
%\usepackage[T1]{fontenc}"
%\usepackage{textcomp}"
%\usepackage{underscore}"
% This bit controls how ASN1 is formatted
\usepackage{listings}
\lstdefinelanguage{ASN1} {
keywords={CHOICE, SEQUENCE, BEGIN, END, IMPLICIT, EXPLICIT, INTEGER, DEFINITIONS},
sensitive=false,
morecomment=[s]{(--}{--)},
morecomment=[l]{--}
}
\lstnewenvironment{asn1}[1][] {
\lstset{
language=ASN1,
tabsize=2,
xleftmargin=1em
captionpos=b,
frame=single,
% basicstyle=\scriptsize,
basicstyle=\footnotesize\ttfamily,
float,
#1
}
}
{}
\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
\newcolumntype{C}[1]{>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
\newcolumntype{R}[1]{>{\raggedleft\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
% essentially allows one to build a table within a table
% \newcommand{\specialcell}[2][c]{%
% \begin{tabular}[#1]{@{}c@{}}#2\end{tabular}}
% allow underscores to serve as linebreaks for wrapping
\renewcommand\_{\textunderscore\allowbreak}
% defines the command \camelhyphen. Anything in the argument can break before a capital letter and wrap with a hyphen
\makeatletter
\def\camelhyphen{\leavevmode\begingroup
\let\ifcase\iftrue
\def\or##1{%
\catcode`##1\active\uccode`\~`##1\uppercase{%
\def~{\egroup\-\hbox\bgroup\string##1}}}%
\@Alph{}%
\@camelhyphen}
\def\@camelhyphen#1{{\hbox\bgroup#1\egroup}\endgroup}
\makeatother
\standard{ISO/IEEE 11073-10201}
\yearofedition{2013}
\languageofedition{(E)}
\setcounter{tocdepth}{3} % ToC includes ssclauses and above
% Add a period (.) after the section numbering
\makeatletter
\def\@seccntformat#1{\csname the#1\endcsname.\quad}
\makeatother
\usepackage{etoolbox} \patchcmd{\tableofcontents}{\hfil\pagename}{}{}{}
%\usepackage[dotinlabels]{titletoc}
%\usepackage{tocloft}
%\newcommand{\cftdot}{.}
%\let \savenumberline \numberline
%\def \numberline#1{\savenumberline{#1.}}
\usepackage{lipsum}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{document}
\title{Example Document}
\newpage
\tableofcontents
\clause{Hello}\lipsum
\sclause{Little}\lipsum
\clause{Second}\lipsum
\end{document}
Clarification: I did not edit my actual .tex file to create a MWE. I did not comment anything out that isn't originally commented in my actual file. The code above creates a similar looking document to what I am working with. I also realize now that I have been referring to clauses as sections, but they are actually clauses.
In the TOC, I would like a period after the clause number only (i.e. not sclause or ssclauses).
@Gonzalo Medina - Thank you very much! That worked beautifully! My TOC now does not show "Page"
Thank you to everyone for your helpful comments.
isov2
class has\clause
,\sclause
and similar, Which of those are the ones that you want to add a period to?\usepackage{etoolbox} \patchcmd{\tableofcontents}{\hfil\pagename}{}{}{}