NhlGetGksCi

The Fortran name of this function is NhlFGetGksCi.

This function returns the low-level GKS color index from an HLU color index and an instance of a Workstation object.


C synopsis

#include <ncarg/hlu/hlu.h>
#include <hfile for Workstation class object>

int NhlGetGksCi(
	        int	workid,
		int	hlu_ci
		)

Fortran synopsis

      subroutine NhlFGetGksCi(workid, hlu_ci, indx_gks_ret)
      integer workid, hlu_ci, indx_gks_ret

Arguments

workid (input)
Integer identifier of an instance of a Workstation class object
hlu_ci (input)
Integer color index in the range 1 through 255 of a currently allocated color in the given workid Workstation object.
indx_gks_ret (output, Fortran only)
On output, returns the GKS workstation color index for the given hlu color index.

Description

This function retrieves the GKS workstation's color index for the given hlu color index. Given the GKS workstation id, retrieved by getting the Workstation resource wkGksWorkId and the GKS workstation color index, you can mix calls to the low-level NCAR Graphics library and the GKS library with calls to the HLU library.

Using the NhlGetGksCi function, you can use the low-level NCAR Graphics library and the GKS library to draw in the same colors that the HLU library is using.

It is important to note that the HLU library has no way of detecting if the GKS colormap has been modified by GKS calls, so all colormap changes should be done through the HLU library to prevent unpredictable results.


Return values

The NhlGetGksCi function returns the GKS color index that is used for the given HLU color index for the given HLU workstation; the NhlFGetGksCi Fortran subroutine returns the color index in indx_gks_ret. If the given HLU color index is not valid, then 1 will be returned; this is the default foreground color.

See also


Copyright

Copyright 1987-1999 University Corporation for Atmospheric Research
The use of this Software is governed by a License Agreement.

NCAR Graphics is a registered trademark of the University Corporation for Atmospheric Research.

Reference Manual Control Panel

NG4.1 Home, Index, Examples, Glossary, Feedback, Ref Contents, Ref WhereAmI?


$Revision: 1.12 $ $Date: 1998/06/15 21:26:12 $