;+ ; Project : SOHO - CDS ; ; Name : XPL_STRUCT ; ; Purpose : Explain STRUCTURE tags by browsing help files ; ; Explanation : A pulldown menu is created representing all the ; levels of "introspection" of a structure variable. ; ; If a tag in a structure is an array, it's "expanded" ; if it's less than SIZE, which by default is set to 30. ; ; The tags of the structure are linked to their tag names ; and their parent structure names, i.e., ; ; STC.TAG ; Tag named "TAG" in structure "STC" ; or .TAG ; Tag named "TAG" in anonymous structure. ; ; These combinations are used to look up help texts via ; WIDG_HELP, and display them on the screen. ; ; Use : XPL_STRUCT, DATA_STRUCTURE ; ; Inputs : DATA_STRUCTURE: Any IDL structure. ; ; Opt. Inputs : None. ; ; Outputs : None. ; ; Opt. Outputs: None. ; ; Keywords : ON_BASE : The widget base to put the pulldown button on. ; SIZE : The maximum size of "expanded" arrays ; FILE : The data file to inspect for help texts. ; Default "struct_tags.hlp" ; TITLE : The title to be associated with the pulldown button ; NOHELP : Turn off the help facility (behaves like DSP_STRUCT) ; ; Calls : DATATYPE(), NTRIM(), TRIM(), WIDG_HELP ; ; Common : None. ; ; Restrictions: None. ; ; Side effects: During development, XDOC suddenly wouldn't work. ; Could not reproduce it... ; ; Category : CDS, UTILITY, STRUCTURE ; ; Prev. Hist. : Based on DSP_STRUCT ; Added some more "intelligent" handling of arrays ; ; Written : SVHH, 16-May-1995 ; ; Modified : Version 2, SVHH, UiO, 27 February 1996 ; Using NTRIM to avoid BYTE->STRING ; conversion. ; Version 3, SVHH, UiO, 28 February 1996 ; Using the /hierarchy flag in calling widg_help ; Version 4, SVHH, UiO, 1 March 1996 ; Using fixed font for widg_help topics ; Version 5, SVHH, UiO, 2 October 1996 ; Splitting long lists of tags into sub-lists. ; ; Version : 5, 2 October 1996 ;- PRO xpl_array,arr,menu=menu,elem=elem,Size=Size,ppp=ppp IF N_elements(elem) eq 0 THEN elem = '"(' sz = Size(arr) FOR i=0, (sz(1)-1)