{color} is about using color in (La)TeX documents. Popular packages are color and xcolor.

learn more… | top users | synonyms (1)

4
votes
1answer
26 views

Misplaced noalign when using rowcolor

I am trying to create a table with colored rows and colored hrules between the rows, but I am getting a "Misplaced \noalign. \rowcolor" error. The following example reproduces this problem: ...
3
votes
1answer
27 views

How to color just the section numbers in the Toc in the tufte-book class?

This is a follow-up question to How to color section numbers in the TOC? How to adopt the answers in the link above to work in the tufte-book class? here is my MWE: ...
4
votes
2answers
80 views

How to color section numbers in the TOC?

In the following MWE, how can I color just section numbers in the TOC? \documentclass[a4paper]{book} \usepackage{color} \makeatletter \renewcommand*\l@section{\@dottedtocline{1}{0em}{2.3em}} ...
6
votes
1answer
35 views

Beamer color doesn't match

I am trying to get the color R0, G130, B202 into beamer. It should look like this: But the following Beamer document: \documentclass{beamer} \definecolor{PMSProcessBlue}{rgb}{0,130,202} ...
3
votes
1answer
39 views

How to make a layout with colored boxes around sections

I am trying to reproduce the following layout with latex: Is there any package or document class made for such a layout? The example is made in word using tables. But I think using tables in latex ...
0
votes
0answers
11 views

Coloring citations in the text

(possible duplicate) hi, i try to color my citations using hyperref package. here is my preamble: \usepackage{geometry} \usepackage{setspace,scrextend,sectsty,microtype,endnotes,xcolor} ...
2
votes
1answer
50 views

How to color an semiplane delimited by one axis?

In my code below I made an complex plane with the real axis and imaginary axis CODE: \documentclass{article} \usepackage[brazilian]{babel} \usepackage{tikz} \begin{document} ...
0
votes
1answer
23 views

Annotate row and column highlighted in one table with different color by Tikzmark in Beamer

I found example for row only here: Annotate the table row highlighted by Tikzmark in Beamer Also found example for column only here: Annotate the table column highlighted by Tikzmark in Beamer but ...
0
votes
1answer
27 views

Set color of \emph{} in beamer

How can I set the color of the \emph{}-tag in beamer? I tried something like \setbeamercolor{emph}{fg=red} inside of beamercolortheme.sty but it had no effect.
3
votes
1answer
27 views

How to increase background color of a node to input text

Obviously I need a background color for the rightsided text. Code is from the Tantau manual, p.45. It's a riddle for me at the time. Something wrong with the node which keeps the text? For any answer ...
4
votes
1answer
29 views

Single character keywords/operators with no spaces with listings package

I want to add a very simple macro language to listings. It uses single-letter keywords/operators, with no whitespace between. I can't see how to make keywords that don't require some kind of separator ...
5
votes
5answers
147 views

How to style href's (underlined and coloured) throughout the document

Let's take the following MWE: \documentclass{article} \usepackage{hyperref,xcolor} \begin{document} \href{http://any-URL}{\color{blue}{\underline{Some URL}}} \end{document} Let's assume I would ...
5
votes
1answer
78 views

Beamer: How to use “beamercolor” in a tikz picture

How might it be possible to change the font color of a tikzpicture element to the value of a particular beamercolor, e.g. block title?-- For example: \documentclass{beamer} \usepackage{tikz} ...
1
vote
1answer
51 views

How can I color one cell of a table using a tikzpicture?

I want to draw a table, and color one cell in another color. As I'm not that experienced in latex, I found this example: \usepackage{tikz} \usetikzlibrary{calc,matrix} \usepackage{amsthm} ...
0
votes
3answers
39 views

LaTex - Change color of section

I want to change the color of a single section, and that color must not be changed in Table of Contents. \subsubsection{{\color{red} Embedded Design}} This is the code I used, but the color will ...
0
votes
0answers
25 views

Column color overwrites hline in array

Please help. Why does color column overwrite just the second \hline? How do I rewrite it? \begin{document} $$P=\left[ ...
2
votes
1answer
32 views

Overwrite point meta value after explicit definition

I want do some surface/mesh plots in pgfplots with a kind of logarithmic axis for positive and negative values. This is sometimes called a symlog colormap transformation, i.e. a logarithmic axis for ...
0
votes
0answers
12 views

How to read a beamer color from the theme? [duplicate]

I want to put some tikz drawings into my beamer slides. I would like to colour the things in the tikz drawing the same as other things in the slide. For example, I want to fill in a box with the ...
1
vote
1answer
37 views

Beamer - numerating theorems and color of block

Why won't it numerate my newly defined theorem block. And can i change the color of the block? \documentclass{beamer} \newtheorem{teorem}{Teorem}[section] \newtheorem{definicija}{Definicija}[section] ...
0
votes
1answer
44 views

Specify Color for autoref Without Affecting Other Document Links

I am creating a document to be used by people not familiar with TeX. I am using the autoref command throughout the document to refer to tables, figures, etc. I would like to clearly signal to my ...
0
votes
0answers
26 views

Change font background color in custom url command

I want to change the background color of a custom url command. I did not find how to. For now I use : \DeclareUrlCommand\myCustomUrl{\def\UrlFont{\ttfamily\color{green}}} But this only change the ...
4
votes
1answer
53 views

Choose color based on value for Kpi reporting

I trying to make a report containing colored spheres that should be wrapped in a command and updated dynamically. I have defined af colored sphere that receives a color, a value and a text. The color ...
1
vote
1answer
33 views

change the color of the footer in the first page of the fancy

I am using this to change the color of the headers and footer of the chapter pages in the fancy page style, which I got from another post. \usepackage{etoolbox} \makeatletter ...
17
votes
3answers
549 views

Why does xcolor lighten a color when mixed

I'm trying to create a smooth gradient between cyan and blue connecting two shapes, one drawn in cyan and one in blue. For that I use a simple mix of the two colors in a \foreach loop. However, in ...
1
vote
0answers
15 views

Colouring in-line text within verbatim environment

I wish colour some selected text within the verbatim environment. These texts may not occupy a whole line, but rather be a small part of a line. An illustration is given below. Say for example, in ...
0
votes
2answers
64 views

Customized table

How can I create a table like the following? \begin {table}[H] \caption {Table Title} \label{tab:title} \begin{center} \begin{tabular}{|c|c|c|c|} \hline \multirow{2}{*}{A} & ...
2
votes
1answer
50 views

Transparent table cell color

I have a simple table \documentclass{article} \usepackage[table]{xcolor} \usepackage{adjustbox} \usepackage{booktabs} \begin{document} \begin{table} \rowcolors{2}{}{gray!10} \centering ...
1
vote
1answer
43 views

Asymptote (XeLaTeX): Use custom-defined colors/Call drawing functions from external file

I'm quite new to Asymptote, although it's great to manipulate vector graphics within LaTeX. Specifically, I'm using XeLaTeX. What I'm trying to do is to change the color of a vector graphic to ...
3
votes
0answers
25 views

How to change this to color map? [duplicate]

Sorry if this question is too basic. I have the following, \documentclass[tikz]{standalone} \usepackage{pgfplots, filecontents} \begin{filecontents*}{h.dat} 0 0 0.0659197583889 1 0 ...
1
vote
1answer
37 views

LyX: How to change color of an individual Shaded Background Box?

I can change it globally by going to Document -> Settings -> Colors: Shaded boxes. However, what if I want different boxes to have different colors? For example, in my case, by default I set the ...
3
votes
1answer
27 views

Command for both bold and colored text

Every time I want a bold text, I want it colored blue. Currently, I am using: \textcolor{blue}{\textbf{some bold and colored text}} To save time, I can define a command to do both at once. How can ...
1
vote
1answer
73 views

How to mimic cards generated by passwordcard.org?

Assuming we have generated contents of card (i.e. excluding top header row and left indexing column) , for eg. with some pseudo-random generator script. How to render such to mimic the look of one ...
3
votes
1answer
78 views

Create a chapter with different style, using Tufte book

I'm finishing a book using Tufte-Style Book (b5paper,twoside,justified). I just arrived at the last chapter (10th) and want it to be different from the previous 9, as it contains different information ...
0
votes
0answers
25 views

citation color and table color of contents are unusual when using MacTex2015

when I use "latexmk -xelatex thesis.tex" to compile thesis.tex, the process always be paused twice with the messages below: (/usr/local/texlive/2015/texmf-dist/tex/latex/trimspaces/trimspaces.sty)) ...
2
votes
1answer
89 views

Color correspondance in tikz and pyplot

I draw a graph with pyplot, which I save in pdf format. I then want to draw a line with the same color in tikz, however colors mismatch. I get this result: I create my graph with: #!/usr/bin/env ...
1
vote
1answer
34 views

insert small colored box to the left of a moderncv subsection without using \hspace

I have this code: \documentclass{moderncv} \usepackage{fontspec} \firstname{test} \familyname{test} \moderncvstyle{casual} \moderncvcolor{blue} ...
1
vote
1answer
17 views

Incompatibility with align and table option in xcolor?

Let's see this MWE, painfully reduced from an institution template. It chokes on the align environment, unless I comment out the table option in the xcolor package. I would like to understand why... ...
2
votes
1answer
15 views

Setting background color to text in ConTeXt (Mark IV)

I need to highlight some text in ConTeXt to get something like this: Concerning background colors, all I've found in the manual is some example with \framed command, which is inappropriate to me ...
1
vote
1answer
26 views

! Package xcolor Error: Undefined color `RED'. Only affecting one chapter [duplicate]

I am using the document class book and this error started popping up, It is only affecting one chapter, the others I can use the colour red fine. The line is: \section{\color{red}Section Title} ...
0
votes
0answers
30 views

Latex lstlisting: stringstyle not working

I defined my own language Drools and I want that the words between "" have the color red. I used stringstyle to do that but this doesn't work. Am I forgetting something because I couldn't find any ...
2
votes
2answers
62 views

Macro: compatibility of 1) Auto-colorization & 2) Auto-counter-and-title-to-label

This question is about asking to have the following 2 "workflows" (if you permit me to call them as such) to be able to coexist together in 1 Tex document: Workflow Auto-colorization (≅ User ...
0
votes
0answers
41 views

Set the color to the sides of cylinder and exterior ring/hollow cylinder

I'm a newbee to tikz and from tex.stackexchange.com I tried a lot of resources. But I didn't get the initial help to solve my problem by myself. Maybe you can help me. Here is my problem: I want to ...
2
votes
1answer
28 views

Is there a TeXShop Macro to make selected typeset text a certain color?

Suppose I have the following code snippet in my *.tex document (src ;-) ): Dolorem ipsum color sit amet. I'd love to be able to select part of that text (e.g. color), do something quick and ...
2
votes
1answer
17 views

Package xcolor warning when using sciposter document class

Is there anyway to avoid the warning message "Package xcolor Warning: Incompatible color definition on input line" when using the Sciposter document class? MWE: \documentclass{sciposter} ...
2
votes
0answers
18 views

Ensure black/white pages are recognized as such by printer

How can I ensure that the pages I print in black and white with pdflatex are recognized as black and white by a printer in my PDF and not as mixed from CMYK colors? My question arises because my ...
4
votes
1answer
59 views

In-place calculation of color with tikz and calc

Is it possible to calculate a color value like this in-place with tikz and its calc library? \filldraw[fill=black!{50-95.7/2},draw=black] (1,0) rectangle (2,1); %Gives a 'Missing number, treated as ...
4
votes
2answers
125 views

Automatically colourize all occurrences of certain strings (different colouring for different sets of words)

This question is a follow-up of Macro: Replace all occurrences of a word, but I would like the same for different colours, that is to have different pre-defined sets of text strings which will be ...
2
votes
0answers
34 views

Automatically colour previously defined strings of text (for strings with spaces &/or punctuations) [duplicate]

Main question Answers to the question Automatically colour previously defined strings of text show how to colour pre-defined strings of text, but all those pre-defined strings are without spaces and ...
4
votes
2answers
184 views

Is there a way to set colors of hyperref links and urls differently in headings / sections than in the body?

I know hypersetup from hyperref needs to be added before \begin{document} but after \usepackage{hyperref} and \usepackage{bookmark}. For example, you can inject it like the following to ensure this: ...
1
vote
0answers
19 views

texmaker commenting in math mode colors

Can you set the color of comments in math mode to be grey like normal comments? For instance \begin{array}{cl} \min & \tr XBX^T \\ \text{s.t.} & |Xe-2e|^2=0, \\ & ...