如何解决手册乳胶部分IEEE标准
我在/ paragraph节下定义了两个新的节。一个是“ \ mysection”,另一个是“ \ myszsection”。 \ mysection未重置,并且在使用mysection之后,段落编号没有增加。
\documentclass[conference]{IEEEtran}
\usepackage{titlesec}
\usepackage{titletoc}
\usepackage{chngcntr}
\newcounter{mysection}
\setcounter{secnumdepth}{5}
\titleclass{\mysection}{straight}[\part]
\titleformat{\mysection}[hang]
{\itshape \normalsize}{\themysection}{0em}{.}
\titlespacing{\mysection}{25pt}{0ex }{0 ex }
\renewcommand{\themysection}{\roman{mysection}}
\renewcommand{\theparagraph}{\themysection.\arabic{paragraph}}
\counterwithin{paragraph}{mysection}
\newcounter{myzsection}
\setcounter{secnumdepth}{6}
\titleclass{\myzsection}{straight}[\part]
\titleformat{\myzsection}[hang]
{\itshape \normalsize}{\themyzsection}{1em}{}
\titlespacing{\myzsection}{33pt}{0ex }{0 ex }
\renewcommand{\themyzsection}{\arabic{myzsection}}
\renewcommand{\theparagraph}{\themyzsection.\arabic{paragraph}}
\counterwithin{paragraph}{myzsection}
\contentsmargin{1em}
\begin{document}
\section{Introduction}
gg
\subsection{deatails}\label{AA}
gg
\subsubsection{gg again}
gg
\paragraph{gg this too}
gg
\mysection{problem}
gg
\myzsection{problem}
gg
\paragraph{problem1}
When i added them,paragraph number stopped increasing. What to do?
\mysection{problem2}
The counter is not resetting for the new defined sections. When i use them under another section it continues increasing from before. What to do?
\end{document}
- 当我添加它们时,段落号停止增加。该怎么办?
- 未为新定义的部分重置计数器。当我在另一部分下使用它们时,它会比以前持续增加。该怎么办?
解决方法
使用您的代码,您将paragraph
的计数器重置为my(z)section
,但是您需要反过来进行操作(并且段号中也不能包含my(z)section
计数器) :
\documentclass[conference]{IEEEtran}
\usepackage{titlesec}
\usepackage{titletoc}
\usepackage{chngcntr}
\newcounter{mysection}
\setcounter{secnumdepth}{5}
\titleclass{\mysection}{straight}[\part]
\titleformat{\mysection}[hang]
{\itshape \normalsize}{\themysection}{0em}{.}
\titlespacing{\mysection}{25pt}{0ex }{0 ex }
\counterwithin{mysection}{paragraph}
%
\newcounter{myzsection}
\setcounter{secnumdepth}{6}
\titleclass{\myzsection}{straight}[\part]
\titleformat{\myzsection}[hang]
{\itshape \normalsize}{\themyzsection}{1em}{}
\titlespacing{\myzsection}{33pt}{0ex }{0 ex }
\counterwithin{myzsection}{paragraph}
\contentsmargin{1em}
\renewcommand{\themysection}{\roman{mysection}}
\renewcommand{\themyzsection}{\arabic{myzsection}}
\begin{document}
\section{Introduction}
gg
\subsection{deatails}\label{AA}
gg
\subsubsection{gg again}
gg
\paragraph{gg this too}
gg
\mysection{problem}
gg
\myzsection{problem}
gg
\paragraph{problem1}
When i added them,paragraph number stopped increasing. What to do?
\mysection{problem2}
The counter is not resetting for the new defined sections. When i use them under another section it continues increasing from before. What to do?
\end{document}
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。