summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/listings/lstmisc.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2007-02-28 22:32:28 +0000
committerKarl Berry <karl@freefriends.org>2007-02-28 22:32:28 +0000
commite7d22f9c3388947b1b1e5e8c8519c9ae0684a96f (patch)
tree54fcbbab0ca8c6ff479a36810919d99ce6e9e112 /Master/texmf-dist/tex/latex/listings/lstmisc.sty
parent278b41c83363bdbda2ef386ec54df1c16417a1d8 (diff)
listings update (28feb07)
git-svn-id: svn://tug.org/texlive/trunk@4002 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/listings/lstmisc.sty')
-rw-r--r--Master/texmf-dist/tex/latex/listings/lstmisc.sty52
1 files changed, 24 insertions, 28 deletions
diff --git a/Master/texmf-dist/tex/latex/listings/lstmisc.sty b/Master/texmf-dist/tex/latex/listings/lstmisc.sty
index 4180dc84094..2d2a6435163 100644
--- a/Master/texmf-dist/tex/latex/listings/lstmisc.sty
+++ b/Master/texmf-dist/tex/latex/listings/lstmisc.sty
@@ -4,7 +4,7 @@
%%
%% The original source files were:
%%
-%% listings-1.3.dtx (with options: `misc,0.21')
+%% listings.dtx (with options: `misc,0.21')
%%
%% Please read the software license in listings-1.3.dtx or listings-1.3.pdf.
%%
@@ -72,7 +72,7 @@
\ifnum\lst@length=\z@\else \lst@WFWriteToFile \fi}
\lst@EndAspect
\lst@BeginAspect{strings}
-\gdef\lst@stringtypes{d,b,m,bd,db}
+\gdef\lst@stringtypes{d,b,m,bd,db,s}
\gdef\lst@StringKey#1#2{%
\lst@Delim\lst@stringstyle #2\relax
{String}\lst@stringtypes #1%
@@ -113,14 +113,6 @@
\fi}
\global\let\lst@StringDM@bd\lst@StringDM@b
\global\let\lst@StringDM@db\lst@StringDM@bd
-\gdef\lst@StringDM@a#1#2\@empty#3#4#5{%
- \lst@CArg #2\relax\lst@DefDelimBE{}{}%
- {\let\lst@next\@gobblethree
- \lst@ifletter\else
- \ifx\lst@lastother)\else \ifx\lst@lastother]\else
- \let\lst@next\@empty
- \fi \fi \fi
- \lst@next}#3{#1}{#5}#4}
\gdef\lst@StringDM@m#1#2\@empty#3#4#5{%
\lst@CArg #2\relax\lst@DefDelimBE{}{}%
{\let\lst@next\@gobblethree
@@ -130,6 +122,9 @@
{\let\lst@next\@empty}%
\fi
\lst@next}#3{#1}{#5}#4}
+\gdef\lst@StringDM@s#1#2#3\@empty#4#5#6{%
+ \lst@CArg #2\relax\lst@DefDelimB{}{}{}#4{#1}{#6}%
+ \lst@CArg #3\relax\lst@DefDelimE{}{}{}#5{#1}}
\lst@SaveOutputDef{"7D}\lstum@rbrace
\lst@EndAspect
\lst@BeginAspect{mf}
@@ -327,7 +322,7 @@
\lst@CArg #2\relax\lst@ActiveCDefX
{}%
{\lst@escapeend #4\lst@LeaveAllModes\lst@ReenterModes
- \lst@whitespacefalse}%
+ \lst@newlines\z@ \lst@whitespacefalse}%
{}%
\fi
#3\lst@escapebegin
@@ -750,11 +745,12 @@
\lst@AddToHook{SelectCharTable}
{\lst@iftexcsincludebs \ifx\@empty\lst@texcs\else
\lst@DefSaveDef{`\\}\lsts@texcsbs
- {\ifx\lst@lastother\lstum@backslash
- \lsts@texcsbs\lst@XPrintToken
- \else
- \lst@Merge\lsts@texcsbs
- \fi}%
+ {\lst@ifletter
+ \lst@Output
+ \else
+ \lst@OutputOther
+ \fi
+ \lst@Merge\lsts@texcsbs}%
\fi \fi}
\lst@EndAspect
\lst@BeginAspect[keywords]{directives}
@@ -1206,7 +1202,7 @@
\lst@AddToHook{PreSet}{\let\lst@advancenumber\z@}
\lst@AddToHook{PreInit}
{\ifx\lst@firstnumber\@undefined
- \let\lst@firstnumber\lst@firstline
+ \def\lst@firstnumber{\lst@lineno}%
\fi}
\gdef\lst@SetFirstNumber{%
\ifx\lst@firstnumber\@undefined
@@ -1232,10 +1228,7 @@
\lst@AddToHook{InitVars}
{\global\c@lstnumber\lst@firstnumber
\global\advance\c@lstnumber\lst@advancenumber
- \global\advance\c@lstnumber-\lst@advancelstnum
- \ifx \lst@firstnumber\c@lstnumber
- \global\advance\c@lstnumber-\lst@advancelstnum
- \fi}
+ \global\advance\c@lstnumber-\lst@advancelstnum}
\lst@AddToHook{ExitVars}
{\global\advance\c@lstnumber\lst@advancelstnum}
\AtBeginDocument{%
@@ -1440,20 +1433,23 @@
\let\lst@frametshape\@empty
\let\lst@framershape\@empty
\let\lst@framebshape\@empty
- \let\lst@framelshape\@empty}
+ \let\lst@framelshape\@empty
+ \let\lst@bkgcolor\@empty}
\gdef\lst@frameMakeBoxV#1#2#3{%
\setbox#1\hbox{%
\color@begingroup \lst@rulecolor
+ \ifx\lst@framelshape\@empty
+ \else
+ \llap{%
+ \lst@frameBlock\lst@fillcolor\lst@frametextsep{#2}{#3}%
+ \kern\lst@framexleftmargin}%
+ \fi
\llap{\setbox\z@\hbox{\vrule\@width\z@\@height#2\@depth#3%
\lst@frameL}%
\rlap{\lst@frameBlock\lst@rulesepcolor{\wd\z@}%
{\ht\z@}{\dp\z@}}%
\box\z@
- \ifx\lst@framelshape\@empty
- \kern\lst@frametextsep\relax
- \else
- \lst@frameBlock\lst@fillcolor\lst@frametextsep{#2}{#3}%
- \fi
+ \kern\lst@frametextsep\relax
\kern\lst@framexleftmargin}%
\rlap{\kern-\lst@framexleftmargin
\@tempdima\linewidth
@@ -1811,7 +1807,7 @@
\lst@Key{stringtest}\relax{}% dummy
\lst@Key{outputpos}\relax{\lst@outputpos#1\relax\relax}
\lst@Key{stringspaces}\relax[t]{\lstKV@SetIf{#1}\lst@ifshowstringspaces}
-\lst@Key{visisblespaces}\relax[t]{\lstKV@SetIf{#1}\lst@ifshowspaces}
+\lst@Key{visiblespaces}\relax[t]{\lstKV@SetIf{#1}\lst@ifshowspaces}
\lst@Key{visibletabs}\relax[t]{\lstKV@SetIf{#1}\lst@ifshowtabs}
\lst@EndAspect
\lst@BeginAspect{fancyvrb}