[Tugindia] colors in latex

Radhakrishnan CV cvr at river-valley.org
Fri Apr 4 17:16:51 CEST 2003


>>>>> "Sandip" == Sandip P Deshmukh <deshmukh at escortsmumbai.com> writes:

    Sandip> hello all my latex documents look wonderful. i must say,
    Sandip> professional quality. it is amazing to know that one can
    Sandip> use a 486 to produce a professional looking document.

    Sandip> one thing i have been missing is colors. i am yet to know
    Sandip> how to make different texts appear in different colors.

\usepackage{color} % load color package

%\definecolor{<color_name>}{<color model>}{<values>}

% syntax for defining colors; color models can be, rgb, cmyk, gray;
% values are comma separated decimal values
% color names can be any logical name you might assign for a color

% eg:

\definecolor{lavender}{rgb}{.902, .902, .98}

\definecolor{gray10}{gray}{.9} % 10% gray

% Usage:

\textcolor{lavender}{text material to appear in lavender color}

%or 

\color{lavender} Material to appear in color .... \normalcolor

or you might define environments which would start and end the
particular color you want.

Useful documentation:

* grfguide.ps(.gz), which is available in any standard TeX distribution.

* TUGIndia on-line tutorial which describes color table available at:
  http://www.tug.org.in/tutorials.html 

Radhakrishnan


More information about the Tugindia mailing list