Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- documentclass[12pt,oneside,a4paper,openright]{report}
- usepackage[utf8]{inputenc}
- usepackage[T1]{fontenc}
- usepackage[sc]{mathpazo}
- usepackage[utf8]{inputenc}
- usepackage[danish, english]{babel}
- usepackage{xcolor}
- usepackage{graphicx}
- % Colors for Code
- definecolor{grayC}{RGB}{250,250,250}
- definecolor{Dgray}{RGB}{200,200,200}
- definecolor{bluekeywords}{rgb}{0,0,1}
- definecolor{greencomments}{rgb}{0,0.5,0}
- definecolor{redstrings}{rgb}{0.64,0.08,0.08}
- definecolor{xmlcomments}{rgb}{0.5,0.5,0.5}
- definecolor{types}{rgb}{0.17,0.57,0.68}
- usepackage{listings}
- lstset{
- literate= {Ø}{{O}}1 {Æ}{{AE}}1 {Å}{{AA}}1
- }
- lstdefinelanguage{BABs} {
- alsoletter={O,AE,AA},
- morekeywords={
- HVIS,
- GØR,
- FÆRDIG,
- ER,
- IKKE,
- OG,
- ELLER,
- GENTAG,
- OPDATER,
- TABEL,
- RÆKKE,
- VIS,
- INDLÆS,
- SANDHEDSVÆRDI,
- TEKST,
- DECIMALTAL,
- HELTAL,
- SAND,
- FALSK
- },
- sensitive = false, % No case sensitivity of keywords
- morecomment = [s]{#}{#}, % Comment with start and end
- morestring = [b]" % Strings are enclosed with "
- }
- % Some additional settings for BABs
- lstset{language=BABs,
- backgroundcolor=color{grayC},
- basicstyle=ttfamilysmall,
- breakatwhitespace=false,
- breaklines=true,
- commentstyle=color{greencomments},
- deletekeywords={...},
- escapeinside={(*@}{@*)},
- extendedchars=true,
- frame=single,
- keepspaces=true,
- keywordstyle=color{bluekeywords},
- numbers=left,
- numbersep=5pt,
- numberstyle=tinycolor{black},
- rulecolor=color{Dgray},
- showspaces=false,
- showstringspaces=false,
- showtabs=false,
- stepnumber=1,
- stringstyle=color{redstrings},
- tabsize=2
- }
- begin{document}
- This is a test to show that lstinline[language=BABs]|GØR{<Stmts>}| and lstinline[language=BABs]{FÆRDIG} are not properly highlighted, however lstinline[language=BABs]{HVIS(<BoolExpr>)} is.
- end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement