![]() |
|
Dataplot: Colors
Dataplot Supports 89 Colors
|
You can specify 89 different colors within Dataplot.
A given output device (monitor, laser printer, penplotter)
may or may not have the capacity to generate all 89 colors;
if the capacity does not exist, then a mapping of the
89 colors onto a subset supported by the particular device
will occur.
|
Colors Can Be Specified with Either a Name or an Index
|
Colors can be specified with either a name or an index. For
example,
|
CHARACTER COLOR 8
LINE COLOR YELLOW or
Index Maps to a Specific Color
|
In Dataplot, an index maps to a specific color (e.g., index 3
is equivalent to BLUE). The advantage of this is that names
and indices are consistent across devices. The disadvantage
is that using indices for colors can be somewhat counter
intuitive on a specific device. For example, the VGA device
supports 15 colors. However, using indices 1 through 15 will
not yield 15 unique colors on the VGA.
|
|
Within Dataplot, you can view a file that lists the
index to color mapping by entering the command
|
Color Support on Specific Graphics Devices
|
The following graphics devices support all 89 colors.
|
Displaying the Color Mapping for a Specific Graphics Device
|
For details of the color mapping for a device,
use the SHOW command, as in
|
SHOW VGA COLORS
SHOW CALCOMP COLORS END OF CAPTURE LIST JUNK.
CAPTURE JUNK.
Penplotters Are a Special Case
|
Penplotters are a special case in two ways.
|
|
Table Showing Supported Colors in Dataplot
|
The following table shows the supported colors in Dataplot.
It shows both the name and corresponding index number. The
last column shows the actual color that the VGA device will
generate for the requested color (use the
SHOW COLORS <device> command to see this for other
devices).
|
Gray Scale
|
In addition, gray scale can be specified with the following
scheme.
|
Negative Indices for Gray Scales
|
Gray scales can also be specified with negative indices (-1 through
-100). Currently, Postscript and X11 support gray scale. Other
devices will map gray scale to either black or white.
|
Colors Can Have a Different Appearance on Different Graphics
Devices
|
Be aware that different hardware devices can render a given color
quite differently. For some graphics devices, the colors are
essentially fixed and Dataplot simply tries to map a Dataplot
color to the closes available color on that device (in some
cases, the choices are a bit arbitrary). Even for devices that
support full RGB (Red, Green, Blue, each represented by an
integer value in the range 0 to 255) specification (e.g.,
Postscript, X11, SVG), there can be differences in the colors
actually rendered. Dataplot specificies a consistent set of
RGB values, but this does not garauntee that the color will
look the same on different hardware.
|
Dataplot Graph Showing Different Colors
|
The following graph shows the Dataplot colors from a Postscript
device.
|
Dataplot Program to Demonstrate Colors
|
The Dataplot program that generated the above color graph follows.
|
let xinc = 10 let x2 = x1 + xinc let yinc = 3 let y1 = 97 margin x1 vertical spacing 3 crlf on line thickness 2.5 . line color white; draw x1 y1 x2 y1; text white; let y1 = y1 - yinc line color black; draw x1 y1 x2 y1; text black; let y1 = y1 - yinc line color red; draw x1 y1 x2 y1; text red; let y1 = y1 - yinc line color blue; draw x1 y1 x2 y1; text blue; let y1 = y1 - yinc line color green; draw x1 y1 x2 y1; text green; let y1 = y1 - yinc line color magenta; draw x1 y1 x2 y1; text magenta; let y1 = y1 - yinc line color orange; draw x1 y1 x2 y1; text orange; let y1 = y1 - yinc line color cyan; draw x1 y1 x2 y1; text cyan; let y1 = y1 - yinc line color YELLOW; draw x1 y1 x2 y1; text yellow; let y1 = y1 - yinc line color YGRE; draw x1 y1 x2 y1; text YGRE; let y1 = y1 - yinc line color DGRE; draw x1 y1 x2 y1; text DGRE; let y1 = y1 - yinc line color lblu; draw x1 y1 x2 y1; text lblu; let y1 = y1 - yinc line color vblu; draw x1 y1 x2 y1; text vblu; let y1 = y1 - yinc line color vred; draw x1 y1 x2 y1; text vred; let y1 = y1 - yinc line color dgra; draw x1 y1 x2 y1; text dgra; let y1 = y1 - yinc line color lgra; draw x1 y1 x2 y1; text lgra; let y1 = y1 - yinc line color aqua; draw x1 y1 x2 y1; text aqua; let y1 = y1 - yinc line color brow; draw x1 y1 x2 y1; text brown; let y1 = y1 - yinc line color cabl; draw x1 y1 x2 y1; text cabl; let y1 = y1 - yinc line color coral; draw x1 y1 x2 y1; text coral; let y1 = y1 - yinc line color cblu; draw x1 y1 x2 y1; text cblu; let y1 = y1 - yinc line color dogr; draw x1 y1 x2 y1; text dogr; let y1 = y1 - yinc line color dorc; draw x1 y1 x2 y1; text dorc; let y1 = y1 - yinc line color dsbl; draw x1 y1 x2 y1; text dsbl; let y1 = y1 - yinc line color dtur; draw x1 y1 x2 y1; text dtur; let y1 = y1 - yinc line color fire; draw x1 y1 x2 y1; text fire; let y1 = y1 - yinc line color fgre; draw x1 y1 x2 y1; text fgre; let y1 = y1 - yinc line color gold; draw x1 y1 x2 y1; text gold; let y1 = y1 - yinc line color gldr; draw x1 y1 x2 y1; text gldr; let y1 = y1 - yinc line color gray; draw x1 y1 x2 y1; text gray; let y1 = y1 - yinc . let x1 = 30 let x2 = x1 + xinc let y1 = 97 line color ired; draw x1 y1 x2 y1; text ired; let y1 = y1 - yinc line color khak; draw x1 y1 x2 y1; text khak; let y1 = y1 - yinc line color dmgr; draw x1 y1 x2 y1; text dmgr; let y1 = y1 - yinc line color lsbl; draw x1 y1 x2 y1; text lsbl; let y1 = y1 - yinc line color lgre; draw x1 y1 x2 y1; text lgre; let y1 = y1 - yinc line color maro; draw x1 y1 x2 y1; text maroon; let y1 = y1 - yinc line color maqu; draw x1 y1 x2 y1; text maqu; let y1 = y1 - yinc line color mblu; draw x1 y1 x2 y1; text mblu; let y1 = y1 - yinc line color mfgr; draw x1 y1 x2 y1; text mfgr; let y1 = y1 - yinc line color mgld; draw x1 y1 x2 y1; text mgld; let y1 = y1 - yinc line color morc; draw x1 y1 x2 y1; text morc; let y1 = y1 - yinc line color msgr; draw x1 y1 x2 y1; text msgr; let y1 = y1 - yinc line color msbl; draw x1 y1 x2 y1; text msbl; let y1 = y1 - yinc line color mspg; draw x1 y1 x2 y1; text mspg; let y1 = y1 - yinc line color mtur; draw x1 y1 x2 y1; text mtur; let y1 = y1 - yinc line color mvrd; draw x1 y1 x2 y1; text mvrd; let y1 = y1 - yinc line color mdbl; draw x1 y1 x2 y1; text mdbl; let y1 = y1 - yinc line color navy; draw x1 y1 x2 y1; text navy; let y1 = y1 - yinc line color ored; draw x1 y1 x2 y1; text ored; let y1 = y1 - yinc line color orch; draw x1 y1 x2 y1; text orch; let y1 = y1 - yinc line color pgre; draw x1 y1 x2 y1; text pgre; let y1 = y1 - yinc line color pink; draw x1 y1 x2 y1; text pink; let y1 = y1 - yinc line color plum; draw x1 y1 x2 y1; text plum; let y1 = y1 - yinc line color purp; draw x1 y1 x2 y1; text purple; let y1 = y1 - yinc line color salm; draw x1 y1 x2 y1; text salmon; let y1 = y1 - yinc line color sgre; draw x1 y1 x2 y1; text sgre; let y1 = y1 - yinc line color sien; draw x1 y1 x2 y1; text sienna; let y1 = y1 - yinc line color skbl; draw x1 y1 x2 y1; text skbl; let y1 = y1 - yinc line color sblu; draw x1 y1 x2 y1; text sblu; let y1 = y1 - yinc line color spgr; draw x1 y1 x2 y1; text spgr; let y1 = y1 - yinc . let x1 = 55 let x2 = x1 + xinc let y1 = 97 line color stbl; draw x1 y1 x2 y1; text stbl; let y1 = y1 - yinc line color tan; draw x1 y1 x2 y1; text tan; let y1 = y1 - yinc line color this; draw x1 y1 x2 y1; text thistle; let y1 = y1 - yinc line color turq; draw x1 y1 x2 y1; text turquoise; let y1 = y1 - yinc line color viol; draw x1 y1 x2 y1; text violet; let y1 = y1 - yinc line color whea; draw x1 y1 x2 y1; text wheat; let y1 = y1 - yinc line color gyel; draw x1 y1 x2 y1; text gyel; let y1 = y1 - yinc line color lcya; draw x1 y1 x2 y1; text lcyan; let y1 = y1 - yinc line color blu2; draw x1 y1 x2 y1; text blu2; let y1 = y1 - yinc line color blu3; draw x1 y1 x2 y1; text blu3; let y1 = y1 - yinc line color blu4; draw x1 y1 x2 y1; text blu4; let y1 = y1 - yinc line color cya2; draw x1 y1 x2 y1; text cya2; let y1 = y1 - yinc line color cya3; draw x1 y1 x2 y1; text cya3; let y1 = y1 - yinc line color cya4; draw x1 y1 x2 y1; text cya4; let y1 = y1 - yinc line color gre2; draw x1 y1 x2 y1; text gre2; let y1 = y1 - yinc line color gre3; draw x1 y1 x2 y1; text gre3; let y1 = y1 - yinc line color gre4; draw x1 y1 x2 y1; text gre4; let y1 = y1 - yinc line color yel2; draw x1 y1 x2 y1; text yel2; let y1 = y1 - yinc line color yel3; draw x1 y1 x2 y1; text yel3; let y1 = y1 - yinc line color yel4; draw x1 y1 x2 y1; text yel4; let y1 = y1 - yinc line color ora2; draw x1 y1 x2 y1; text ora2; let y1 = y1 - yinc line color ora3; draw x1 y1 x2 y1; text ora3; let y1 = y1 - yinc line color ora4; draw x1 y1 x2 y1; text ora4; let y1 = y1 - yinc line color red2; draw x1 y1 x2 y1; text red2; let y1 = y1 - yinc line color red3; draw x1 y1 x2 y1; text red3; let y1 = y1 - yinc line color red4; draw x1 y1 x2 y1; text red4; let y1 = y1 - yinc line color mag2; draw x1 y1 x2 y1; text mag2; let y1 = y1 - yinc line color mag3; draw x1 y1 x2 y1; text mag3; let y1 = y1 - yinc line color mag4; draw x1 y1 x2 y1; text mag4; let y1 = y1 - yinc . let x1 = 80 let x2 = x1 + xinc let y1 = 97 line color g10; draw x1 y1 x2 y1; text g10; let y1 = y1 - yinc line color g20; draw x1 y1 x2 y1; text g20; let y1 = y1 - yinc line color g30; draw x1 y1 x2 y1; text g30; let y1 = y1 - yinc line color g40; draw x1 y1 x2 y1; text g40; let y1 = y1 - yinc line color g50; draw x1 y1 x2 y1; text g50; let y1 = y1 - yinc line color g60; draw x1 y1 x2 y1; text g60; let y1 = y1 - yinc line color g70; draw x1 y1 x2 y1; text g70; let y1 = y1 - yinc line color g80; draw x1 y1 x2 y1; text g80; let y1 = y1 - yinc line color g90; draw x1 y1 x2 y1; text g90; let y1 = y1 - yinc
|
Privacy
Policy/Security Notice
NIST is an agency of the U.S.
Commerce Department.
Date created: 6/5/2001 |