~cvs/scrib/doc/HIERARCY.html

# ~cvs/scrib ("script lib")

`scrib' is a cvs module of scripts and TCL procs for scripting med with an easily-configurable Wish/Tk application.

## explanation of scrib directories: ~/cvs/scrib/*

1. `app_*` : config files for any application utilizing scripts/ and lib/ files.

2. `app_example` : config files for a sample of such a scrib application

3. `lib` : files containing tcl procs for use in scripts/ and app_*/ files

4. `scripts` : files containing scripts which script med, using procedures in lib/.

5. `icons` : icons used for guis in app_* modules

6. `med_menus` : menus for configuring the med gui appearance

7. `params` : various parameter files, e.g. for nastran

8. `doc` : for things like this file

## scrib applications (app_*)

1. app_example : a sample application, run with the $ICEM_SCRIB/run_example file
2. app_bsm_$site : batch surface meshing, run with the $ICEM_SCRIB/bsm_$site file

## scrib (global) variable

1. `proc_scrib_data`: this array is set in the app_*/procedure.tcl file. it is written to and accessed in the generated current_med_script.tcl which is generated from scripts/*.tcl files. ideally, the proc_scrib_data array should NOT be accessed or set in lib/*.tcl files.

## scrib directories: app

! files in this directory ought not be modified for any reason by anyone but jason ! stuff will start to break !

## scrib directories: lib

1. files in this directory are arranged by usage, and each proc's name points to it's location, e.g. the proc scrib_lib_uns_* is in ~cvs/scrib/lib/uns.tcl. the purpose of this is to make the location of procs obvious when encountered in ~cvs/scrib/app_*/ and ~cvs/scrib/scripts/ files.
2. lib/*.tcl files should, ideally, act only on the given arguments along with the current mesh or geometry object. this will allow procs in ~cvs/scrib/lib/*.tcl files to be sourced in med outside the context of a scrib application.
3. the list of those files in the lib directory which are sourced is found in ~cvs/scrib/lib/config.tcl. if you add a file to the lib directory, one ought to add it to the list of file roots in the args to the command scrib_lib_source_files_set in that file.
4. to generate an HTML document specification of the procs available in the ~cvs/scrib/lib/*.tcl files, type scrib_app_document_self in the Messages window.

## scrib directories: scripts

1. ideally, each script would do little more than call ic_ and scrib_lib_* functions.
2. the contents of these script files are written to the current_med_script.tcl and wrapped in the currrent proc_scrib_data array and some other set-up information.
3. the current_med_script.tcl is able to be run in med with the function "File > Scripting > Run script".

## scrib directories: params

1. files in this directory contain various parameters used, e.g. those for nastran.

------------------------------------------------------

author: jason k. aftosmis (jason at icemcfd dot com), april 2002