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

18
votes
3answers
1k views

Highlighting a .diff file

Is there a way to highlight the syntax of a diff file (i.e. by using the listings package)?
5
votes
2answers
135 views

How can I highlight elements in a matrix?

I'm about to use this diagram to make computing 3x3 determinants clear and easy for my students. I tried to add this picture to my lecture but it's blurred due to the bad quality of the picture. So i ...
3
votes
1answer
29 views

How to make TeXstudio recognize \DeclarePairedDelimiter declaration

I'm using TeXstudio as editor because I think it provides the best features among other software I tried (namely Kile and TeXworks), especially about highlighting, autocompletion and spell checking. ...
2
votes
1answer
22 views

Where is TeXworks' syntax-pattern.txt file (on windows 7)?

I was trying to change my TeXworks editor's background to black, some suggested it is possible to edit this file : ~/.TexWorks/configuration/syntax-pattern.txt but I could not locate this .txt ...
0
votes
1answer
84 views

Highlight text and mathematical expressions with colored background

I'd like to have a function that I can use like a highlighter, both in text and in math mode. I wrote something that works but it's really slow and still causes problems in some situations. Here is ...
1
vote
2answers
203 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 = ...
3
votes
2answers
44 views

Highlight selected references with asterisk

I'm using Biblatex/Biber with the phys style. I would like to highlight selected references in the text with an asterisk, i.e. the number should be marked. A \cite{key1,highlightedkey,key2} should ...
3
votes
2answers
21 views

How to customize a kbordermatrix

To the matrix given below, I would like to add the following two features: A downarrow centered below the text "Column j." Highlight the entry a_{ij}. How might I achieve this? ...
1
vote
1answer
52 views

Highlighting text with ulem package

Consider the following minimal example (taken from this answer): \documentclass{article} \usepackage{color} \usepackage{ulem} \newcommand\hl{\bgroup\markoverwith ...
1
vote
0answers
40 views

How can I highlight something inside a listing? [closed]

I need to call attention to parts of code that don't get highlighted as keywords, strings, etc. inside a listing. I've found a few relevant questions on TeX.SE I and tried to apply the solutions ...
0
votes
2answers
136 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} ...
1
vote
1answer
54 views

gb4e: Highlighting examples

In a presentation of a colleague I saw that his examples were displayed in a filled grey square (he used powerpoint). This impressed me, because it highlighted the examples in a subtle and modest way. ...
10
votes
3answers
431 views

How to highlight tree levels

How can i highlight tree levels to be some thing like that... I've drawn my tree with this code \documentclass[landscape]{article} \usepackage[utf8]{inputenc} \usepackage[T1]{fontenc} ...
2
votes
0answers
57 views

Unhighlighted syntax with listings package

I have some trouble with making documents with syntax highlight. Here is the MWE: \documentclass{article} \usepackage{xcolor} \usepackage{listings} \lstset{% language=[LaTeX]TeX, % I also tried ...
1
vote
0answers
39 views

Box highlighting of text with rounded corners and hyphenation support

I used tcolorbox to highlight text some text in paragraphs, it seems to work smoothly, but it disables text hyphenation, that the highlighted piece fo text cannot be start somwhere at one line and ...
23
votes
3answers
688 views

Visually highlighting symbolic material

I have a diagram in which I need to indicate the difference between symbolic mathematics and English words (potentially to someone who doesn't know about it): Colour works beautifully for making ...
17
votes
5answers
445 views

Highlight every occurrence of a list of words?

In order to revise a draft, and identify related sections, I would like to identify similar words (by color of text, highlight, underline, or otherwise) according to topic. For example, I would like ...
6
votes
2answers
4k views

Is there a good definition for highlighting PHP code in listings?

Does someone have a good definition for highlighting PHP code with the listings package?
5
votes
2answers
207 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
109 views

How can I typeset PowerShell code with the listings package?

I'm currently creating my diploma thesis, and used PowerShell to do some of the described work. I'd like to also put some of this code into the thesis and would therefore like to have syntax ...
4
votes
2answers
2k views

How to color over/underline, or other ways to highlight substituted expressions in proofs?

I desire to "highlight" in equational proofs the expressions that are substituted for or transformed in each successive step. Since an expression may be transformed in both the prior step and the next ...
2
votes
0answers
54 views

Sublimetext highlighting of braces

In SublimeText 3, the syntax highlighting for latex documents in math mode has the following (unexpected?) behavior. Consider the following: \{sometext\} versus \{ sometext\}. The syntax ...
2
votes
0answers
32 views

How to highlight php code in a HTML document and the document itself?

how can I highlight php code in a HTML document and the document itself? Example: <!DOCTYPE html> <html lang="de"> <head> <meta charset="utf-8"> ...
4
votes
3answers
210 views

How to show a filename above a code snippet just like on the arch wiki?

Context I'm writing a tutorial-like document in LaTeX on how to create a certain Linux based device. Part of the effort of recreating the device is writing small pieces of code, in either Bash or ...
2
votes
0answers
104 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
5k 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
3k 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 ...
5
votes
2answers
92 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 ...
3
votes
0answers
40 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
4k 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 ...
8
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
87 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
67 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
144 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
106 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
78 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
87 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
72 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
67 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
133 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
58 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
218 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
120 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
115 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
66 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
125 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?
1
vote
0answers
132 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 ...
39
votes
3answers
36k 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 ...