Вы находитесь на странице: 1из 8

LATEX 2

, color graphics colortbl.


David Carlisle. color
,
. colortbl .


2.1 . . . . . . . . . . . . . . . . . . . . . .
2.1.1 named . . . . . . . . . . . . . . . . . . .
2.1.1.1 , dvips.
2.1.2 rgb . . . . . . . . . . . . . . . . . . . . .
2.1.3 gray . . . . . . . . . . . . . . . . . . . .
2.1.4 cmyk . . . . . . . . . . . . . . . . . . . .
2.2 . . . . . . . . . . . . .

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

.
.
.
.
.
.
.

2
2
2
2
3
4
4
4

\usepackage
, , , .
dvips1 . dvips, Tomas Rokicki, dvi, LATEX , ,
PostScript. ps- GhostScript2
. , GhostScript
ps- PDF. PDF
pdf LATEX, H`an The Th`anh,
pdftex.

c 2001 . : syutkin@ns.kinetics.nsc.ru

\ExecuteOptions color.cfg.
2
GhostScript PostScript Windows GSview.
1

, graphics: xdvi, dvipdf, dvipdfm, dvipsone, dviwindo, emtex, dviwin, pctexps,


pctexwin, pctexhp, pctex32, truetex, tcidvi, vtex, oztex, textures.
, monochrome.
, .

, , (), .
. ,
color. , 3.

2.1

2.1.1 named
named .
. color ,
3 :

black ()
red ()
blue ()
magenta ()

white ()
green ()
cyan ()
yellow ()

\textcolor4 :
\textcolor{blue}{ \fbox{$x^2$}.}

x2 .

2.1.1.1 , dvips. dvipsnam.def 68 . .

GreenYellow
Goldenrod
Apricot
Melon
Orange
Bittersweet
Mahogany
BrickRed
OrangeRed
WildStrawberry
CarnationPink
VioletRed
Mulberry

Yellow
Dandelion
Peach
YellowOrange
BurntOrange
RedOrange
Maroon
Red
RubineRed
Salmon
Magenta
Rhodamine
RedViolet

: GhostScript Acrobat Reader


.
4
, LATEX.

()

Fuchsia
Thistle
DarkOrchid
Plum
RoyalPurple
Periwinkle
CornflowerBlue
NavyBlue
Blue
Cyan
SkyBlue
TealBlue
BlueGreen
JungleGreen
Green
PineGreen
YellowGreen
OliveGreen
Sepia
Tan
Black

Lavender
Orchid
Purple
Violet
BlueViolet
CadetBlue
MidnightBlue
RoyalBlue
Cerulean
ProcessBlue
Turquoise
Aquamarine
Emerald
SeaGreen
ForestGreen
LimeGreen
SpringGreen
RawSienna
Brown
Gray
White

color usenames:
\usepackage[usenames]{color}
dvips , color,
. :
S
\textcolor{Orange}{ $\bigcup$.}
.
usenames , dvips
named :
H
\textcolor[named]{Orange}{ $\oint$.}
.
dvips pdftex, color
dvipsnames.
2.1.2

rgb

rgb :
(red), (green) (blue).
0 1, . , 1,1,0,
1,1,1. 0,0,0 .
, , ,
. , , ,
, . ,
.

2.1.3

gray

(gray) rgb
, . gray
0 1, , 0.5 0.5,0.5,0.5 rgb. 0,
1. gray 2.2.
2.1.4 cmyk
,
. , .
, .
, 5 .
cmyk.
0 1,
(cyan), (magenta), (yellow) (black) .

.
-. .
, cmyk
0,0,0,0 ( ), 0,0,0,1.

2.2

\definecolor{name}{model}{spec}
name . model , spec . name ,
, named.
:
. . .

\definecolor{faded}{gray}{0.7}
\textcolor{faded}{\dots}

text
\textcolor[model]{spec}{text}

{\color[model]{spec}text}
model , spec .
:
\textcolor{red}{,}
\textcolor[cmyk]{0,1,1,0}{ ,}
\textcolor[rgb]{1,0,0}{ !}
5

,
,
!

, ,
.

\colorbox[model]{spec}{lr-text}
, \mbox, lr-text ,
model spec. model , spec .
\fcolorbox[model]{fr-spec}{spec}{lr-text}
fr-spec. :
. . .

\fcolorbox{red}{yellow}{\dots}

, ,
color. 2.

\fcolorbox \fboxrule \fboxsep LATEX.


\pagecolor[model]{spec}
model , spec .
. ,
\pagecolor{white}.

colortbl, color array, .


, color model spec (.
2).

\columncolor[model]{spec}[left-overhang][right-overhang]
>{...} ( array)
tabular array. ,
model spec. left-overhang right-overhang , ,
. ,
.
\tabcolsep tabular \arraycolsep array. , .4\tabcolsep:
\begin{tabular}{%
|>{\color{white}\columncolor{black}}l|
>{\columncolor{yellow}[.6\tabcolsep]}c|
>{\columncolor[gray]{.8}}r|}
& & \\ & &
\end{tabular}

\rowcolor[model]{spec}[left-overhang][right-overhang]
5

. :
\begin{tabular}{|l|c|}

\rowcolor[gray]{.9} & \\

\rowcolor[gray]{.6} &
\end{tabular}
.
\multicolumn. ,
:
\newcolumntype{H}{>{\columncolor{magenta}}c}
\begin{tabular}{%
|>{\columncolor{yellow}}l|
>{\color{white}\columncolor{black}}l|}
\multicolumn{2}{|H|}{} \\
& \\ &
\end{tabular}

colortbl longtable dcolumn tools.


, . . \tabrowsep.
plain TEX, \tabrowsep :
\def\tabrowsep{\noalign{\vskip 2pt}}
\noalign, ( 2 pt) ( ). \tabrowsep:
\newcolumntype{H}{%
>{\columncolor[gray]{.9}}p{1.7cm}}
\begin{tabular}[t]{*2H}
\rowcolor[gray]{.6} & \\\tabrowsep
& \\\tabrowsep &
\end{tabular}

\arrayrulecolor[model]{spec}
, .
, >{...}
- . \arrayrulecolor
. , ,
, , .

\doublerulesepcolor[model]{spec}
(||) (\hline\hline) .
. :
\setlength\arrayrulewidth{2pt}\arrayrulecolor{blue}
\setlength\doublerulesep{2pt}\doublerulesepcolor{yellow}
\begin{tabular}{||l||c||}
\hline\hline
& \\ & \\
\hline\hline
\end{tabular}

\hhline hhline, ,
, , :
\begin{tabular}{||l|c||}

\hhline{|t:=:t:=:t|}

& \\ & \\
\hhline{|b:=:b:=:b|}
\end{tabular}
\arrayrulecolor \doublerulesepcolor >{...}
- = \hhline. :
\newcommand\rgbline[1]{\hhline{>{\arrayrulecolor{red}}|#1:=%
>{\arrayrulecolor{green}}=>{\arrayrulecolor{blue}}=:#1|}}
\arrayrulecolor{red}
\begin{tabular}{||*3c||}\rgbline{t}
red & green & \multicolumn{1}{c||}{blue}\\
\rgbline{b}\end{tabular}

red

green

blue

- , \cline,
\hhline -.


a
\arrayrulecolor . . . . . . . . . . . . . . 6

t
\textcolor . . . . . . . . . . . . . . . . . . . 4

c
\color . . . . . . . . . . . . . . . . . . . . . . . 4
\colorbox . . . . . . . . . . . . . . . . . . . . 5
\columncolor . . . . . . . . . . . . . . . . . 5

dvipsnames . . . . . . . . . . . . . . . . 3
monochrome . . . . . . . . . . . . . . . . 2
usenames . . . . . . . . . . . . . . . . . . 3

d
\definecolor . . . . . . . . . . . . . . . . . 4
\doublerulesepcolor . . . . . . . . . . 6


cmyk . . . . .
gray . . . . .
named . . . .
rgb . . . . . .

p
\pagecolor . . . . . . . . . . . . . . . . . . . 5
r
\rowcolor . . . . . . . . . . . . . . . . . . . . 5

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

.
.
.
.

4
4
2
3