Univeristy of Alabama in Huntsville


IDL Routines from Phillip Bitzer and UAH Lightning Group

summary     class     fields     routine details     file attributes



Misc, Plotting, Graphic

When dealing with Function Graphics, it's handy to know what visualization elements are in a graphic. This is especially true for mapping. This function adds a method to IDL's Graphic to retrieve these names.


Let's say you're working on an example from the documentation:

map = MAP('Orthographic', $ LIMIT = [30, -150, 60, -90], $ CENTER_LATITUDE = 48, $ CENTER_LONGITUDE = -122, $ FILL_COLOR = "light blue") m1 = MAPCONTINENTS() m2 = MAPCONTINENTS(/USA, COMBINE = 0, FILL_COLOR = "MOCCASIN") m3 = MAPCONTINENTS(/CANADA, COMBINE = 0, FILL_COLOR = "MOCCASIN") m4 = MAPCONTINENTS(/LAKES, FILL_COLOR="light blue") The Harris example then colors some of the entities in the map:
cstates = MAP['USA/*C*'] FOREACH c,cstates DO c.FILL_COLOR="goldenrod" MAP['Saskatchewan'].FILL_COLOR = "goldenrod"
It's not clear how/what possibilites there are. To see what's available:
names = map.VisNames()
You'll get a hash with visualizations in the graphic. The line:
cstates = MAP['USA/*C*']
corresponds to the all the states that begin with "C". You can see all the states with:
print, names['USA']

Author information


Phillip M. Bitzer, University of Alabama in Huntsville, pm.bitzer "AT" uah.edu


See Git log.


top Graphic::VisNames

result = Graphic::VisNames( [FullArray=string])

Return a Hash of the visualization elements in a graphic.

Return value

An ordered hash. The keys are the parent visualization names, and their children are the values


FullArray out optional type=string

If a named variable is provided, then return all the visualization identifiers as a string array in this variable.

Other attributes


None, external

File attributes

Modification date: Fri Nov 10 15:10:58 2017
Lines: 28
Docformat: rst rst