LaTeX and PRISM: syntax highlighting in the listing environment
Warning: Trying to access array offset on value of type bool in /data/www/freeminded.org/www/wp-content/plugins/wp-latex/wp-latex.php on line 91
Warning: Attempt to read property "url" on bool in /data/www/freeminded.org/www/wp-content/plugins/wp-latex/wp-latex.php on line 77
Warning: Attempt to read property "error" on bool in /data/www/freeminded.org/www/wp-content/plugins/wp-latex/wp-latex.php on line 78
Warning: Attempt to read property "latex" on bool in /data/www/freeminded.org/www/wp-content/plugins/wp-latex/wp-latex.php on line 78
You may be using the PRISM Model Checker for your research. You may also want to put some code in your text, for instance in your PhD thesis. Using and the Listings environment is probably your best bet.
Listings defines many options and supports many languages. Unfortunately, PRISM is not one of them and googling around does not yield any result. In search for a quick-and-dirty solution, here’s what I came up with:
\\lstset{ language={}, caption={model.sm}, label=l:prismmodel, morekeywords={dtmc, const, int, double, module, formula, endmodule} }
A rather simplistic approach, I agree. There must be more people with the same problem. Know a better solution? Let me know in the comments!
There is a similar solution for using lstlisting with PRISM code here:
https://groups.google.com/forum/?fromgroups=#!topic/prismmodelchecker/hTINumpmAv8