{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)

2
votes
0answers
42 views

R-code linebreaks AND themes in knitr

hpesoj626 provides two great minimal working examples for how to get R-code linebreaks AND code highlighting in knitr. I was wondering if it was possible to use Yihui's knitr themes within either of ...
8
votes
1answer
4k views

Beamer: highlighting aligned math with overlay

This question led to a new package: hf-tikz Minimal working example: \documentclass{beamer} \usepackage{amsmath} \begin{document} \begin{frame} \begin{align} a_i + b_j = 10 & ...
19
votes
2answers
2k views

Highlighting in Beamer using TikZ nodes

This question led to a new package: aobs-tikz Is it possible to alter the code in the following MWE to the effect that “ABCD” is visible on both slides but only on the second it has the red ...
3
votes
2answers
45 views

Automatically highlight words from a predefined list

I am not a native English speaker and there are some grammar mistakes I do a lot, especially have/has in conjunction with each/every, and so on. Q: Is there some way to highlight all occurrences of ...
2
votes
0answers
19 views

tikzmark: declare a shape imitating <span> in HTML

Too Long; Didn't Read See the figure. The yellow blocks are actually three nodes. How to improve anchor border? How to place such a node inline? Or, overall, any better mechanism to do so? ...
4
votes
2answers
1k views

Undesirable highlighting of a keyword name (dh) occuring within an identifier (0dh)

I'm using the x86masm dialect of Assembler and register names are emphasized even when they occur inside of a label or a hexadecimal number. For example, dh is register, but 0dh is a number, yet the ...
12
votes
1answer
2k views

How to make \hl (highlighting) to automatically place incompatible commands in \mbox?

The soul package provides a useful command \hl for highlighting text. However, \cite, \ref, and some other commands (maybe equations too) must be placed within an \mbox in order for \hl to work ...
7
votes
3answers
1k views

Red box drawn around question-mark operator in minted Erlang code

I'm trying to include some Erlang code samples in a document using the minted package which include the ? operator to denote a message being received from a process. The code \documentclass{minimal} ...
2
votes
0answers
40 views

Highlighting words with special characters using \hl (soul)

I am using xelatex, polyglossia and the document is in UTF-8 encoding. I use the soul package to highlight words (using soulutf8 makes no difference). The problem is really weird, so I will go ...
4
votes
1answer
55 views

Why highlighting math with soul doesn't combine with l2tabu option for the nag package?

I have found that highlighting mathematical formulas with soul package does not work if the nag package is used with l2tabu option. A minimal (not) working example is: \documentclass{book} ...
6
votes
1answer
110 views

highlighting words which cannot be hyphenated

is there any package which can automatically highlight unhyphenable words in output PDF? I.e. words which are not in the list of words for hyphenation. For example: I'm using polyglossia package. ...
1
vote
0answers
50 views

(Beamer) Highlight node/edge labels using onslide/only

So in my Beamer slides, I'm using this to highlight various parts of a tikz figure on different slides. \documentclass{beamer} \usepackage{tikz} \usetikzlibrary{positioning,automata} ...
0
votes
1answer
51 views

LaTeX interaction with the OCaml toplevel system

I would like to be able to write an OCaml expression inside a LaTeX document, and have it loaded in the OCaml toplevel system, which would compile it and evaluate it. Then both the expression and its ...
2
votes
1answer
48 views

Problems with matrix highlighting in two separate equations using hf-tikz

I have the following 2 matrix. If I do that: \documentclass{article} \usepackage{amsmath} \usepackage[usenames,dvipsnames]{xcolor} \newcommand\x{\times} % requires version 0.3 of the package ...
4
votes
1answer
54 views

Problems with pdfcomments and Unicode characters in XeLaTeX

I'm trying to use the pdfcomment package in XeLaTeX. I can't seem to be able to use Unicode characters such as Czech ň or ě properly in \pdfmarkupcomment. Usually any such trailing characters of the ...
2
votes
1answer
48 views

Multiple underlines with multiple colors

I would like to highlight the text that corresponds to many persons. I think underline is a good highlighting method. But I can put only one color for the underline. \usepackage{soul,xcolor} ...
2
votes
1answer
51 views

Lyx code tag with highlighting for C

I just installed Lyx and when I try to insert the program I observe that there is no syntax highlighting. What is the best way to allow for syntax highlighting in LYX?
0
votes
1answer
43 views

Editor with mode-sensitive syntax highlightning

Is there a text editor with support for the following (somewhat special) syntax highlightning. I want to be able to set a different background color for math mode and for normal mode. (I realize this ...
0
votes
0answers
132 views

Word/rtf to Latex conversion with highlighting?

Similar questions have been asked before, such as Word 2003 to LaTeX converter and How to write in .doc/.odf/.rtf and convert to .tex?. I have a minor specification on them: I would like the ...
6
votes
1answer
92 views

Highlight code with squared brackets

I want to show some .ini file in my work. The ini file works with squared brackets. I try to use \lstdefinelanguage but I can't handle it. That is what I try before and in my understanding it should ...
2
votes
1answer
72 views

Typeset colored terminal output using minted

I need to reproduce the output of a command in a LaTeX document. The command uses ANSI escape codes to produce colored output. I'd like to use minted, but using \inputminted{shell}{coloredoutput} ...
1
vote
0answers
48 views

Highlight indentation level in code listings

I try to highlight the indentation level of some code listings to explain indentation behaviour of my language. My language is whitespace sensitive. Indentation indicates block structure similar to ...
4
votes
1answer
86 views

LaTeX to HTML using htlatex - Background problem

I've been trying to highlight Python code and convert it to HTML. For highlighting I used the minted package since it provided a few styles that I was looking for and I used htlatex for HTML ...
53
votes
6answers
12k views

Syntax Coloring in LaTeX

Is there any way to include Python code in a LaTeX file and automatically color its syntax? Is it possible to do syntax coloring with any other language? If yes what packages can I use to do that?
4
votes
1answer
87 views

Adding Keywords to Existing Language for Listings Package

I would like to add more keywords to an existing language definition so that when I use \begin{lstlisting} ... \end{lstlisting}, the new keywords are highlighted along with the predefined ones. This ...
1
vote
0answers
88 views

TeXShop inverse search highlight color

[EDIT 18 Jan 2015: This has now been fixed in 3.49! Thanks to Richard Koch and company. Copied from http://pages.uoregon.edu/koch/texshop/version.html: Three hidden preferences were added, allowing ...
38
votes
3answers
31k views

What can I use to typeset MATLAB code in my document?

This question led to a new package: matlab-prettifier Does anybody have a quick and easy way to typeset some relatively long MATLAB code in the appendix? I looked up a few methods, and the ...
4
votes
3answers
414 views

How can I highlight text before a character with listing?

All is in the title. I would like to add a color to the text before a character with listing package. For example, I would like to add a color to text between the beginning of a line and : or =, in a ...
1
vote
2answers
270 views

How can I highlight Java bytecode?

I usually use minted to display highlighted source code. But it seems as if minted would not support Java bytecode (see list of supported languages). How can I insert highlighted java bytecode? (Is ...
4
votes
2answers
119 views

Highlight / emphasize a string in tcblisting

How can I emphasize a string in a tcblisting like it is possible with the "moredelim" option in a lstlisting environment? The goal ist to be able to situational epmhasize arbitrary strings in a ...
1
vote
1answer
104 views

How do I highlight a block of source code in LaTeX?

I have many blocks of source code in my document (each of them is at least 40 lines). I would like to format parts of these code blocks, preferably with some annotations on the right. I was thinking ...
6
votes
1answer
335 views

legend problem in highlighting a data plot

I followed the tips on highlighting in data plots at http://www.howtotex.com/tips-tricks/highlighting-in-tikz-plots/ The highlighting does not work well with \addlegendentry. A MWE is shown below. ...
4
votes
1answer
75 views

LESS and SASS source code formatting

I need to add piece of source code in LESS and SASS. Piece of code is divided into two columns. First column is source code in Less and second column in Sass, something like on this page, but without ...
0
votes
1answer
90 views

highlighting RTL text - ulem with bidi and color

following this: http://tex.stackexchange.com/a/48549/22969, I tried this code: \documentclass{article} \usepackage{ulem} \usepackage{xcolor} \usepackage{polyglossia} \setdefaultlanguage{hebrew} ...
0
votes
0answers
46 views

TeXShop is scrolling upwards while pressing cmd

When I press cmd in TeXShop 3.48.1, it scrolls upwards and highlights some text. Is there a way to solve this problem. I've just updated to MacTeX 2014 which did not solve the problem.
3
votes
1answer
72 views

Chess Notation with skak: How to highlight squares?

i'm using the skak-package for some chess notation in a presentation. My only issue: How can i highlight various squares on the chessboard? Basic: \documentclass[12pt]{beamer} \usepackage{skak} ...
2
votes
1answer
278 views

Highlight Row in LaTex [duplicate]

I would like to highlight first row in a table, starts with Date... Here is a screenshot of the table in question:
1
vote
0answers
124 views

listings - highlighting additional keywords inside own delimiters (like Doxygen annotations)

According to listings - use different style for normal comments /* and doxygen comments /** I used listings package to set style for /** Doxygen comments */ as user defined delimiter moredelim = ...
2
votes
1answer
77 views

listings - use different style for normal comments /* and doxygen comments /**

listings package allows setting basicstyle, keywordstyle, identifierstyle, commentstyle, stringstyle. Is it possible to set different style for comments that start from /** not just /*? To make my ...
4
votes
0answers
74 views

Text highlighting that works with CMYK xcolor mode?

I looked at Cool Text Highlighting in LaTeX, and as my MWE (below) demonstrates: ... the first part, highlighted with soul's \hl, fails when [cmyk]{xcolor} is used. The accepted answer in the link ...
22
votes
3answers
7k views

Highlighting table cells

I have a large (13x13) table in which I need to highlight a subset of cells. I know that I can set a background color to those cells using colortbl or xcolor. But I need to highlight the table without ...
37
votes
5answers
2k views

Highlight First Occurrence of a Particular Word

I'm writing a scientific paper, and in this paper, I present a series of new terms. The first time a new term is presented, I would like LaTeX to automatically highlight this - e.g. by using italics ...
5
votes
1answer
80 views

Combine todonotes with mdframed to highlight paragraphs and write notes

I am trying to combine todonotes with mdframed to create a unifying command that allows to write todos and and highlight paragraphs at the same time. The syntax is ...
4
votes
1answer
167 views

Using BW style for minted code highlighting not pure BW

I'm trying to use the minted package with bw style for JavaScript code highlighting. Under the document I added \usemintedstyle{bw} and use highlighting like this: ...
1
vote
0answers
74 views

Minted Listings don't behave the way they should

I'm quite new to La/TeX and I have a question about the 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 well ...
2
votes
1answer
241 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 ...
8
votes
1answer
310 views

How can I automatically highlight SuperCollider symbols and environment variables?

This question led to a new package: sclang-prettifier I've been poring over the listings manual, trying to figure out how to get some very specific types of formatting for the SuperCollider ...
2
votes
0answers
487 views

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

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: ...
1
vote
1answer
174 views

How can I highlight keywords with special characters or numbers in them?

In the following MWE the declared keywords te-st and 999 are not highlighted as expected: \documentclass{scrartcl} \usepackage{listings,xcolor} ...
4
votes
1answer
148 views

Listings with keywords that contain both letters and numbers

I have a listing which needs to highlight keywords with both letters and numbers. Following the advice in this question I've used the otherkeywords to define the keywords which contain numbers. This ...