summaryrefslogtreecommitdiff
path: root/info/examples/ltt/sect.sty
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /info/examples/ltt/sect.sty
Initial commit
Diffstat (limited to 'info/examples/ltt/sect.sty')
-rw-r--r--info/examples/ltt/sect.sty14
1 files changed, 14 insertions, 0 deletions
diff --git a/info/examples/ltt/sect.sty b/info/examples/ltt/sect.sty
new file mode 100644
index 0000000000..77d8a622c9
--- /dev/null
+++ b/info/examples/ltt/sect.sty
@@ -0,0 +1,14 @@
+% sect.sty (Fragment)
+\def\section{\secdef\@section\@ssection}
+\def\@section[#1]#2{
+ \ifnum \c@secnumdepth >\m@ne
+ \refstepcounter{section}%
+ \addcontentsline{toc}{section}{%
+ \protect\numberline{\thesection}#1}
+ \else
+ \addcontentsline{toc}{section}{#1}
+ \fi
+ \sectionmark{#1}%
+ \@makesectionhead{#2}\@afterheading
+ }
+\def\@ssection#1{\@makessectionhead{#1} \@afterheading}