-------------------------------
Transformation from Lisp to Tk
-------------------------------

Lisp:	(Tkcmd <interp> &rest <args>)

<interp> : The interpreter id bound by tk-init-session.

<args>   : The following rules apply:

	   1. Lisp strings are unchanged. (Any argument which has any 
	      upper case characters must be enclosed in quotes.)

	   2. Lisp atoms are converted to lowercase print strings.

	   3. Lisp keywords are converted to lowercase strings with the
		colon (":") character replaced by a hyphen ("-").

	   4. Lisp lists are converted to Tcl lists by replacing the
	      enclosing parenthesis with Tcl list delimiters "{}" and
	      recursively applying rules 1-4.

---------
Examples:
---------

  1. Case sensitivity

     Tk:   option readfile Demo.opt widgetDefault
     Lisp: (Tkcmd *interp* 'option 'readfile "Demo.opt" "widgetDefault")

     Note: "Demo.opt" and "widgetDefault" must be enclosed in quotes, since 
	   both are case sensitive.

     Alternatively, this could have been:

	   (Tkcmd *interp* "option" "readfile" "Demo.opt" "widgetDefault")

	Or even,

	   (Tkcmd *interp* "option readfile" "Demo.opt" "widgetDefault")
	   (Tkcmd *interp* "option readfile Demo.opt widgetDefault")

        You can always put as much of the command in strings as you want 
	(to be passed verbatim to Tcl).


  2. Lists

     Tk:   pack append . .title {left padx 5 expand}
     Lisp: (Tkcmd *interp* 'pack 'append "." '.title '(left padx 5 expand))

     Note: "." must be in quotes since '. isn't allowed by the Lisp reader.
	   But, '.title is ok. If the actual widget name were say, .bTitle,
   	   (mixed case), it would have to be enclosed in quotes and the 
	   Lisp command would be:

	   (Tkcmd *interp* `pack 'append "." ".bTitle" '(left padx 5 expand))


  3. Keywords

     Tk:   button .exit -text Quit -command cleanup_and_exit
     Lisp: (Tkcmd *interp* 'button '.exit :text "Quit" :command 'cleanup_and_exit)

     Note: cleanup_and_exit has either been defined at the Tcl level or
           via the Lisp def-tcl-command.

  4. String escaping

     Tk:   button .sample -text "Sample and Hold" -command "puts Sampling ..."
     Lisp: (Tkcmd *interp* 'button ".sample" 
		           :text "\"Sample and Hold\""
			   :command "\"puts Sampling ...\"")

     Note: When double-quoted strings are required, the quotes have to be
           escaped.

  5. A case not handled very well.

     Tk:   button .add -command [ puts [ add 3 3 ] ]
     Lisp: (Tkcmd *interp* 'button ".add" :comand "[ puts [ add 3 3 ] ]")

     Note: I'd like to see something better than double quoting the command.  
