{highlighting} is about highlighting document elements. Use this tag in addition to other tags specifying what should be highlighted.

learn more… | top users | synonyms (1)

4
votes
0answers
49 views

(Clickable) cross-reference in lstlisting

To generate documentation for an 'application programming interface', I would like to have a syntax highlighted area (with the class declaration), which has clickable links to the documentation (which ...
3
votes
0answers
36 views

Highlighting text for review

I am looking for a way to highlight sections, sentences, etc for review without breaking the paragraphs up. I have tried the package todonotes, but I couldn't get the underlining to work with ...
2
votes
0answers
54 views

How to change (Mac)Vim's syntax highlighting rules for (La)TeX files?

I'm a long-time AUCTeX/Emacs user that switched to Vim/LaTeX-Box recently. I got everything working the way I want and grew pretty fond of Vim, but there's still one unusual thing that bothers me: ...
2
votes
1answer
67 views

How to set different color in listing?

I want to split the listing into three different colors. How to do it? I have read Peter Grill's answer and apply it like this: \documentclass[12pt]{article} \usepackage[utf8]{inputenc} ...
1
vote
0answers
28 views

Minted Listings don't behave the way they should

i'm quite new to la/tex and i have a question about the latex package minted and it's listing feature. i'm using a latex template from someone else who gave it to me. He used the listing feature as ...
6
votes
2answers
65 views

T2A fontshape in verbments listings

I'd like to use T2A fontshape inside verbments listings (for comments in source code), but have no luck in this. For the code \begin{pyglist}[language=haskell] fact n = foldl 1 (*) [1..n] -- так ...
1
vote
0answers
32 views

highlight glossaries entries on page

I want to highlight my glossaries entries with bold or italic formatting. I have used the following command but then the whole document is very colorful what I didn't want to have it like this. ...
14
votes
1answer
220 views

How does minted work from a point of LaTeX-User?

The package minted is one of the most famous package for highlighting source code. But how does it work?
7
votes
2answers
137 views

highlight line numbers in listings

I would like to highlight the line numbers of the lines I refer to with lstlistings. I use escape characters to define labels in my Listing to which I refer later in my document (e.g. see Line X of ...
2
votes
0answers
56 views

How to include program listings in C# with custom font and syntax highlighting in LyX?

I'm rather new to LaTeX and use LyX editor to create my documents. There are similar questions but none of them answer how to do that in LyX. I am wondering, how to include a program listing in ...
1
vote
1answer
36 views

error when using tcolorbox + listings for multipage source

I'm try to highlight source code with colored background, but I face a bit error. first image is created with listings only and that is what I need. You can see on the last image that basicstyle ...
3
votes
1answer
94 views

How can I highlight a keyword that contains a dash or a slash? [duplicate]

I have a Clojure listing and I want to colour certain keywords whereas I can only do for strings not including any dash ('-') or slash ('/). But I also need to consider keywords consisting of with ...
4
votes
1answer
95 views

How can I highlight SPSS Syntax code with the listings package?

I'm writing my master thesis at the moment and I want to add some code listings to the appendix. The code is written in "Syntax", the programming language of SPSS Statistics. Is there a way to ...
2
votes
1answer
58 views

Listings refuses to highlight identifiers such as 'intent–filter'. Why?

I have some xml code, which I want to look fine in my latexdocument. I am doing it this way: \documentclass[12pt]{scrartcl} \usepackage[ngerman]{babel} \usepackage[utf8]{inputenc} ...
7
votes
2answers
70 views

Automatically highlight undefined references

Is there a way to force LaTeX to automatically change the formatting of the ?? that gets typeset in place of an undefined reference? For example, can one make LaTeX draw a yellow "highlight" ...
1
vote
1answer
122 views

How to write the beautiful code as follows

I want to know how to generate the following beautiful code, including fonts, colors, line, and the figure description. I think it is not written by \lstset. This picture is extracted from a paper ...
3
votes
3answers
189 views

How to improve this text highlighting?

I want to highlight some letters which represent an amino acid sequence of a protein using different colors. The below code works fine, but the highlighted box is not fitting exactly the letters, as ...
3
votes
2answers
80 views

Listings problem with quotes in a string

A single quote occuring inside a listings string seems to be interpreted as ending the string. Is there a way to avoid this from happening? \documentclass[12pt]{article} \usepackage[top=0.3in, ...
3
votes
0answers
86 views

How do you best differentiate listings in different programming languages? [closed]

I am currently producing a new edition of an old book of mine; this new book will incorporate code samples from several different computing environments. I can using the listings package quite ...
5
votes
1answer
79 views

Why are my custom settings for listings not taken into account?

I would like some help to get my source code to look correct. The code is supposed to look like this: As you can see, some words should be purple and bold, some should just be bold, some should be ...
4
votes
1answer
87 views

How can I define a custom class of keywords in listings?

How can I define a custom class of keywords in listings? In the C# listing below, keywords, such as using, namespace, etc., get highlighted as desired. However, I would like to define a custom class ...
5
votes
0answers
128 views

How to activate syntax highlighting for multiple references in TexStudio?

I want to enable highlighting for multiple references command \parencites {} of Biblatex package the same as of a similar command for one reference \parencite {} using TexStudio editor. The image ...
4
votes
1answer
120 views

Highlighting of Beamer navigation bar

I have an issue with the highlighting of my navigation bar within a beamer presentation. On my computer monitor the highlighting looks quite good, but i like to have the current element of the ...
1
vote
1answer
45 views

Remove spaces from source code

I have this code (javascript from language option supported in listings) \lstset{language=javascript} \begin{lstlisting} $('#term').terminal(function(command, terminal) { var cmd = ...
0
votes
0answers
27 views

Is there syntax higlighting for javascript in LaTeX? [duplicate]

Is there a listing setting for javascript, or a package that can be used instead?
3
votes
1answer
68 views

Problems with spacing in lstlisting with escaped code

Consider the following code: \documentclass{beamer} \usepackage{listings} \begin{document} \begin{frame}[fragile]{title} \begin{lstlisting}[escapeinside={!*}{*!},] int add int !*\color{red}add*! ...
7
votes
2answers
136 views

Highlighting text through stacked colored underlines

I have sentences in which characters have been "marked" by some people and not by others. I'd like to present the markings simultaneously. Stacked colored underlining (in which a line represents each ...
4
votes
2answers
151 views

Making an unfilled circle including a number in a table

I wonder is it possible to highlight a number enclosing with an unfilled circle next to a line in a listing or table like the image below? \documentclass[english,a4paper,12pt]{report} ...
1
vote
0answers
86 views

Kile syntax highlighting: A single dollar sign in the preamble

I'm using Kile to edit my LaTeX documents. I define my own custom environment to hightlight LaTeX code named lstLaTeX with the following code: \documentclass[a4paper]{scrartcl} ...
3
votes
1answer
241 views

Color highlighting text and environments in LyX

I am using LyX 2.0.5 with document class article and 'Theorems (AMS)' in the modules. I am wondering if it is possible to make it so that the titles of different environments will be highlighted in ...
3
votes
1answer
135 views

Annotating tables

I'm trying to annotate a table by highlighting and annotating the final column, yet once I use the\tabnode together with coloring I get misalignment. Either the content of the cell marked with ...
1
vote
1answer
58 views

Use common latex quotes with csquote in french mode and keeping specific highlight in SublimeText

I'm using Sublime Text3 with Latexing, and i search to know if it's possible to replace automatically during compilation the regular quote for latex ''mytext"" by \enquote{} That seems silly but, a) ...
3
votes
2answers
63 views

Impossible to select text and, then, autoformat it with Emacs+AUCtex

With Emacs+AUCTeX, I was able to select text (with the shortcut CTRL+SPACE) and, then, format this text. For example, it was possible to select a sentence (the text is highlighted) and to press C-c ...
4
votes
1answer
82 views

How to automatically color a string that starts by a specific character (@)?

Using the memoir class, I'm looking for a way to automatically color any string that starts whith an @ character, whether it be in the main text or in a footnote. Any idea how to do that? Update : I ...
2
votes
1answer
117 views

After changing Kate's LaTeX syntax highlighting file, syntax highlighting for LaTeX can not be selected anymore in Kile

I wanted to adapt the Kate LaTeX Syntax Highlighting file (in my case: /usr/share/kde4/apps/katepart/syntax/latex.xml), to have a different highlighting in Kile, as in the answer to disable syntax ...
8
votes
1answer
129 views

How to get more than 3 levels of nesting in mdframed environments?

Before I get to many of "don't do this as it does not look good", I have two modes of my documents: Final mode: where there is ONLY one level of nested mdframed Review mode: where there are numerous ...
4
votes
1answer
226 views

Can the listings package be set up to highlight Prolog code like minted does?

I am interested to know how listings can be customized to mimic the Pygments's Prolog lexer (i.e. make Prolog code represented by listings look the same as it is done with minted) I previously asked ...
3
votes
1answer
51 views

Beamer Frame is displayed wrong

i made a Code for alerting through a frame. It adds an empty (just looks empty very light text) frame in front of the greyed out frame (Picture below). It only appears to add a frame, if i use ...
6
votes
2answers
181 views

How can you highlight a C compiler directive spanning multiple lines?

In my \lstset{...} I have morecomment=[l][{\color[rgb]{0.1, 0.2, 0.8}}]{\#}, which I've seen used to give preprocessor commands colour. This works just fine but I'd like to get multi-line macros to be ...
8
votes
1answer
228 views

How can I automatically highlight SuperCollider symbols and environment variables?

I've been poring over the listings manual, trying to figure out how to get some very specific types of formatting for the SuperCollider language. I need to highlight words where the opening delimiter ...
3
votes
1answer
737 views

Texworks syntax highlighting not working on windows 8 and 8.1

any latex code I want to view in TexWorks 0.4.5 r.1280 (Miktex 2.9) won't show the syntax highlighting. It compiles just fine but everything line is written in black. On very long documents the ...
9
votes
2answers
232 views

Beamer: highlighting text with colored background through which surrounding text can be seen

On some slides I'd like to highlight some text by using a colored background, like so: I've exaggerated the width of the border around the text in this example to indicate the effect I want. I ...
3
votes
1answer
89 views

Highlighting in tabular environment

I am trying highlight a row of matrices in a tabular environment. However, the left brackets of the matrices are gone. And I don't know how to fix this. In addition, how can I highlight 2 elements ...
8
votes
1answer
745 views

How can I highlight YAML code in a pretty way with listings?

I'm trying to highlight simple YAML (the markup language, not the CSS framework) code. I know that there is a solution using pygments and minted, however, I would prefer a solution with ...
0
votes
0answers
83 views

Indented Code Blocks Have no Background Color When Generating PDF

As the title says, when I run: pandoc -o book.pdf book.md The code blocks show up in monotype font but with no background color. I've also tried all styles using --highlight-style with no success. ...
4
votes
1answer
217 views

Change selection color in TeXShop

I'm working with TeXShop (Mac OS) and I want to change the color of text selection. If I want to search for special words with CMD+F, the program highlights the text in a light gray color... Every ...
4
votes
1answer
211 views

tikz node with listing environment

I'm trying to create a c++ class hierarchy. Each node in the hierarchy is a class description with code listing in it and multiple nodes are connected by lines and arrows depicting the hierarchy. I'm ...
3
votes
1answer
83 views

Making comments stand out when using Sweave and R

Is there any way to bold or highlight all comments when using Sweave? Maybe a command to make all lines starting with # be bolded? <<>>= # I want this to be bold automatically @
11
votes
1answer
204 views

How can I typeset LaTeX source code with this very specific syntax highlighting? [closed]

I want to put some LaTeX source code in my PDF output with the style like this: Color in text mode is white, in math mode is yellow and in comments is grey. For control sequences, I divide it into ...
5
votes
1answer
191 views

Code highlighting for imported source files

I have several source code files that I would like to include in my document. I know that I can use verbatiminput to get the lines from the file, and use lstlisting to highlight the code, but I ...