lstdoc.sty 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466
  1. %%
  2. %% This is file `lstdoc.sty',
  3. %% generated with the docstrip utility.
  4. %%
  5. %% The original source files were:
  6. %%
  7. %% listings.dtx (with options: `doc')
  8. %%
  9. %% Please read the software license in listings.dtx or listings.dvi.
  10. %%
  11. %% (w)(c) 1996 -- 2002 Carsten Heinz and/or any other author
  12. %% listed elsewhere in this file.
  13. %%
  14. %% This file is distributed under the terms of the LaTeX Project Public
  15. %% License from CTAN archives in directory macros/latex/base/lppl.txt.
  16. %% Either version 1.0 or, at your option, any later version.
  17. %%
  18. %% Permission is granted to modify the listings package as well as
  19. %% lstdrvrs.dtx. You are not allowed to distribute a modified version
  20. %% of the package or lstdrvrs.dtx unless you change the file names and
  21. %% provide the original files. In any case it is better to contact the
  22. %% address below; other users will welcome removed bugs, new features,
  23. %% and additional programming languages.
  24. %%
  25. %% The listings package is free software.
  26. %%
  27. %% However, if you distribute the package as part of a commercial
  28. %% product or if you use the package to prepare a commercial document
  29. %% (books, journals, and so on), I'd like to encourage you to make a
  30. %% donation to the LaTeX3 fund. The size of this `license fee' should
  31. %% depend on the value of the package for your product. For more
  32. %% information about LaTeX see http://www.latex-project.org
  33. %%
  34. %% No matter whether you use the package for a commercial or
  35. %% non-commercial document, please send me a copy of the document (.dvi,
  36. %% .ps, .pdf, hardcopy, etc.) to support further development---it is
  37. %% easier to introduce new features or simplify things if I see how the
  38. %% package is used by other people.
  39. %%
  40. %% Send comments and ideas on the package, error reports and additional
  41. %% programming languages to <[email protected]>.
  42. %%
  43. \def\filedate{2002/04/01}
  44. \def\fileversion{1.0}
  45. \ProvidesPackage{lstdoc}
  46. [\filedate\space\fileversion\space(Carsten Heinz)]
  47. \let\lstdoc@currversion\fileversion
  48. \RequirePackage[writefile]{listings}[2002/04/01]
  49. \newif\iffancyvrb \IfFileExists{fancyvrb.sty}{\fancyvrbtrue}{}
  50. \newif\ifcolor \IfFileExists{color.sty}{\colortrue}{}
  51. \newif\ifhyper \@ifundefined{pdfoutput}{}
  52. {\IfFileExists{hyperref.sty}{\hypertrue}{}}
  53. \newif\ifalgorithmic \IfFileExists{algorithmic.sty}{\algorithmictrue}{}
  54. \iffancyvrb \RequirePackage{fancyvrb}\fi
  55. \ifhyper \RequirePackage[colorlinks]{hyperref}\else
  56. \def\href#1{\texttt}\fi
  57. \ifcolor \RequirePackage{color}\fi
  58. \ifalgorithmic \RequirePackage{algorithmic}\fi
  59. \RequirePackage{nameref}
  60. \renewcommand\ref{\protect\T@ref}
  61. \renewcommand\pageref{\protect\T@pageref}
  62. \def\lst@BeginRemark#1{%
  63. \begin{quote}\topsep0pt\let\small\footnotesize\small#1:}
  64. \def\lst@EndRemark{\end{quote}}
  65. \newenvironment{TODO}
  66. {\lst@BeginRemark{To do}}{\lst@EndRemark}
  67. \newenvironment{ALTERNATIVE}
  68. {\lst@BeginRemark{Alternative}}{\lst@EndRemark}
  69. \newenvironment{REMOVED}
  70. {\lst@BeginRemark{Removed}}{\lst@EndRemark}
  71. \newenvironment{OLDDEF}
  72. {\lst@BeginRemark{Old definition}}{\lst@EndRemark}
  73. \def\advise{\par\list\labeladvise
  74. {\advance\linewidth\@totalleftmargin
  75. \@totalleftmargin\z@
  76. \@listi
  77. \let\small\footnotesize \small\sffamily
  78. \parsep \z@ \@plus\z@ \@minus\z@
  79. \topsep6\p@ \@plus1\p@\@minus2\p@
  80. \def\makelabel##1{\hss\llap{##1}}}}
  81. \let\endadvise\endlist
  82. \def\advisespace{\hbox{}\qquad}
  83. \def\labeladvise{$\to$}
  84. \newenvironment{syntax}
  85. {\list{}{\itemindent-\leftmargin
  86. \def\makelabel##1{\hss\lst@syntaxlabel##1,,,,\relax}}}
  87. {\endlist}
  88. \def\lst@syntaxlabel#1,#2,#3,#4\relax{%
  89. \llap{\scriptsize\itshape#3}%
  90. \def\lst@temp{#2}%
  91. \expandafter\lst@syntaxlabel@\meaning\lst@temp\relax
  92. \rlap{\hskip-\itemindent\hskip\itemsep\hskip\linewidth
  93. \llap{\ttfamily\lst@temp}\hskip\labelwidth
  94. \def\lst@temp{#1}%
  95. \ifx\lst@temp\lstdoc@currversion#1\fi}}
  96. \def\lst@syntaxlabel@#1>#2\relax
  97. {\edef\lst@temp{\zap@space#2 \@empty}}
  98. \newcommand*\syntaxnewline{\newline\hbox{}\kern\labelwidth}
  99. \newcommand*\syntaxor{\qquad or\qquad}
  100. \newcommand*\syntaxbreak
  101. {\hfill\kern0pt\discretionary{}{\kern\labelwidth}{}}
  102. \let\syntaxfill\hfill
  103. \def\alternative#1{\lst@true \alternative@#1,\relax,}
  104. \def\alternative@#1,{%
  105. \ifx\relax#1\@empty
  106. \expandafter\@gobble
  107. \else
  108. \ifx\@empty#1\@empty\else
  109. \lst@if \lst@false \else $\vert$\fi
  110. \textup{\texttt{#1}}%
  111. \fi
  112. \fi
  113. \alternative@}
  114. \long\def\m@cro@#1#2#3{\endgroup \topsep\MacroTopsep \trivlist
  115. \edef\saved@macroname{\string#3}%
  116. \def\makelabel##1{\llap{##1}}%
  117. \if@inlabel
  118. \let\@tempa\@empty \count@\macro@cnt
  119. \loop \ifnum\count@>\z@
  120. \edef\@tempa{\@tempa\hbox{\strut}}\advance\count@\m@ne \repeat
  121. \edef\makelabel##1{\llap{\vtop to\baselineskip
  122. {\@tempa\hbox{##1}\vss}}}%
  123. \advance \macro@cnt \@ne
  124. \else \macro@cnt\@ne \fi
  125. \edef\@tempa{\noexpand\item[%
  126. #1%
  127. \noexpand\PrintMacroName
  128. \else
  129. \expandafter\noexpand\csname Print#2Name\endcsname % MODIFIED
  130. \fi
  131. {\string#3}]}%
  132. \@tempa
  133. \global\advance\c@CodelineNo\@ne
  134. #1%
  135. \SpecialMainIndex{#3}\nobreak
  136. \DoNotIndex{#3}%
  137. \else
  138. \csname SpecialMain#2Index\endcsname{#3}\nobreak % MODIFIED
  139. \fi
  140. \global\advance\c@CodelineNo\m@ne
  141. \ignorespaces}
  142. \def\macro{\begingroup
  143. \catcode`\\12
  144. \MakePrivateLetters \m@cro@ \iftrue {Macro}}% MODIFIED
  145. \def\environment{\begingroup
  146. \catcode`\\12
  147. \MakePrivateLetters \m@cro@ \iffalse {Env}}% MODIFIED
  148. \def\newdocenvironment#1#2#3#4{%
  149. \@namedef{#1}{#3\begingroup \catcode`\\12\relax
  150. \MakePrivateLetters \m@cro@ \iffalse {#2}}%
  151. \@namedef{end#1}{#4\endmacro}%
  152. \@ifundefined{Print#2Name}{\expandafter
  153. \let\csname Print#2Name\endcsname\PrintMacroName}{}%
  154. \@ifundefined{SpecialMain#2Index}{\expandafter
  155. \let\csname SpecialMain#2Index\endcsname\SpecialMainIndex}{}}
  156. \newdocenvironment{aspect}{Aspect}{}{}
  157. \def\PrintAspectName#1{}
  158. \def\SpecialMainAspectIndex#1{%
  159. \@bsphack
  160. \index{aspects:\levelchar\protect\aspectname{#1}\encapchar main}%
  161. \@esphack}
  162. \newdocenvironment{lstkey}{Key}{}{}
  163. \def\PrintKeyName#1{\strut\keyname{#1}\ }
  164. \def\SpecialMainKeyIndex#1{%
  165. \@bsphack
  166. \index{keys\levelchar\protect\keyname{#1}\encapchar main}%
  167. \@esphack}
  168. \newcounter{argcount}
  169. \def\labelargcount{\texttt{\#\arabic{argcount}}\hskip\labelsep$=$}
  170. \def\macroargs{\list\labelargcount
  171. {\usecounter{argcount}\leftmargin=2\leftmargin
  172. \parsep \z@ \@plus\z@ \@minus\z@
  173. \topsep4\p@ \@plus\p@ \@minus2\p@
  174. \itemsep\z@ \@plus\z@ \@minus\z@
  175. \def\makelabel##1{\hss\llap{##1}}}}
  176. \def\endmacroargs{\endlist\@endparenv}
  177. \lst@RequireAspects{writefile}
  178. \newbox\lst@samplebox
  179. \lstnewenvironment{lstsample}[3][]
  180. {\global\let\lst@intname\@empty
  181. \gdef\lst@sample{#2}%
  182. \setbox\lst@samplebox=\hbox\bgroup
  183. \setkeys{lst}{language={},style={},tabsize=4,gobble=5,%
  184. basicstyle=\small\ttfamily,basewidth=0.51em,point={#1}}
  185. #3%
  186. \lst@BeginAlsoWriteFile{\jobname.tmp}}
  187. {\lst@EndWriteFile\egroup
  188. \ifdim \wd\lst@samplebox>.5\linewidth
  189. \begin{center}%
  190. \hbox to\linewidth{\box\lst@samplebox\hss}%
  191. \end{center}%
  192. \lst@sampleInput
  193. \else
  194. \begin{center}%
  195. \begin{minipage}{0.45\linewidth}\lst@sampleInput\end{minipage}%
  196. \qquad
  197. \begin{minipage}{0.45\linewidth}%
  198. \hbox to\linewidth{\box\lst@samplebox\hss}%
  199. \end{minipage}%
  200. \end{center}%
  201. \fi}
  202. \lst@InstallKeywords{p}{point}{pointstyle}\relax{keywordstyle}{}ld
  203. \lstnewenvironment{lstxsample}[1][]
  204. {\begingroup
  205. \setkeys{lst}{belowskip=-\medskipamount,language={},style={},%
  206. tabsize=4,gobble=5,basicstyle=\small\ttfamily,%
  207. basewidth=0.51em,point={#1}}
  208. \lst@BeginAlsoWriteFile{\jobname.tmp}}
  209. {\endgroup
  210. \endgroup}
  211. \def\lst@sampleInput{%
  212. \MakePercentComment\catcode`\^^M=10\relax
  213. \small\lst@sample
  214. {\setkeys{lst}{SelectCharTable=\lst@ReplaceInput{\^\^I}%
  215. {\lst@ProcessTabulator}}%
  216. \leavevmode \input{\jobname.tmp}}\MakePercentIgnore}
  217. \renewcommand\paragraph{\@startsection{paragraph}{4}{\z@}%
  218. {1.25ex \@plus1ex \@minus.2ex}%
  219. {-1em}%
  220. {\normalfont\normalsize\bfseries}}
  221. \def\lstref#1{\emph{\ref{#1} \nameref{#1}}}
  222. \def\@part[#1]#2{\addcontentsline{toc}{part}{#1}%
  223. {\parindent\z@ \raggedright \interlinepenalty\@M
  224. \normalfont \huge \bfseries #2\markboth{}{}\par}%
  225. \nobreak\vskip 3ex\@afterheading}
  226. \renewcommand*\l@section[2]{%
  227. \addpenalty\@secpenalty
  228. \addvspace{.25em \@plus\p@}%
  229. \setlength\@tempdima{1.5em}%
  230. \begingroup
  231. \parindent \z@ \rightskip \@pnumwidth
  232. \parfillskip -\@pnumwidth
  233. \leavevmode
  234. \advance\leftskip\@tempdima
  235. \hskip -\leftskip
  236. #1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
  237. \endgroup}
  238. \renewcommand*\l@subsection{\@dottedtocline{2}{0pt}{2.3em}}
  239. \renewcommand*\l@subsubsection{\@dottedtocline{3}{0pt}{3.2em}}
  240. \newcommand\ikeyname[1]{%
  241. \lstkeyindex{#1}{}%
  242. \lstaspectindex{#1}{}%
  243. \keyname{#1}}
  244. \newcommand\ekeyname[1]{%
  245. \@bsphack
  246. \lstkeyindex{#1}{\encapchar usage}%
  247. \lstaspectindex{#1}{\encapchar usage}%
  248. \@esphack}
  249. \newcommand\rkeyname[1]{%
  250. \@bsphack
  251. \lstkeyindex{#1}{\encapchar main}%
  252. \lstaspectindex{#1}{\encapchar main}%
  253. \@esphack{\rstyle\keyname{#1}}}
  254. \newcommand\icmdname[1]{%
  255. \@bsphack
  256. \lstaspectindex{#1}{}%
  257. \@esphack\texttt{\string#1}}
  258. \newcommand\rcmdname[1]{%
  259. \@bsphack
  260. \lstaspectindex{#1}{\encapchar main}%
  261. \@esphack\texttt{\rstyle\string#1}}
  262. \def\lstaspectindex#1#2{%
  263. \global\@namedef{lstkandc@\string#1}{}%
  264. \@ifundefined{lstisaspect@\string#1}
  265. {\index{unknown\levelchar
  266. \protect\texttt{\protect\string\string#1}#2}}%
  267. {\index{\@nameuse{lstisaspect@\string#1}\levelchar
  268. \protect\texttt{\protect\string\string#1}#2}}%
  269. }
  270. \def\lstkeyindex#1#2{%
  271. }
  272. \def\lstisaspect[#1]#2{%
  273. \global\@namedef{lstaspect@#1}{#2}%
  274. \lst@AddTo\lst@allkeysandcmds{,#2}%
  275. \@for\lst@temp:=#2\do
  276. {\ifx\@empty\lst@temp\else
  277. \global\@namedef{lstisaspect@\lst@temp}{#1}%
  278. \fi}}
  279. \gdef\lst@allkeysandcmds{}
  280. \def\lstprintaspectkeysandcmds#1{%
  281. \lst@true
  282. \expandafter\@for\expandafter\lst@temp
  283. \expandafter:\expandafter=\csname lstaspect@#1\endcsname\do
  284. {\lst@if\lst@false\else, \fi \texttt{\lst@temp}}}
  285. \def\lstcheckreference{%
  286. \@for\lst@temp:=\lst@allkeysandcmds\do
  287. {\ifx\lst@temp\@empty\else
  288. \@ifundefined{lstkandc@\lst@temp}
  289. {\typeout{\lst@temp\space not in reference guide?}}{}%
  290. \fi}}
  291. \newcommand*\lst{\texttt{lst}}
  292. \newcommand*\Cpp{C\texttt{++}}
  293. \let\keyname\texttt
  294. \let\keyvalue\texttt
  295. \let\hookname\texttt
  296. \newcommand*\aspectname[1]{{\normalfont\sffamily#1}}
  297. \DeclareRobustCommand\packagename[1]{%
  298. {\leavevmode\text@command{#1}%
  299. \switchfontfamily\sfdefault\rmdefault
  300. \check@icl #1\check@icr
  301. \expandafter}}%
  302. \def\switchfontfamily#1#2{%
  303. \begingroup\xdef\@gtempa{#1}\endgroup
  304. \ifx\f@family\@gtempa\fontfamily#2%
  305. \else\fontfamily#1\fi
  306. \selectfont}
  307. \ifcolor
  308. \definecolor{darkgreen}{rgb}{0,0.6,0}
  309. \def\rstyle{\color{darkgreen}}
  310. \else
  311. \let\rstyle\empty
  312. \fi
  313. \gdef\lst@emails{}
  314. \newcommand*\lstthanks[2]
  315. {#1\lst@AddTo\lst@emails{,#1,<#2>}%
  316. \ifx\@empty#2\@empty\typeout{Missing email for #1}\fi}
  317. \newcommand*\lsthelper[3]
  318. {{\let~\ #1}%
  319. \lst@IfOneOf#1\relax\lst@emails
  320. {}{\typeout{^^JWarning: Unknown helper #1.^^J}}}
  321. \lstdefinelanguage[doc]{Pascal}{%
  322. morekeywords={alfa,and,array,begin,boolean,byte,case,char,const,div,%
  323. do,downto,else,end,false,file,for,function,get,goto,if,in,%
  324. integer,label,maxint,mod,new,not,of,or,pack,packed,page,program,%
  325. procedure,put,read,readln,real,record,repeat,reset,rewrite,set,%
  326. text,then,to,true,type,unpack,until,var,while,with,write,writeln},%
  327. sensitive=false,%
  328. morecomment=[s]{(*}{*)},%
  329. morecomment=[s]{\{}{\}},%
  330. morestring=[d]{'}}
  331. \lstdefinestyle{}
  332. {basicstyle={},%
  333. keywordstyle=\bfseries,identifierstyle={},%
  334. commentstyle=\itshape,stringstyle={},%
  335. numberstyle={},stepnumber=1,%
  336. pointstyle=\pointstyle}
  337. \def\pointstyle{%
  338. {\let\lst@um\@empty \xdef\@gtempa{\the\lst@token}}%
  339. \expandafter\lstkeyindex\expandafter{\@gtempa}{}%
  340. \expandafter\lstaspectindex\expandafter{\@gtempa}{}%
  341. \rstyle}
  342. \lstset{defaultdialect=[doc]Pascal,language=Pascal,style={}}
  343. \def\lstscanlanguages#1#2#3{%
  344. \begingroup
  345. \def\lst@DefDriver@##1##2##3##4[##5]##6{%
  346. \lst@false
  347. \lst@lAddTo\lst@scan{##6(##5),}%
  348. \begingroup
  349. \@ifnextchar[{\lst@XDefDriver{##1}##3}{\lst@DefDriver@@##3}}%
  350. \def\lst@XXDefDriver[##1]{}%
  351. \lst@InputCatcodes
  352. \def\lst@dontinput{#3}%
  353. \let\lst@scan\@empty
  354. \lst@for{#2}\do{%
  355. \lst@IfOneOf##1\relax\lst@dontinput
  356. {}%
  357. {\InputIfFileExists{##1}{}{}}}%
  358. \global\let\@gtempa\lst@scan
  359. \endgroup
  360. \let#1\@gtempa}
  361. \def\lstprintlanguages#1{%
  362. \def\do##1{\setbox\@tempboxa\hbox{##1\space\space}%
  363. \ifdim\wd\@tempboxa<.5\linewidth \wd\@tempboxa.5\linewidth
  364. \else \wd\@tempboxa\linewidth \fi
  365. \box\@tempboxa\allowbreak}%
  366. \begin{quote}
  367. \par\noindent
  368. \hyphenpenalty=\@M \rightskip=\z@\@plus\linewidth\relax
  369. \lst@BubbleSort#1%
  370. \expandafter\lst@NextLanguage#1\relax(\relax),%
  371. \end{quote}}
  372. \def\lst@NextLanguage#1(#2),{%
  373. \ifx\relax#1\else
  374. \def\lst@language{#1}\def\lst@dialects{(#2),}%
  375. \expandafter\lst@NextLanguage@
  376. \fi}
  377. \def\lst@NextLanguage@#1(#2),{%
  378. \def\lst@temp{#1}%
  379. \ifx\lst@temp\lst@language
  380. \lst@lAddTo\lst@dialects{(#2),}%
  381. \expandafter\lst@NextLanguage@
  382. \else
  383. \do{\lst@language
  384. \ifx\lst@dialects\lst@emptydialect\else
  385. \expandafter\lst@NormedDef\expandafter\lst@language
  386. \expandafter{\lst@language}%
  387. \space(%
  388. \lst@BubbleSort\lst@dialects
  389. \expandafter\lst@PrintDialects\lst@dialects(\relax),%
  390. )%
  391. \fi}%
  392. \def\lst@next{\lst@NextLanguage#1(#2),}%
  393. \expandafter\lst@next
  394. \fi}
  395. \def\lst@emptydialect{(),}
  396. \def\lst@PrintDialects(#1),{%
  397. \ifx\@empty#1\@empty empty\else
  398. \lst@PrintDialect{#1}%
  399. \fi
  400. \lst@PrintDialects@}
  401. \def\lst@PrintDialects@(#1),{%
  402. \ifx\relax#1\else
  403. , \lst@PrintDialect{#1}%
  404. \expandafter\lst@PrintDialects@
  405. \fi}
  406. \def\lst@PrintDialect#1{%
  407. \lst@NormedDef\lst@temp{#1}%
  408. \expandafter\ifx\csname\@lst dd@\lst@language\endcsname\lst@temp
  409. \texttt{\underbar{#1}}%
  410. \else
  411. \texttt{#1}%
  412. \fi}
  413. \def\lst@IfLE#1#2\@empty#3#4\@empty{%
  414. \ifx #1\relax
  415. \let\lst@next\@firstoftwo
  416. \else \ifx #3\relax
  417. \let\lst@next\@secondoftwo
  418. \else
  419. \lowercase{\ifx#1#3}%
  420. \def\lst@next{\lst@IfLE#2\@empty#4\@empty}%
  421. \else
  422. \lowercase{\ifnum`#1<`#3}\relax
  423. \let\lst@next\@firstoftwo
  424. \else
  425. \let\lst@next\@secondoftwo
  426. \fi
  427. \fi
  428. \fi \fi
  429. \lst@next}
  430. \def\lst@BubbleSort#1{%
  431. \ifx\@empty#1\else
  432. \lst@false
  433. \expandafter\lst@BubbleSort@#1\relax,\relax,%
  434. \expandafter\lst@BubbleSort@\expandafter,\lst@sorted
  435. \relax,\relax,%
  436. \let#1\lst@sorted
  437. \lst@if
  438. \def\lst@next{\lst@BubbleSort#1}%
  439. \expandafter\expandafter\expandafter\lst@next
  440. \fi
  441. \fi}
  442. \def\lst@BubbleSort@#1,#2,{%
  443. \ifx\@empty#1\@empty
  444. \def\lst@sorted{#2,}%
  445. \def\lst@next{\lst@BubbleSort@@}%
  446. \else
  447. \let\lst@sorted\@empty
  448. \def\lst@next{\lst@BubbleSort@@#1,#2,}%
  449. \fi
  450. \lst@next}
  451. \def\lst@BubbleSort@@#1,#2,{%
  452. \ifx\relax#1\else
  453. \ifx\relax#2%
  454. \lst@lAddTo\lst@sorted{#1,}%
  455. \expandafter\expandafter\expandafter\lst@BubbleSort@@@
  456. \else
  457. \lst@IfLE #1\relax\@empty #2\relax\@empty
  458. {\lst@lAddTo\lst@sorted{#1,#2,}}%
  459. {\lst@true \lst@lAddTo\lst@sorted{#2,#1,}}%
  460. \expandafter\expandafter\expandafter\lst@BubbleSort@@
  461. \fi
  462. \fi}
  463. \def\lst@BubbleSort@@@#1\relax,{}
  464. \endinput
  465. %%
  466. %% End of file `lstdoc.sty'.