This page was created by the IDL library routine `mk_html_help2`.

Last modified: Tue Aug 5 18:17:40 2025.

# Directory Listing of Routines

# projects/themis/deprecated/thm_ui

- THM_GUI_ORIGINAL
  GUI for THEMIS data analysis
- THM_UI_CALL_TPLOT
  A widget interface for calling tplot from the themis_w widget,
- THM_UI_CHECK4SPIN
  given a THEMIS tplot variable name, check to see if spin period and
- THM_UI_CHOOSE_DTYPE
  A widget for choosing data for the THEMIS data analysis GUI
- THM_UI_COTRANS_OLD
  Widget for coordinate transforms
- THM_UI_DPROC
  A widget interface for calling tplot from the themis_w widget,
- THM_UI_ERROR
  A widget to display, edit and save the file 'thm_gui_error.txt' error
- THM_UI_HELP
  A widget to display the file 'thm_gui.txt' help
- THM_UI_LOAD_DATA_FN
  A widget interface to load CDF data for whatever instrument
- THM_UI_MULTICHOICE_HISTORY
- THM_UI_NPAR
  Simple widget that allows user to change n parameter values and units (if units were
- THM_UI_NPAR_NEW
  Simple widget that allows user to change n parameter values and units (if units were
- THM_UI_ONLY_TRANGE
  This program oprerates on the tplot data_quants to strip out data
- THM_UI_PAR
  Simple widget that asks for a parameter
- THM_UI_PROGOBJ__DEFINE
  defines an object to pass through into file_retrieve and
- TPWRSPC[1]
  wapper for pwrspc.pro for calling from GUI, a split_vec is performed
- THM_UI_RESET_COMMON_BLOCK
- THM_UI_SCLIST
  creates an array for the different themis spacecraft, to be used in
- THM_UI_SCMCAL
  A widget for choosing data for the THEMIS data analysis GUI
- THM_UI__SCMCAL_HELP
  A widget to display the file 'thm_gui.txt' help
- THM_UI_SET_ACTIVE_DSET
  sets active datasets in themis GUI to given tplot varnames, used in
- THM_UI_SET_DATA_ID
  This program sets the data_id values of the pointer in the thm_gui state
- THM_UI_SET_TRANGE
  A widget interface for setting time ranges for the thm_gui widget
- THM_UI_SHOW_DLIM
- THM_UI_SUMMPLOT
  This widget prompts the user for a choice of probe, and then Calls
- THM_UI_TSELECT
  A list widget for time selection, this is a blocking widget, it must
- THM_UI_TSELECT_FN
- THM_UI_UPDATE_DATA_ALL
  Calls thm_ui_set_data_id, thm_ui_set_active_dset and
- THM_UI_UPDATE_DATA_DISPLAY
  update the loaded-data display for the themis_w widget
- THM_UI_UPDATE_HISTORY
  Adds the string input to the state structure history array
- THM_UI_UPDATE_PROGRESS
  Write a string into the progress widget for the THEMIS GUI
- THM_UI_USERDEF
  A widget that allows the user to define his own operator to be used
- THM_UI_VALID_DTYPE
  get valid datatype names from thm_load_* routines, using the
- YESNO_WIDGET_FN
  Simple widget that asks for a yes or no

# Routine Descriptions

## THM_GUI_ORIGINAL

[Next Routine] [List of Routines]

    NAME:
     thm_gui_original
    PURPOSE:
     GUI for THEMIS data analysis
    CALLING SEQUENCE:
     thm_gui_original
    INPUT:
     none
    OUTPUT:
     none
    HISTORY:
     Version 2.0 jmm, jimm@ssl.berkeley.edu 25-apr-2007
                 jmm, 21-may-2007, Currently Only Loads data
                 jmm, 7-jun-2007, all buttons are now defined
                 jmm, 31-jul-2007, added warning for too long time ranges
                 jmm, 2-aug-2007, added widget_kill_request block so that
                      the pointers and progobj are cleaned up when you click
                      the 'x'
                 jmm, 11-sep-2007, added this comment
                 jmm, 25-oct-2007, Now holds plot parameters (wondow
                                   number,etc) in state structure
                 jmm, 4-mar-2008, put in this comment to test email
                      notifications
                 cg,  1-apr-2008, added ps_size and ps_units to pstate structure
                      (needed to store user inputs for postscript file size)
                 cg,  29-may-2008, added a new structure that defines the SCM
                      calibration parameters. altered how the load SCM data is
                      handled, it now calls a different GUI for SCM data
                 jmm, Tweaking to test SVN, 21-May-2009
                 jmm, Tweaking to test SVN, 9-nov-2016
    $LastChangedBy: $
    $LastChangedDate: $
    $LastChangedRevision: $
    $URL: $

(See projects/themis/deprecated/thm_ui/thm_gui_original.pro)

## THM_UI_CALL_TPLOT

[Previous Routine] [Next Routine] [List of Routines]

    NAME: Setting ptype
     thm_ui_call_tplot
    PURPOSE:
     A widget interface for calling tplot from the themis_w widget,
     currently of limited usefulness, but expandable
    CALLING SEQUENCE:
     thm_ui_call_tplot, master_widget_id
    INPUT:
     master_widget_id = the id number of the widget that calls this
    OUTPUT:
     none, there are button_master to push for plotting, setting limits, not
     sure what else yet...
    HISTORY:
     14-dec-2006, jmm, jimm@ssl.berkeley.edu
     13-feb-2007, jmm, fixed problem with !p.background resetting in
     set_plot commands
     12-mar-2007, jmm, Added wavelet button
     2-apr-2007, jmm, Added pwrspc options, NEEDS TESTING.
     jun-2007, jmm, split from dproc widget.
     12-jul-2007, jmm, added a message widget, for invalid user input
                       errors, grays out all button_master while processing
     31-jul-2007, jmm, various checks for windows present to avoid tplot
                       and ctime bombs
     25-oct-2007, jmm, plot info, window number, size, ptyp, are no held
                       in the main GUI state structure
     19-mar-2008, jmm, changed state.ptyp to pstate.ptyp to fix bug
     1-apr-2008, cg, added a pop-up window to allow user to set size/units
                     for postscript files
     5-may-2008, cg, fixed bug with scroll bar
     15-may-2008, cg, added spacecraft/component plot capabilities
                      reorganized code

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_call_tplot.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_call_tplot.pro)

## THM_UI_CHECK4SPIN

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_check4spin
    PURPOSE:
     given a THEMIS tplot variable name, check to see if spin period and
     phase exist, for coordinate transformations, If they do not, load
     the state data for the appropriate time period
    CALLING SEQUENCE:
     thm_ui_check4spin, vname, vname_spin1, vname_spin2, history_out
    INPUT:
     vname = tplot variable name
    OUTPUT:
     vname_spin1 = the tplot variable containing the spin period. or
                     spinras
     vname_spin2 = the tplot variable containing the spin phase or
                       spindec
     history_out = a history string, if data needs loading
    KEYWORDS:
     rasdec = if set, return the variables for spinras, and spindec used
              for dsl <-> gse tranformations
    HISTORY:
     26-feb-2007, jmm, jimm@ssl.berkeley.edu

     NOTES:
       The rest of the original GUI has been deprecated, but this routine is useful for a lot of the other THEMIS code.
         For now, it will live in common

    $LastChangedBy: jwl $
    $LastChangedDate: 2014-01-24 16:22:37 -0800 (Fri, 24 Jan 2014) $
    $LastChangedRevision: 14015 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_check4spin.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_check4spin.pro)

## THM_UI_CHOOSE_DTYPE

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_choose_dtype
    PURPOSE:
     A widget for choosing data for the THEMIS data analysis GUI
    CALLING SEQUENCE:
     thm_ui_choose_dtype, instr, dtyp, station, astation, probe
    INPUT:
     instr = the instrument,  one of ['asi', 'ask', 'esa_pkt', $
               'efi', 'fbk', 'fft', 'fgm', $
               'fit', 'gmag', 'mom', 'scm', 'sst', 'state']
    OUTPUT:
     dtyp = the output datatype, a string of instr/datatype/datalevel,
            e.g., 'state/spinras/l1'
     station = the ground station(s) if gmag data was chosen
     astation = the ground station(s) if asi data was chosen
     probe = the spacecraft if spacecraft data was chosen
    HISTORY:
     jmm, jimm@ssl.berkeley.edu 1-may-2007
     jmm, Changed the probe list to reflect probe assigments:
          A (P5), B (P1), C (P2), D (P3) and E (P4)
           14-jun-2007
     jmm, correctly handles level 1 and level 2 datatypes, 11-jul-2007
     jmm, really correctly handles level 1 and 2 data types, by using a
          common block to handle them
     jmm, changed default behavior of windows, when an invalid string is
          used, then the available data types are set to 'None',
          31-jul-2007
     jmm, Changed call to thm_ui_valid_dtype to
          reflect new version, 11-apr-2008
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_choose_dtype.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_choose_dtype.pro)

## THM_UI_COTRANS_OLD

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_cotrans_old
    PURPOSE:
     Widget for coordinate transforms
    CALLING SEQUENCE:
     thm_ui_cotrans_old, gui_id
    INPUT:
     gui_id = the widget id of the thm_gui widget that called this one.
    OUTPUT:
     none explicit, new variables are created
    HISTORY:
     26-feb-2007, jmm, jimm@ssl.berkeley.edu
     10-apr-2007, jmm, changed input from state to the variable names
     31-may-2007, jmm, rewrite to become its own widget, and to call
                  thm_cotrans, rather than cotrans directly
     12-jul-2007, jmm, added a message widget, for invalid user input errors
     06-may-2008, cg, rearranged gui so that message window is at bottom, is
                  longer and doesn't wrap
     08-apr-2015, af, renaming to avoid conflict with new routine
    $LastChangedBy: aaflores $
    $LastChangedDate: 2015-04-24 18:45:02 -0700 (Fri, 24 Apr 2015) $
    $LastChangedRevision: 17429 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_cotrans_old.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_cotrans_old.pro)

## THM_UI_DPROC

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_dproc
    PURPOSE:
     A widget interface for calling tplot from the themis_w widget,
     currently of limited usefulness, but expandable
    CALLING SEQUENCE:
     thm_ui_dproc, master_widget_id
    INPUT:
     master_widget_id = the id number of the widget that calls this
    OUTPUT:
     none, there are buttons to push for plotting, setting limits, not
     sure what else yet...
    HISTORY:
     06-may-2008, cg, added check to validate data, any active data that
                      has dimensions ge 3 cannot be processed
                      added data check for despike, time deriv, wavelet,
                      powerspec, active data that has a y component > 6
                      cannot be processed
                      and finally, rearranged widgets to allow for a long
                      narrow message window
     28-mar-2008, cg, added filename dialog box to ascii save option,
                      and passed file name to tplot_ascii
     14-dec-2006, jmm, jimm@ssl.berkeley.edu
     13-feb-2007, jmm, fixed problem with !p.background resetting in
     set_plot commands
     12-mar-2007, jmm, Added wavelet button
     2-apr-2007, jmm, Added pwrspc options
     5-jun-2007, jmm, rewritten
     12-jul-2007, jmm, added a message widget, for invalid user input
                       errors, grays out all buttons while processing
     31-jul-2007, jmm, changed time limits to 'set time limits'
     17-mar-2008, jmm, changed smooth option to input seconds, not npts
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_dproc.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_dproc.pro)

## THM_UI_ERROR

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
    thm_ui_error
    PURPOSE:
     A widget to display, edit and save the file 'thm_gui_error.txt' error

    $LastChangedBy: cgoethel_new $
    $LastChangedDate: 2009-03-12 14:24:14 -0700 (Thu, 12 Mar 2009) $
    $LastChangedRevision: 5269 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_error.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_error.pro)

## THM_UI_HELP

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
    thm_ui_help
    PURPOSE:
     A widget to display the file 'thm_gui.txt' help

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_help.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_help.pro)

## THM_UI_LOAD_DATA_FN

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
    thm_ui_load_data_fn
    PURPOSE:
    A widget interface to load CDF data for whatever instrument
    CALLING SEQUENCE:
    varnames = thm_ui_load_data_fn(st_time, en_time, $
                                  dtype = dtype, $
                                  station = station, $
                                  astation = astation, $
                                  probe = probe)
    INPUT:
    st_time, en_time = start and end times in seconds from
                       1-jan-1970 0:00
    KEYWORDS:
    dtype, the type of data, a string, of form
           'instrument/datatype/datalevel', the default is 'gmag/mag/l2'
    station, the ground station of the gmag data, default is '*', for all
    astation, the ground station of the asi data, default is '*', for all
    probe = one or more of ['a','b','c','d','e'], default is ['a','b','c','d','e']
    scm_cal = a structure containing calibration parameters
    OUTPUT:
    varnames = an array of tplot variable names, to pass into tplot
    HISTORY:
     22-sep-2006, jmm, jimm@ssl.berkeley.edu
     23-oct-2006, jmm, changed to call cdf2tplot
     30-oct-2006, jmm, changed again, to call load_thg_mag, also added
                       dtype and station as inputs
     13-nov-2006, jmm, changed the argument list, now the output is a
                       data id string, added a check for start time > end
                       time
     08-dec-2006, krb, changed load_thg_mag to thm_load_gmag
     13-dec-2006, jmm, Added call to cdf2tplot for data for which there
                       is no load program...
     14-dec-2006, jmm, returns an array of variable names and
                       subscripts, which should be easier to read..
     15-dec-2006, jmm, Added calls to thm_load_fgm, fit, sst, efi,
                       ask,probe can be an array
     16-jan-2007, jmm, Add all of the thm_load routines
     5-feb-2007,  jmm, update calls to load routines
     10-apr-2007, jmm, removed history tracking, which is now handled in
                       thm_gui_event, also changed dtype, station
                       astation and probe to keywords
     1-may-2007,  jmm, New version, new argument list,etc....
     10-may-2007, jmm, New version, new argument list,etc... that last
                       one lasted a long time, didn't it
     30-jul-2007, jmm, allow for string time input, this is needed to
                       run histories.
     11-apr-2008, jmm, Added 'spin' ipnput option
     21-apr-2008, WMFeuerstein, Changed THM_LOAD_SCM call as per Vassilis'
                       instructions.
     30-may-2008, cg,  added optional keyword scm_cal to pass in calibration
                       parameters
    $LastChangedBy: aaflores $
    $LastChangedDate: 2012-01-26 16:47:04 -0800 (Thu, 26 Jan 2012) $
    $LastChangedRevision: 9627 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_load_data_fn.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_load_data_fn.pro)

## THM_UI_MULTICHOICE_HISTORY

[Previous Routine] [Next Routine] [List of Routines]

     This program creates a string for the history array when multiple
     datatypes, spacecraft or stations are chosen, for use in the
     themis_w_event routine
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_multichoice_history.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_multichoice_history.pro)

## THM_UI_NPAR

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_npar
    PURPOSE:
     Simple widget that allows user to change n parameter values and units (if units were
     specified)
    CALLING SEQUENCE:
     new_value = thm_ui_npar(name, init_value, [radio_array=radio_array], $
                             [radio_value=radio_value])
    INPUT:
     name = the name of the parameter, can be an array
     init_value = the initial value of the parameter, e.g., '1.0', must
                  be a string array of the smae size as name
     radio_array = optional string array containing radio button names
     title=title = optional title for the panel
     radio_value = optional string containing the radio button to set initially
    OUTPUT:
     new_value = the output value of the parameters, a string array of values,
                 e.g., ['4.67', '3.0', ...n]
                 if optional radio buttons were used the last element of  the array
                 will contain the radio button selection,
                 e.g., ['4.67', '3.0', ..., 'inches']
    METHODS:
     thm_ui_npar0 - creates the window, widgets, and calls the xmanager
     thm_ui_npar0_event - event handler for the window (handles parameter input, cancel/
                          accept buttons, and window close 'X'
     thm_ui_rad_event - event handler for the radio buttons; thm_ui_npar0 - creates the window, widgets, and calls the xmanager
    HISTORY:
     5-feb-2007, jmm, jimm@ssl.berkeley.edu
     25-OCt-2007, jmm, added KILL_REQUEST block
     15-may-2008, cg, added optional title for widget

    $LastChangedBy: aaflores $
    $LastChangedDate: 2012-01-26 16:47:04 -0800 (Thu, 26 Jan 2012) $
    $LastChangedRevision: 9627 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_npar.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_npar.pro)

## THM_UI_NPAR_NEW

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_npar_new
    PURPOSE:
     Simple widget that allows user to change n parameter values and units (if units were
     specified)
    CALLING SEQUENCE:
     new_value = thm_ui_npar_new(name, init_value, [radio_array=radio_array], $
                             [radio_value=radio_value])
    INPUT:
     name = the name of the parameter, can be an array
     init_value = the initial value of the parameter, e.g., '1.0', must
                  be a string array of the smae size as name
     radio_array = optional string array containing radio button names
     title=title = optional title for the panel
     radio_value = optional string containing the radio button to set initially
    OUTPUT:
     new_value = the output value of the parameters, a string array of values,
                 e.g., ['4.67', '3.0', ...n]
                 if optional radio buttons were used the last element of  the array
                 will contain the radio button selection,
                 e.g., ['4.67', '3.0', ..., 'inches']
    METHODS:
     thm_ui_npar_new0 - creates the window, widgets, and calls the xmanager
     thm_ui_npar_new0_event - event handler for the window (handles parameter input, cancel/
                          accept buttons, and window close 'X'
     thm_ui_rad_event - event handler for the radio buttons; thm_ui_npar_new0 - creates the window, widgets, and calls the xmanager
    HISTORY:
     5-feb-2007, jmm, jimm@ssl.berkeley.edu
     25-OCt-2007, jmm, added KILL_REQUEST block
     15-may-2008, cg, added optional title for widget
     20-jan-2009, jmm, Testing SVN
     20-jan-2009, jmm, Testing SVN again
     20-jan-2009, jmm, And again
    $LastChangedBy: lphilpott $
    $LastChangedDate: 2012-06-18 14:37:32 -0700 (Mon, 18 Jun 2012) $
    $LastChangedRevision: 10578 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_npar_new.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_npar_new.pro)

## THM_UI_ONLY_TRANGE

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_only_trange
    PURPOSE:
     This program oprerates on the tplot data_quants to strip out data
     the is not in the input time range: start time, end time, and the
     subscripts of the appropriate data_quants structures are used, this
     is designed to be used in thm_ui_load_data_fn only... jmm,
     13-nov-2006
    INPUT:
     st_time, en_time = time in seconds from 1-jan-1970 0:00
     data_ss = the subscripts of the data array to on which to operate
    OUTPUT:
     None explicit, the tplot variables are changed
    HISTORY:
     jmm, 13-nov-2006, jimm@ssl.berkeley.edu
     jmm, 13-dec-2006, made to work for non thg_mag data

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_only_trange.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_only_trange.pro)

## THM_UI_PAR

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_par
    PURPOSE:
     Simple widget that asks for a parameter
    CALLING SEQUENCE:
     new_value = thm_ui_par(name, init_value)
    INPUT:
     name = the name of the parameter, e.g., 'time_resolution'
     init_value = the initial value of the parameter, e.g., '1.0', must
                  be a string.
    OUTPUT:
     new_value = the output value of the parameter, a string, e.g., '4.67'
    HISTORY:
     22-jan-2007, jmm, jimm@ssl.berkeley.edu
     25-OCt-2007, jmm, added KILL_REQUEST block
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_par.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_par.pro)

## THM_UI_PROGOBJ__DEFINE

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_progobj__define
    PURPOSE:
     defines an object to pass through into file_retrieve and
     file_http_copy that allows updates to the thm_gui progress widget
    METHODS DEFINED IN THIS CLASS:
     set = sets the parameter (only one, the gui widget id)
     get = returns the parameter
     update = if called, this updates the thm_gui progress widget, with
              the input text
     checkcancel = Currently does nothing, but will eventually allow the
                   user to cancel a download.
    HISTORY:
     15-may-2007, jmm, jimm@ssl.berkeley.edu
     24-jul-2007, jmm, activated checkcancel, to see if it can do anything...
     5-mar-2008, jmm, pass _extra through to thm_ui_update_progress, to
                      allow the message_wid value to be passed through
     $LastChangedBy: jimm $
     $LastChangedDate: 2009-01-20 11:23:55 -0800 (Tue, 20 Jan 2009) $
     $LastChangedRevision: 4561 $
     $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_progobj__define.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_progobj__define.pro)

## THM_UI_RESET_COMMON_BLOCK

[Previous Routine] [Next Routine] [List of Routines]

     This puts the input data structure into the tplot common block as
     the data_quants structure, and undefines all of the other variables
     in the common block, using temporary, the original common block is
     saved in a different common block. This is needed to call the
     stackmagplot routine on a subset of stations
     13-nov-2006, jmm, jimm@ssl.berkeley.edu

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_reset_common_block.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_reset_common_block.pro)

## THM_UI_SCLIST

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_sclist
    PURPOSE:
     creates an array for the different themis spacecraft, to be used in
     a list widget
    CALLING SEQUENCE:
     sclist = thm_ui_sclist()
    INPUT:
     none
    OUTPUT:
     sclist = ['THA', 'THB', 'THC', 'THD', 'THE']

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_sclist.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_sclist.pro)

## THM_UI_SCMCAL

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_scmcal
    PURPOSE:
     A widget for choosing data for the THEMIS data analysis GUI
     This was specifically built for SCM data and displays additional
     user inputs for configuration settings
    CALLING SEQUENCE:
     thm_ui_scmcal, gui_id, instr_in0
    INPUT:
     gui_id - gui id number for the main panel
     instr_in0 - instrument name
    OUTPUT:
     cal_params - structure of SCM calibration parameters
    HISTORY:
    AUTHOR: Cindy Goethel
    $LastChangedBy: lphilpott $
    $LastChangedDate: 2012-06-14 10:40:21 -0700 (Thu, 14 Jun 2012) $
    $LastChangedRevision: 10557 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_scmcal.pro $ cal_base

(See projects/themis/deprecated/thm_ui/thm_ui_scmcal.pro)

## THM_UI_SET_ACTIVE_DSET

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_set_active_dset
    PURPOSE:
     sets active datasets in themis GUI to given tplot varnames, used in
     the call_tplot widget.
    CALLING SEQUENCE:
     ss = thm_ui_set_active_dset(gui_id, active_names)
    INPUT:
     gui_id = the widget id for the master widget
     active_names = the tplot variable names
    OUTPUT:
     ss = the subscripts of the valid active varnames in the full
          tnames() array
    HISTORY:
     22-jan-2007, jmm, jimm@ssl.berkeley.edu
     27-feb-2007, jmm, removed call to set_state_ptrs routine
     10-may-2007, jmm, changed argument list, to use the GUI_ID and not
                       the state structure
     7-may-2008, jmm, Slight change to avoid putting in invalid names

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_set_active_dset.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_set_active_dset.pro)

## THM_UI_SET_DATA_ID

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_set_data_id
    PURPOSE:
     This program sets the data_id values of the pointer in the thm_gui state
     structure, given the tplot common block:
    INPUT:
     state_or_id = thm_gui state structure, or gui_id
    HISTORY:
     26-feb-2007, jmm, jimm@ssl.berkeley.edu
     10-may-2007, jmm, allow for input of the gui_id instead of the state

    $LastChangedBy: pcruce $
    $LastChangedDate: 2013-09-19 11:51:11 -0700 (Thu, 19 Sep 2013) $
    $LastChangedRevision: 13087 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_set_data_id.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_set_data_id.pro)

## THM_UI_SET_TRANGE

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_set_trange
    PURPOSE:
     A widget interface for setting time ranges for the thm_gui widget
    CALLING SEQUENCE:
     thm_ui_set_trange, master_widget_id
    INPUT:
     master_widget_id = the id number of the widget that calls this
    OUTPUT:
     none, the start and end time are set
    HISTORY:
     9-may-2007, jmm, jimm@ssl.berkeley.edu
     12-jul-2007, jmm, Removed ability to type in time values..
     19-jul-2007, jmm, typed time values are back..
     25-oct-2007, jmm, Added kill_request block
    $LastChangedBy: jimm $
    $LastChangedDate: 2011-11-04 11:47:05 -0700 (Fri, 04 Nov 2011) $
    $LastChangedRevision: 9262 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_set_trange.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_set_trange.pro)

## THM_UI_SHOW_DLIM

[Previous Routine] [Next Routine] [List of Routines]

    Name:
    THM_UI_SHOW_DLIM.PRO

    Syntax:
      THM_UI_SHOW_DLIM ,tplot_name, group=group
        where,
        tplot_name is the name string or index number of a single tplot
          variable.

    Purpose:
      Display the output of help,/structure for the default limits
        structure of specified tplot variable.

    Keywords:
      group

    Example:
      This is a subroutine to THM_GUI.PRO -- not intended for outside
        calls (but it wil work).

    Author: W.M.Feuerstein, 2008/2/4

    Modification History:
      Padded names array with white space to make widget output left
        justified, WMF.
      Fixed group kw (must die with parent), fixed Windows bug,
        added DLIMITS.DATA_ATT info (if present), WMF, 3/5/2008.

    History:
      A J. McTiernan request.
      Adapted from TPLOT_LABEL.PRO

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_show_dlim.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_show_dlim.pro)

## THM_UI_SUMMPLOT

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_summplot
    PURPOSE:
     This widget prompts the user for a choice of probe, and then Calls
     the thm_gen_overplot routine.
    HISTORY:
     21-jun-2007, jmm, jimm@ssl.berkeley.edu
     31-jul-2007, jmm, resets active data in correct order after plotting
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_summplot.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_summplot.pro)

## THM_UI_TSELECT

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_tselect
    PURPOSE:
     A list widget for time selection, this is a blocking widget, it must
     be exited for anything to happen
    CALLING SEQUENCE:
     thm_ui_teslect
    INPUT:
     none
    OUTPUT:
     the selected time is held in the common block saved_time_sel
    HISTORY:
     sep-2006,  jmm,  jimm@ssl.berkeley.edu

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_tselect.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_tselect.pro)

## THM_UI_TSELECT_FN

[Previous Routine] [Next Routine] [List of Routines]

     Calls the thm_tselect widget, returns the value..
    16-jul-2007, jmm added the init_time input
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_tselect_fn.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_tselect_fn.pro)

## THM_UI_UPDATE_DATA_ALL

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_update_data_all
    PURPOSE:
     Calls thm_ui_set_data_id, thm_ui_set_active_dset and
     thm_ui_update_data_display in one procedure,
    CALLING SEQUENCE:
     thm_ui_update_data_all, gui_id, active_vnames
    INPUT:
     gui_id = a widget id for the gui
    OUTPUT:
     none
    HISTORY:
     5-jun-2007, jmm, jimm@ssl.berkeley.edu
     7-may-2008, jmm, sort and uniq functionality is handled by tnames
                      call. This is now a short program....
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_update_data_all.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_update_data_all.pro)

## THM_UI_UPDATE_DATA_DISPLAY

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_update_data_display
    PURPOSE:
     update the loaded-data display for the themis_w widget
    CALLIMG SEQUENCE:
     thm_ui_update_data_display, widget_id
    INPUT:
     widget_id = the id number of the widget
    HISTORY:
     dec-2006, jmm jimm@ssl.berkeley.edu
     18-jun-2007, jmm, changed to access 'active data' widget
     16-jul-2007, jmm, changed to add coordinate system to display
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_update_data_display.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_update_data_display.pro)

## THM_UI_UPDATE_HISTORY

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_update_history
    PURPOSE:
     Adds the string input to the state structure history array
    INPUT:
     string = a string to add to the history array. Note that this is
     returned undefined, if it is passed in by reference, i/e/, if it's a
     named variable.
    OUTPUT:
     state.history is updated
    HISTORY:
     sep-2006, jmm, jimm@ssl.berkeley.edu
     26-feb-2007, jmm, fixed problem with multiple lines when choosing
                       multiple probes, datatypes, sataiotns, etc...
     8-may-2007, jmm, changed so that the thm_gui widget id is now passed
                      in, since the history widget is now on the main
                      widget, removed some error checking, if things are
                      undefined in here i want to know

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_update_history.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_update_history.pro)

## THM_UI_UPDATE_PROGRESS

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_update_progress
    PURPOSE:
     Write a string into the progress widget for the THEMIS GUI
    CALLING SEQUENCE:
     thm_ui_update_progress, gui_id, input_string
    INPUT:
     gui_id = the widget_id for the GUI
     input_string = a string to be displayed
    OUTPUT:
     None
    KEYWORDS:
     message_wid = id for any other message widgets that you might like
                    to display the messages
    HISTORY:
     jmm, 9-may-2007, jimm@ssl.berkeley.edu
     jmm, 5-mar-2008, added multiple lines, and the ability to show in
                      multiple message widgets.
    $LastChangedBy: nikos $
    $LastChangedDate: 2014-06-17 11:59:06 -0700 (Tue, 17 Jun 2014) $
    $LastChangedRevision: 15392 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/spedas/gui/utilities/spd_ui_update_progress.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_update_progress.pro)

## THM_UI_USERDEF

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_userdef
    PURPOSE:
     A widget that allows the user to define his own operator to be used
     on the data from a tplot variable, e.g., the user types in the
     string '2.0*!pi*q', and a temporary function is created which takes
     the data and does this multiplication. This is pretty experimental.
    CALLING SEQUENCE:
     thm_ui_userdef, gui_id
    INPUT:
     gui_id = the id of the main gui widget
    OUTPUT:
     none explicit, hopefully new tplot variables are created
    HISTORY:
     7-jun-2007, jmm, jimm@ssl.berkeley.edu
     19-oct-2010, jmm, Added a comment to trigger a new snapshot
     30-jul-2013, jmm, Added another comment, to check SVN
     27-jan-2014, jmm, Another SVN test comment, to check how SVN switch
                       works, but this comment is different. If svn
                       switch work as expected then this comment will be
                       retained in my local SVN working directory.
     12-Feb-2014, jmm, Testing SVN messaging
     12-feb-2014, jmm, Another SVN test
    $LastChangedBy: jimm $
    $LastChangedDate: 2014-02-12 16:01:10 -0800 (Wed, 12 Feb 2014) $
    $LastChangedRevision: 14369 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_userdef.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_userdef.pro)

## THM_UI_VALID_DTYPE

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     thm_ui_valid_dtype
    PURPOSE:
     get valid datatype names from thm_load_* routines, using the
     valid_names keyword and returns a list of data types that can be
     loaded for each instrument.
    CALLING SEQUENCE:
     datalist = thm_ui_valid_dtype(instrument, ilist, llist)
    INPUT:
     none
    OUTPUT:
     datalist = a list of the datatypes that can be loaded
     instrument = the instrument responsible for this datatype
     ilist = a list of the input instrument replicated for each datalist
             element
     llist = the level of the data, some have 'l1', some have 'l2' some
             have one for each
    HISTORY:
     16-jan-2007, jmm, jimm@ssl.berkeley.edu
     29-jan-2007, jmm, various changes, now station isn't returned, gmag
     and asi output are hard-wired, other changes will ensue when load
     routines are standardized.
     4-feb-2007, jmm, Rewritten back to the old hard-wired version....
     5-jul-2007, jmm, Added level information
     11-apr-2008, jmm, now calls thm_data2load.pro, for 1 instrument
    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_valid_dtype.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_valid_dtype.pro)

## THM_UI__SCMCAL_HELP

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
    thm_ui__scmcal_help
    PURPOSE:
     A widget to display the file 'thm_gui.txt' help

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_scmcal_help.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_scmcal_help.pro)

## TPWRSPC[1]

[Previous Routine] [Next Routine] [List of Routines]

    NAME:
     tpwrspc
    PURPOSE:
     wapper for pwrspc.pro for calling from GUI, a split_vec is performed
     on the data if necessary
    CALLING SEQUENCE:
     thm_ui_pwrspc, varnames, new_names, trange, history_ext, $
                    polar = polar, dynamic = dynamic, _extra = _extra
    INPUT:
     varnames = an array (or scalar) of tplot variable names
    Output
     new_names = the variable names of any new variables
    HISTORY:
     28-mar-2007, jmm, jimm.ssl.berkeley.edu
     2-apr-2007, jmm, added the /dynamic keyword
     5-jun-2007, jmm, no longer handles history

    $LastChangedBy: cgoethel $
    $LastChangedDate: 2008-07-08 08:41:22 -0700 (Tue, 08 Jul 2008) $
    $LastChangedRevision: 3261 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/thm_ui_pwrspc.pro $

(See projects/themis/deprecated/thm_ui/thm_ui_pwrspc.pro)

## YESNO_WIDGET_FN

[Previous Routine] [List of Routines]

    NAME:
     yesno_widget_fn
    PURPOSE:
     Simple widget that asks for a yes or no
    CALLING SEQUENCE:
     yn=yesno_widget_fn(title, list = list, _extra = _extra)
    INPUT:
     title = a title, or a question
    OUTPUT:
     yn = 0 for no, 1 for yes
    KEYWORDS:
     list, a string array to put in the widget, as an aid
    HISTORY:
     27-nov-2006, jmm, jimm@ssl.berkeley.edu
     31-jul-2007, jmm, added /enable_yes_always button, default behavior
                  is to not allow this sort of thing
     27-mar-2008, jmm, just added this comment to test SVN from my PC..
     27-mar-2008, jmm, another comment to test SVN from my PC..
     10-apr-2008, jmm, another test of SVN
     29-apr-2008, jmm, another test of SVN
    $LastChangedBy: egrimes $
    $LastChangedDate: 2014-07-08 09:29:52 -0700 (Tue, 08 Jul 2014) $
    $LastChangedRevision: 15528 $
    $URL: svn+ssh://thmsvn@ambrosia.ssl.berkeley.edu/repos/spdsoft/trunk/projects/themis/deprecated/thm_ui/yesno_widget_fn.pro $

(See projects/themis/deprecated/thm_ui/yesno_widget_fn.pro)