\ProvidesPackage{epltxchapno}% [2014/01/27 v1.0 ExPex-LaTex chapter numbering integration (JF)] \RequirePackage{expex} % epltxchapno.sty is for use in conjunction with LaTex classes which use % \chapter (book.cls, scrbook.cls, report.cls, and memoir.cls at least). % \excnt is set to 1 at the beginning of each chapter and examples are % numbered (n.1), (n.2), etc. in chapter n. The \deftag/\getref % mechanism produces the desired reference. \@ifundefined{if@mainmatter}{\newif\if@mainmatter\@mainmattertrue}\relax \def\@chapter[#1]#2{\ifnum \c@secnumdepth >\m@ne \if@mainmatter \refstepcounter{chapter}% \excnt=1 \typeout{\@chapapp\space\thechapter.}% \addcontentsline{toc}{chapter}% {\protect\numberline{\thechapter}#1}% \else \addcontentsline{toc}{chapter}{#1}% \fi \else \addcontentsline{toc}{chapter}{#1}% \fi \chaptermark{#1}% \addtocontents{lof}{\protect\addvspace{10\p@}}% \addtocontents{lot}{\protect\addvspace{10\p@}}% \if@twocolumn \@topnewpage[\@makechapterhead{#2}]% \else \@makechapterhead{#2}% \@afterheading \fi} \lingset{exnotype=chapter.arabic}