Skip to content

Commit

Permalink
Introduce new dialect [nocomment]modelica for making comments appear …
Browse files Browse the repository at this point in the history
…as normal code
  • Loading branch information
henrikt-ma committed Oct 16, 2020
1 parent d7bafb0 commit 573d450
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions preamble.tex
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,12 @@
basicstyle=\upshape\ttfamily, % Font size for inline code snippets.
}

% Special dialect of Modelica to use when there are URLs appearing outside string literals, to avoid the part
% starting with '//' being treated as comment.
\lstdefinelanguage[nocomment]{modelica}[short]{modelica}{%
commentstyle=\upshape\ttfamily, % Camouflage comments as workaround for not being able to remove rest-of-line comment recognition.
}

% Note: within only a keyword in grammar
\lstdefinelanguage{grammar}{%
basicstyle=\upshape\smallifpdf\ttfamily, % size of fonts used for the code
Expand Down

0 comments on commit 573d450

Please sign in to comment.