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

learn more… | top users | synonyms (1)

2
votes
1answer
975 views

Draw red box around verse

This is a follow-up question to: How to center a verse horizontally I am using the solution given by @Herbert. Is there a way to put a color box around selected few verses I desire?
3
votes
1answer
716 views

Filling complex figures with color

I wonder if there is any method available in LaTeX to fill complex figures. There are few methods for filling figures: even-odd rule algorithm, winding number algorithm. According to these algorithms, ...
2
votes
1answer
795 views

Filling polygons with color

Is there any good tutorial/approach in LaTeX for drawing polygons filled with color? EDIT: I would like to use pdfLaTeX interpreter
5
votes
2answers
793 views

Colored text with dcolumn

I want to typeset a table where certain numbers are going to appear red. In order to achieve the correct alignment I am using the dcolumn package. The problem is that the parsing that dcolumn does, ...
0
votes
1answer
272 views

Different color display between Adobe Reader and Yap

Today I have been realized some drawings for my scientific article using PGF. After converting the DVI to the PDF file I have noticed that my grid which has been supposed to be gray was somewhat ...
5
votes
2answers
1k views

PGF/TikZ Clipping & Drawing: How to customize lines?

I have gotten some undesirable behavior with PGF/TikZ related to clipping and drawing paths with different color, say gray. So I tried with no success to exchange between \clip[draw=gray], ...
4
votes
1answer
1k views

Setting colour of beamer itemize bullet depending on alert mode

I know how to globally set the colour of beamer's itemize bullets. I've defined my own symbols for them and I'd like to colour them in \alert mode. (At the moment only the colour of the text changes, ...
5
votes
1answer
1k views

How to avoid \cellcolor overflowing when changing the space in the column?

I reduced the space in the columns through the use of @{} in the column type: \newcolumntype{M}{@{}c@{}} The problem is that, when I combined this with the \cellcolor command, it overflows into the ...
31
votes
3answers
3k views

Parametrize shading in table through TikZ

I wanted to do some shading in a table according to its values. For example, if you see the table below: a b c d a 90 10 0 0 b 0 80 10 10 c 0 0 95 5 d 0 10 5 85 I want to ...
34
votes
5answers
26k views

What colors are good to use for graphs and figures in scientific publications that print well in black and white?

This question is not TeX specific. When creating scientific documents with graphs and figures, what colors are good to use such that they help the reader understand the figure but will also print well ...
3
votes
1answer
1k views

Using “listings” package to colorize the source code of ANTLR grammar file?

I use listings package in my diploma thesis for source code. Besides the mainstream languages like Java and C# I also need to include the sources of the language grammars (.g) which are pure mark-up ...
22
votes
1answer
1k views

Defining a Color using another

I know how to define a color using \definecolor with literals to describe the color. How can I define a color using an already defined color? In other words: How can I make a color accessible under ...
10
votes
3answers
2k views

Tikz fit-library vs fill (overlaying nested node colors)

I am trying to figure out the best way of nesting tikz nodes having a different background color. I would like the "inner" nodes to "win" concerning the background color. Currently the "outer" node ...
6
votes
2answers
7k views

Beamer title font color

I would like to use the title color of my beamer presentation (some kind of blue) to write some inline text with the same color. Therefore I want to know the color definition. Is there a command for ...
5
votes
1answer
1k views

beamer: shading the block environment

I want the block environment to be shaded in blue, because now it is hardly noticeable. The LaTeX code I'm using is \documentclass[10pt]{beamer} \mode<beamer>{% \usetheme[hideothersubsections, ...
12
votes
1answer
1k views

Why is it that coloring in soul in beamer is not visible

\documentclass{beamer} \usepackage{soul,color} \begin{document} \begin{frame} \hl{Hello World} \end{frame} \end{document} I process this with pdflatex and I do not see the expected highlight. ...
49
votes
4answers
7k views

Does anybody know a good source of (free) ornaments, decorations, frames, backgrounds etc.?

I'd like to prepare a "fancy" typographical project, more interesting visually than a "boring" black-on-white text. I'm not very talented at drawing, though, so I'd like to ask about a place to find ...
3
votes
2answers
627 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
5k views

Multicolumn overrules rowcolors

I am trying to create a table with alternating rowcolors. This works fine in itself with a command like: \rowcolors{1}{gray!20}{white} However, from here it gets a bit more complex. Since the last ...
11
votes
3answers
3k views

Pattern color differs from normal color?

I have the following code: \documentclass{minimal} \usepackage{tikz} \usetikzlibrary{scopes,patterns,intersections,calc} \begin{document} \begin{tikzpicture}[thick] \path (-2,0) coordinate ...
33
votes
2answers
29k views

How to change line color in tabular?

How can I change the color of the lines (the frame) in a tabular environment? In the following MWE: \begin{tabular}{c|c|c} a&b&c \\ \hline d&e&f \\ \hline g&h&i \end{tabular} ...
12
votes
2answers
3k views

Invert Background and Text Colours across Whole Document with pdflatex

When using pdflatex is there a simple way to invert the colors to give white text on a black background across the whole document? I'd like the colours to be inverted whilst I write and edit the ...
4
votes
1answer
1k views

How to color digits with the listings package

For my project, I've been using the listings package in order to color the keywords, comments, strings, and digits in the code. The thing is, I've managed to color the keywords, comments and strings, ...
0
votes
1answer
2k views

Colored Small Caps [duplicate]

Possible Duplicate: Small Caps and Bold Face I'm trying to get some bold, colored, small-cap text. I've tried different variations, including: {\bf \textcolor{blue}{\textsc{text}}} and ...
8
votes
1answer
2k views

Strange behaviour of titlesec, with colored titlerule

With the following MWE, i get the Section title underlined in black : \documentclass[12pt]{article} \usepackage[explicit]{titlesec} \usepackage[dvipsnames]{xcolor} \titleformat{\section}% ...
8
votes
5answers
5k views

Giving headlines a background color spanning across the entire typearea

I posted this at stackoverflow and got redirected here. This does indeed look like a better place to ask. I would like to decorate my headlines (section, subsection, etc.) by adding a background ...
10
votes
1answer
1k views

Is it possible to have multiple paragraphs inside a multicolumn using xcolor or a replacement?

I am getting information written by users in many lines, paragraphs, and I have to put those inside a table, I would like to know if it is possible to instruct LaTeX to accept paragraphs inside a ...
7
votes
1answer
909 views

How to prevent a page break between section title and colored rule?

I use \usepackage[explicit]{titlesec} to customize the design of my sections, subsections... In particular, i have : \titleformat{\section}% {\large\sffamily\bfseries}% {My Section \arabic{section} ...
1
vote
1answer
484 views

Colored sectioning - headings

I am working on some project in pdflatex. I am not an expert in this so I really need your help :). Well what I am trying to do: I (or somebody) will make some common .tex file (with some text) with ...
1
vote
2answers
1k views

Changing background color of external pdf files using pdfpages

The following TeX code is intended to change the background color of an external pdf file by using the pdfpages package, but it does not work for me. Does it work at all? \documentclass{minimal} ...
9
votes
2answers
2k views

Background color for fancyvrb

For reasons unclear to me, fancyvrb doesn't have a background option. However, the minted package, which it is based on, has one, which suggests it should not be too difficult to add. The relevant ...
2
votes
2answers
169 views

Smaller font sizes in boitecoloriee environment gives bad result

The boites package defines environments that allow page breaks inside framed boxes whose edges may be variously fancy. The bundle includes a few examples (shaded box, box with a wavy line on its side, ...
3
votes
1answer
2k views

Undefined color error for URL, when compiling with XeLaTeX

I've defined a different color for hyperlink using \hypersetup command with urlcolor. When I am compiling it with XeLaTeX I am getting undefined color error for the URL link, but it works fine when I ...
13
votes
1answer
2k views

Glossary link's color

How can I change the color of glossary links when using glossaries along with hyperref? I just want to change glossary link colors not all links.
5
votes
1answer
299 views

Error “Dimension too large” (\@tempdima) when using HTML color 097054 with beamer's \setbeamercovered{transparent} option

The code \documentclass{beamer} \mode<presentation>{\setbeamercovered{transparent}} \begin{document} \begin{frame} \onslide<2>{\textcolor[HTML]{097054}{foo}} \end{frame} ...
19
votes
1answer
1k views

Caption parbox 6.0 pt too wide

For my listings, I use this caption setup: \usepackage{caption} \DeclareCaptionFont{white}{\color{white}} \DeclareCaptionFormat{listing}{\colorbox{gray}{\parbox{\textwidth}{#1#2#3}}} ...
3
votes
1answer
139 views

Changing the color of the typeblock by changing the color of the text

Admittedly a looooooong shot... We're all taught that one of the prime objectives of typesetting is providing a uniform typeblock color (ie. the proportion of ink / no-ink on a page) as that is ...
20
votes
1answer
8k views

Colors and legend in groupplots/barplot

In order to compare three items I use the groupplot command. For each item I have n different criteria to compare. Is it possible to set the color for each criteria itself? Meaning the first bar in ...
3
votes
2answers
337 views

Having all one single line with black background and text in white

I want to have one line of text with black background and the text in white. The line is alone and so it can be one paragraph. I would like the coloration for the full width of the line and not only ...
8
votes
2answers
2k 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?
17
votes
2answers
2k 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) ...
5
votes
2answers
1k views

How to mark whole line or part of line with background color in a listing (listings package)?

I want to highlight either a whole line of code in a listing, or a part of line (a subexpression) using background color (to not interfere with syntax highlighting). I use lstlistings environment ...
10
votes
3answers
1k views

How can I ensure all teletype/monospaced text is in a certain color?

I'm trying to include some monospaced text, and I'd like it to be in a different color than the normal text. There will be several (read: hundreds) of instances of monospaced text, and I want it all ...
8
votes
2answers
431 views

Define a no-op color name which is always the current color

Using xcolor I like to define a named color which actually does not change the current color. So \textcolor{mycolor}{text} should print text in the currently active color. In other words: I'm looking ...
4
votes
1answer
1k views

bug in tabu when rowcolors are defined?

In the following code the vertical separation from cell to the bottom is negative instead of the defined \tabulinesep=5pt when \rowcolor{headcolor} and and \rowfont are defined. ...
9
votes
1answer
2k views

Fancy Theorem Environment and Colors

I'm trying to make a boxed theorem environment with colors. I thought I had done it, but I was mistaken--lists were the wrong colors. In the picture above, I would like the "list" to be the same ...
7
votes
1answer
1k views

How to omit vertical realignment when using cmidrule in different colors?

My question is similar to the one here How do I eliminate the vertical realignment when using arrayrulecolor with cmidrule? but can not be solved with the suggested answer (because the lines are ...
3
votes
2answers
364 views

Centering text in tables problems with colortabs

I am trying to produce a basic color table as shown below \documentclass{article} \usepackage{booktabs} \usepackage[dvipsnames*,svgnames]{xcolor} \usepackage{colortbl} \usepackage{array} ...
1
vote
1answer
1k views

Problem with dtx code: rowcolors unknown

I get the following error in my .dtx file: ) (./test.dtx ! Undefined control sequence. l.35 % \rowcolors {1}{colorrow}{colorbody} which I do not understand since xcolor and colortbl are loaded and ...
3
votes
1answer
1k views

\RequirePackage without option clashes because of the package loading order?

I am writing a package which requires the xcolor package with table option. It is loaded in the package with \PassOptionsToPackage{table}{xcolor} \RequirePackage{xcolor} which works if my package ...