Tag Info

New answers tagged

1

Why morekeywords doesn't seem to work Your question stems from a misunderstanding of the morekeywords key. Contrary to what you think, writing \lstset{language=Haskell, morekeywords={fix}} does not alter the definition of listings' Haskell language. That's why the fix identifier is not highlighted in your second listing. How to modify an existing ...


1

Short answer: soul is not compatible with nag. Preferred answer: avoid nag, it does nothing that can't be obtained by using correct style to begin with; avoid soul, too. Longer answer: if you really need both packages \RequirePackage[l2tabu, orthodox]{nag} \documentclass{book} \usepackage{soul} \usepackage{etoolbox} %\usepackage{hyperref} % try with and ...


0

It has been possible to highlight JVM bytecode since v1.3 of listings using the language name of JVMIS (Java Virtual Machine Instruction Set, I believe). It's actually mentioned on that page you linked in the OP.


4

You must pass listings options inside the argument of the listings options key. If you want to change the listings options locally you could pass it through an optional argument (put braces around the argument of moredelim to protect the []): \documentclass[]{scrbook} \usepackage[most]{tcolorbox} \newtcblisting{somebox}[1][]{ listing only, listing ...


4

You can define a new listing language \lstdefinelanguage{mylang} { moredelim=**[is][\color{green}]{@}{@} } and use it inside the listing options of your \newtcblisting \newtcblisting{somebox}{ listing only, listing options={style=tcblatex,language=mylang} } MWE \documentclass[]{scrbook} \usepackage[most]{tcolorbox} ...



Top 50 recent answers are included