Browse Source

prettier code formatting in documentation

master
Jonathan Spratte 3 months ago
parent
commit
15efae0ef0
2 changed files with 4 additions and 3 deletions
  1. BIN
      documentation.pdf
  2. 4
    3
      documentation.tex

BIN
documentation.pdf View File


+ 4
- 3
documentation.tex View File

@@ -22,11 +22,12 @@
22 22
 %%   ./listings-extx.py -o example.lst example.c
23 23
 \input{example.lst}
24 24
 
25
+\newcommand\mycode{$\langle$\itshape\aftergroup\mycodeclose}
26
+\newcommand\mycodeclose{$\rangle$}
27
+
25 28
 \lstdefinestyle{regex}
26 29
   {
27
-    escapeinside=<>
28
-    ,escapebegin=$\langle$\begingroup\itshape
29
-    ,escapeend=\endgroup$\rangle$
30
+    ,moredelim=**[is][\mycode]{<}{>}
30 31
     ,otherkeywords={[,],?:,(,),\\A,\\s,\\w}
31 32
     ,keywords=[1]{?:,(,)}
32 33
     ,keywords=[2]{[,]}

Loading…
Cancel
Save