Technical Notes on Suprem TCL shell

Technical Notes on Suprem TCL shell

Contents

How to define a new Suprem command

  1. define valid parameters by inserting a Parser_ParameterDef table in syntaxDefinition.c
  2. insert a typedef for command specific data structure used to hold the actual parameter values in commandDefinition.h
  3. insert a Sup_WrapperData structure appropriate for the command into commandHandler.c
  4. insert appropriate declarations for the Parser_ParameterDef and the Sup_WrapperData in commandDefinition.h
  5. registers new command with the Tcl Interpretter by adding in appropriate Tcl_CreateCommand line in tkAppInit.c

Description of the Files

Include Files C Files

Calling Sequence

   --------> Tcl_Interpreter
  |                 |command line, 
  |                 |Appropriate Sup_WrapperData
  |                 |
  |                 V         command line
  |            Sup_Wrapper ---------------> Parse_Argv
  |                                              |
  |                                              |Translated command line
  |                                              V
  |                                         Parser_ProcessParameters
  |                                              |
  |                                              |Filled in WidgetRec
  |                                              V
  |                                              *
  |                                              |Packaged Sup_CommandData
  |                                              V
Appropriate Suprem Command <-------------------  *
                            Casted pointer to int

Description of Data Types

Error Reporting