9
votes
3answers
229 views

Is it possible to give colors to big (automatic) parenthesis in math mode?

In the following code I can't make the right parenthesis to have arbitrary colors. \documentclass{article} \usepackage{amsmath} \usepackage{xcolor} \begin{document} \begin{equation} ...
6
votes
4answers
183 views

How to color only a “tilde” accent on a letter? [duplicate]

I would like to color only a "tilde" on my letters. I read how to do this with Umlauts or other accent, but for my expression it seems different I think. Here is my expression : \widetilde{E}^w So, ...
8
votes
3answers
86 views

Spacing for subscripts in mathmode with \textcolor

It is possible to use \textcolor in math-mode; however, it changes the spacing of subscripts. \documentclass{article} \usepackage[usenames]{xcolor} \begin{document} $Y_i$ vs $\textcolor{red}{Y}_i$ vs ...
5
votes
2answers
90 views

How to color equations in TeXify

I am using texify.com to generate images of equations, so that I can put them in emails. I am trying to insert a colored equation, using the following code: {\color{green} dy} = {\color{red} ...
4
votes
2answers
108 views

color block of text without repeatedly using /textcolor

I want to color the answers into blue however my current solution is not really viable as each line needs to be colored blue individually due to my use of \par\bigskip messes up \textcolor if its in ...
5
votes
1answer
127 views

Problem with spacing after \[…\] environment when using the \textcolor{} command

I'm getting odd spacing/indentation behavior when the \textcolor command is combined with the \[ ... \] environment. I did find a fix by putting % in a couple places, as outlined below, but I'd like ...
7
votes
2answers
225 views

Color fraction bar

What would be the easiest way to create a fraction whose bar can be coloured as desired? I know one can use the \genfrac{left-delim}{right-delim}{thickness}{mathstyle}{numerator}{denominator} command ...
4
votes
2answers
118 views

How to colorize escaped math in syntax highlighted listings?

my listings are syntax highlighted using \lstset with escapechar=$ and commentstyle=\color[rgb]{0,0.5,0}. Now my C-code looks like int16_t speed; // calculated speed in $\(\frac{cm}{s}\)$ and the ...
3
votes
0answers
29 views

Restore standard horizontal spacing for colored symbols in mathmode [duplicate]

I have to highlight some symbols in red, something like this: \documentclass{article} \begin{document} $2+2+2=6 \textcolor{red}{\to} 4+2=6$ \end{document} However the colored formula horizontal ...
1
vote
1answer
192 views

Changing align environment tag styles and colors [duplicate]

I'm using amsmath and amsfonts to typeset my homework, and since it will be read on a screen, I would like to make \tag{comments inside equations} differently colored, and optimally downsize them by a ...
5
votes
1answer
571 views

Set math fonts to predefined color

I am trying to define math text is some predefined color as in my preamble: \setbeamercolor{math text}{pmsGreen} \everymath{\color{pmsGreen}} \everydisplay{\relax \ifx \\\@eqncr \else ...
1
vote
1answer
103 views

Assigning different colors to numerical values below a certain parameter?

I'm relatively new to Latex so apologies for any stupidity upcoming. I'm trying to read a Matlab vector into a latex table with values ranging between 0 and 1. For the values less than 0.1, I want ...
10
votes
3answers
269 views

Defining a macro for “real” colored delimiters

I recently looked up J. van Hoorn's question on How to color delimiters in Math Mode, and so I decided to test my LaTeX knowledge by trying to define a new appropriate command: ...
3
votes
0answers
644 views

Texmaker. Color in the editor. Math mode [closed]

I am starting to use Texmaker with the default configuration. When I use the math mode ($...$) all of it is coloured in green in the editor, making long formulas difficult to follow. I would like ...
4
votes
1answer
120 views

Matching Brackets in TeX output

Is there any ways or features to make pdf-files using one of TeX systems so that when I move the cursor to one of brackets (either open or closed brackets) in pdf, then the bracket and the other ...
2
votes
0answers
740 views

Is it possible to reorganize coloring/highlighting priority in Texmaker? [closed]

I want to be able to see latex commands in Texmaker while in mathmode, but the settings file does not seem to account for priority via line rearrangement, so I was wondering if there was a way to make ...
8
votes
2answers
282 views

How can I use color in a mathematical expression without losing horizontal spacing?

How can I use color in a mathematical expression without losing horizontal spacing? \documentclass{article} \usepackage{xcolor} \definecolor{red}{HTML}{dd0000} \begin{document} \[3+(-5)-2+3\] ...
4
votes
1answer
130 views

Re-color alphabets in mathmode

In user700902's answer to this thread, the following code is suggested to color alphabets A-Z green: \makeatletter \def\colorizemath #1#2{% \expandafter\mathchardef\csname ...
8
votes
2answers
1k views

LaTeX color setting for math mode

I'm wondering if it's possible to do something like this in LaTeX: For all numbers (0, 1, ..., 9) in math mode, color it red. For alphabets (a, b, ..., z, A, B, ..., Z) in math mode, color it green. ...
4
votes
2answers
185 views

Colored “sum” in display math mode

The line \[ \textcolor{green}{\sum}_{k=0}^n \] makes the k=0 and n parts go to the right of Sigma instead of at the top and bottom, as it should be. Can we retain k=0 and n at the top and bottom?
13
votes
1answer
325 views

\everymath and author color

Consider the following example: \documentclass[11pt]{paper} \usepackage[usenames]{color} \definecolor{foo}{rgb}{0.75,0.0,0.0} \everymath{\color{foo}} \title{something} \author{someone} ...
2
votes
1answer
64 views

Automate replacement of `\not` when in `\bm` mode

Hendrik Vogt has provided a \longnot macro to alleviate the issues related to Interaction of \boldmath and \not. This seems to work fine, but I run into a snag when I try to automatically use ...
7
votes
1answer
138 views

How to change only the color of curly brace made by \underbrace but keep the content color remain unchanged?

I have to set globally the color of every math to blue. However, if I need to annotate an expression by using \underbrace, the curly brace must be in black (for example). The following are my MWE and ...
10
votes
1answer
392 views

Interaction of \boldmath and \not

It seems that using \boldmath (or \bm) along with the \not does not quite work so well. Here is an example using \not\subseteq and \not\le where the line representing negation does not stretch ...
3
votes
1answer
2k views

Changing color of text snippet in a verbatim environment

Is it possible to change color of part of the text that is in a verbatim environment? Lets say I have this verbatim section. I want to change the color of the marked lines into blue. ...
11
votes
1answer
366 views

Changed all math text to red in beamer, now I can't make some math text black

When I try to make the checkmark black using the following code, it doesn't work; the checkmark shows up red. How do I make it black? \documentclass{beamer} \usepackage{amsmath, amsthm, amssymb, ...
11
votes
3answers
185 views

Distinguish math symbols in the language and the meta-language

I'm writing some notes on logic and formal languages, and I would like to provide some visual cues to distinguish symbols in the formal language (e.g. predicate and logic symbols), from symbols in the ...
16
votes
1answer
2k views

Colored symbols

First of all, I apologize if this is a repetitive question. I searched, but couldn't find it. I was wondering if I can change the color of symbols in latex. For example \ast always give me a black ...
2
votes
1answer
1k views

Overline in text mode, Background Color

I've got the following code below to mimic a TI83 Calculator screen, but I'm stuck on adding a couple of things I'd like to add. I'd like to make the \overline{x} in text mode. I tried \={x}, and ...
4
votes
2answers
635 views

How to highlight math environments with colored background?

How to highlight maths environments (in-line mode excluded) with a coloured rectangular background e.g. grey? A \textwidth rectangular behind the \begin{equation} environment.
8
votes
1answer
177 views

Is there a way to color (only real) math in pdflatex?

I'd like to change the color of all math in my document. I understand that several packages and some engines provide support for changing the color of all math, and I understand that something like ...
10
votes
3answers
337 views

How to color just the `\vec` symbol?

How do I color only the vector symbol in \vec f? I'm using beamer, so xcolor is already loaded. Extra "points" to an answer that also explains how to fish..and not only gives me the fish. Thanks!
1
vote
1answer
319 views

Different default color for each font in ConTeXt

Is there a way to specify the color along with the font name when using simplefonts? At the moment, I use the following to setup my default fonts. \usemodule[simplefonts] \setmainfont[Ubuntu] ...
9
votes
2answers
1k views

How to change color of some particular environment for entire document

I want to change color of particular environment in document. For example wherever I found verbatim environment or equation environment appears in my tex file. With some global settings, I want to ...
3
votes
2answers
531 views

Changing colors of MATH functions and DRAWING lines

My problem is that I want my math functions and drawing illustrations to be in different colors. I want my colors to be defined at the beginning so they will automatically change the color of math and ...
7
votes
1answer
1k views

Coloured math in beamer

I have a question: Is there any way to have math (everything between $s) in different colour than text (for example, green) in beamer?
14
votes
2answers
1k views

How do I get different colors for math and for text?

I want to include something in my LaTeX article that will make all mathematical formulae appear in black, while all text (including everything inside \text{}s in the middle of mathematical formulae) ...
9
votes
1answer
167 views

Is there a package to differently color nested expressions in the output?

Say I have an expressions like $(\sin(x-3(z^{(x-2)^2}))+1)^2$ with many nested expressions. To better visualize this in the output (and to help finding missing delimiters when proof-reading) I'd like ...
26
votes
1answer
26k views

How to color math symbols?

One can use the command such as \textcolor[rgb]{1.00,0.00,0.00}{boundary} to color the word "boundary" in a document. Here is my question: How to color the math symbols in $$? For example, can one ...
16
votes
5answers
5k views

Color underline a formula

I want to underline different parts of a formula with different colors. What is the best possible option? Soul seems only to provide one color per document.