NAME: setcolor PURPOSE: (one line only) Set a 24-bit color value for plotting on 24-bit direct graphics or Postscript DESCRIPTION: CATEGORY: Utility CALLING SEQUENCE: value=setcolor(input) INPUTS: input - Input value. Choices are: Scalar long - this is taken to be the BGR triplet, example: '0000ff'xl is red. Byte or integer, 3-element vector - this is taken to be RGB example: [0,0,255] is red. If the input is invalid in any way !d.n_colors-1 is returned. OPTIONAL INPUT PARAMETERS: KEYWORD INPUT PARAMETERS: OUTPUTS: return value is the color index needed. This is intended to be passed to the color keyword on many plot programs. KEYWORD OUTPUT PARAMETERS: COMMON BLOCKS: SIDE EFFECTS: RESTRICTIONS: PROCEDURE: If the display is 24-bit, the color is returned as a LONG scalar. If the display is Postscript, then a three color lookup table is loaded where 0=white, 1=your color, 2=black. In this case the return value is set to 1. To return the color to a normal setting after this you need to do the following manually. tvlct,bindgen(256),bindgen(256),bindgen(256) or loadct,0,/silent MODIFICATION HISTORY: Written by Marc W. Buie, Southwest Research Institute, 2009/01/13