Commit of 4.0.0 version

This commit is contained in:
Erick Gallesio 1999-09-05 13:16:41 +02:00
parent 956ab227cc
commit a6b9113d17
397 changed files with 28279 additions and 31522 deletions

18
CHANGES
View File

@ -1,9 +1,25 @@
09/03/99 Release 4.0.0
----------------------
Mains changes/modifications since 4.0 are:
* Lot of Win32 fixes
* <Scroll-Frame>, <Toolbar> STklos classes.
* Integration of some finals SRFI (0, 2, 6, 8)
* define-syntax (but not let-syntax and let-syntax*)
* Lot of bug fixes.
* New License Policy (request for commercial apps no more needed).
02/02/99 Release 3.99.4
-----------------------
Mains changes/modifications since 3.99.3 are:
* Works on Windows too (need some more testing, since this is
far form perfect)
far from perfect)
* A console mode (which is used by default on Windows, but can
be used with the -console option on Unix)

View File

@ -2,15 +2,16 @@ Since I'm not a lawyer, I don't know where to put copyrigth notices
and permission notices of softwares I use. Consequently I put them here in
hope it's sufficient....
Note:
STk licence seems not to be as clear as I hope. The main idea is
that you can do what you want with STk. You can even use it in
commercial products. The only restriction is that you must prevent me
if you intend to use it in a commercial product (so I can send you a
"written permission" for efectively using it). The goal is not to
restrict commercial applications but only to count them. If someone,
fluent in english and which like those aspects, can help me to make
things clearer...
Note:
For version 4.0, the clause for commercial software in the STk
license has been deleted. That means that you can make a commercial
product which uses STk without asking me permission to do so, as it
was required before. The idea of this clause was not to restrict
commercial applications but rather to count them. However, it seems
that this clause was more harmful than useful. Anyway, if you make a
commercial product which uses STk, it would be kind to tell me so.
==============================================================================
@ -109,18 +110,17 @@ STk Copyright
-------------
/*
* Copyright © 1993-1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* This software is a derivative work of other copyrighted softwares; the
* copyright notices of these softwares are placed in the file COPYRIGHTS
*
*/
*/

505
ChangeLog
View File

@ -1,3 +1,508 @@
1999-09-05 Erick Gallesio <eg@unice.fr>
* Release 4.0.0
* STk.prj: Added the file Combobox.stklos
1999-09-04 Erick Gallesio <eg@unice.fr>
* Demos/server.stk : Set the process in a variable to avoid the
socket be closed when a GC occurs.
* Win32: some minor corrections
1999-09-03 Erick Gallesio <eg@unice.fr>
* First package named 4.0 (Let's pray).
* New Copyright applied to all the files which need it. The new
copyright deletes the restriction on commercial applocations.
* Tk/generic/tkConfig.c (DoConfig): Correction of a long standing
bug signalled by Brian Denheyer <briand@deldotd.com>about the
environments which were garbaged on checkbutton menu entry.
* configure.in : Modifications for RPM 3.0 packaging
1999-09-01 Erick Gallesio <eg@unice.fr>
* Src/syntax.c (syntax_let_family): Bug correction in named let:
the scope of the name of a * named let encloses only the body of
the let and not the * initialization values of the bound
variables. That means that
(let ((f -)) (let f ((n (f 1))) n)) => -1
rather than 1. This (apparently very common) bug was signaled in
comp.lang.scheme.
* Src/print.c (STk_print): Deleted an extra close parenthesis when
printing a local var.
1999-08-31 Erick Gallesio <eg@unice.fr>
* Lib/srfi-7.stk: New file for SRFI-7 (PROGRAM)
* Src/syntax.c (STk_syntax_begin): Accepts now the form "(begin)"
without complaining about a null body
* Src/port.c : slight modification to input-port? primtive: it
returns #t for all the input port (i.e. file, string and virtual
port) instead of the file port only. A new primitive as been
added: input-file-port? for testing explicitly if an object is an
input port. Of course, the same applies also for output. This
change was needed to be conform to SRFI-6.
1999-08-30 Erick Gallesio <eg@unice.fr>
* Lib/defsyntax.stk : R4RS define-syntax. This is the Macro By
Example implementation from Dorai Sitaram <dorai@cs.rice.edu>
adapted for STk.
* Lib/srfi-0.stk: New file implementing srfi-0
* Lib/srfi-2.stk: New file implementing srfi-2
1999-08-24 Erick Gallesio <eg@unice.fr>
* Demos/widget.stk (show-code): Changed the way the code file is
read to work under Win32 too.
1999-08-23 Erick Gallesio <eg@unice.fr>
* Lib/init.stk (STk): Changed the time where the autoload of the
graphical error routine is done, so that an error during the
reading of initialization file doesn't pop this weird black empty
window on the screen.
* Src/port.c (STk_close_file_port): closing a closed file with
fclose on glibc2.1.1 dumps core. fclose has been replaced by a
fflush and a close.
* Lib/winsocket.stklos : New file which implements sockets for
Win32. This file is a contribution of Steve Pruitt
<steve@pruitt.net>
1999-08-22 Erick Gallesio <eg@unice.fr>
* Demos/console-demo.stk: New (simple) demo showing the console in
action.
* Makefile.in (install-no-strip): New entry to install the
executable without stripping them. This was needed by Brian
Denheyer <briand@deldotd.com>
* Lib/console.stk : Added scrollbar in the list of modules when
choosing a new console
1999-08-19 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Paned.stklos (): Made the fraction of a
paned an active slot. This was requested by Andrew Dorrell
<andrewd@mountains.net.au>
1999-08-18 Erick Gallesio <eg@unice.fr>
* Demos/widget.stk :Changed the Quit button by a new toolbar for
the widget Demo.
1999-08-16 Erick Gallesio <eg@unice.fr>
* Doc/Reference/Reference*.tex: Big documentation update.
* Src/io.c (STk_internal_flush): Changed the implementation of
virtual port and make some cleanups. everything is documented now.
1999-08-15 Erick Gallesio <eg@unice.fr>
* Lib/console.stk : Clos console menu didn't exit the interpreter
on the main console.
* Lib/help.stk: Modified the help function to deiconify the
browser if it already exists
* Src/stk.h: Conditionally define TRUE and FALSE as requested by
Shiro Kawai <shiro@squareusa.com>
* Lib/console.stk : New menu in
console to allow to open a new console in a given module.
* Src/module.c (STk_all_modules): New primitive "all-modules"
which returns the list of all the living modules.
1999-08-12 Erick Gallesio <eg@unice.fr>
* Lib/www-url.stk (merge-paths): modified to take into account Win32
* Lib/fs.stk: * Lib/win32.stk: fs.stk is the file which will load
either unix.stk or win32.stk depending of the running system.
* Lib/image.stk : Changed the images are searched. It didn't work
for Win32
1999-08-04 Erick Gallesio <eg@unice.fr>
* Lib/console.stk (console-splash-screen): compute geometry with
quotient rather than "/" (useful for people with odd
resolutions. Yes it exists!)
1999-08-03 Erick Gallesio <eg@unice.fr>
* Src/unix.c: Modifications to parse correctly DOS filenames.
This is probably not completely correct (DOS guys are really
crazy).
* Lib/www-url.stk (url-regexp): Changed the regexp for parsing
correctly DOS filename (C:\\A was seen as the path \\A for the
service "C")
1999-07-02 Erick Gallesio <eg@unice.fr>
* Src/error.c (STk_err): the assignment of the two global is done
now in STk_err to have it even in the context of a CATCH. Patch
provided by Ian Wild <ian.wild@eurocontrol.be>.
* Lib/balloon.stk ((display-balloon-help w)): Correction of a bug
which apperas when the window to which a ballon is associated does
not exists anymore.
* Lib/dialog.stk:
* Lib/error.stk:
* STklos/Tk/Composite/Msgbox.stklos (): Added more colorful icons
for the standard message boxes
1999-07-01 Erick Gallesio <eg@unice.fr>
* STklos/stklos.stk:
* Src/stklos.c (next_method_exists): New primitive in STklos:
next-methods-exists?
1999-06-30 Erick Gallesio <eg@unice.fr>
* Src/symbol.c: New primitive string->uninterned-symbol.
* Lib/init.stk (gensym): gensym now use an uninterned symbol.
1999-06-21 Erick Gallesio <eg@unice.fr>
* install.bat: Added the installation of libraries for Win32 as
requested by Jonathan Berry <berryj@elon.edu>
1999-06-19 Erick Gallesio <eg@unice.fr>
* Src/hash.c (hash_table_put):
* Src/tk-glue.c (STk_add_callback): Changed the variable new to
new_entry to be more C++ friendly as requested by Jonathan Berry
<berryj@elon.edu>
1999-06-06 Erick Gallesio <eg@unice.fr>
* Use a coherent scheme for toolbars. All the pixmaps have been
modified.
1999-06-05 Erick Gallesio <eg@unice.fr>
* Doc/Reference/Appendix-C.tex (subsection{Example}): Typo error
signalled by Ben L. Di Vito <bld@air57.larc.nasa.gov>
1999-06-04 Erick Gallesio <eg@unice.fr>
* Src/proc.c (STk_procedurep): Bug corrcetion: procedure? was
returning #t for all STklos instance, it returns #t for
next-methods and descendants of methods now.
(STk_is_thunk): ditto.
* Tcl/tclInt.h: The Tcl List type is now hidden (since it is not
used by STk) . It is a request from Jonathan Berry
<berryj@elon.edu>
1999-05-28 Erick Gallesio <eg@unice.fr>
* Tk/generic/tkCanvLine.c: Added the option :centerarrow for
lines. The implementation was provided by Sarah Calvo
<sarah@grammatech.com>
* STklos/Tk/Canvitem.stklos (<Line>): Added the center-arrow slot
to the <Line> class to take into account the new:centerarrow
option
1999-05-26 Erick Gallesio <eg@unice.fr>
****** All the stuff below has been provided by people at Grammatech
****** <sarah@grammatech.com> & <paul@grammatech.com>
* Tk/generic/tkFrame.c: Declare the menu option of a frame as
a TK_CONFIG_MENU rathere than a TK_CONFIG_STRING.
* Src/tcl-lib.c (Tcl_CreateInterp): flags field was not
initialized.
* Src/stk.h: Added #define USE_PROCESS for Win32
* Src/eval.c: Two new functions for applying 1 or 2 arguments only.
* Src/io.c (STk_StdinProc): initializing errno to 0 before a read
system call.
* Src/dynload.c: Type declaration was uncorrect for a message
issued on architectures without FFI.
* Src/cont.c (STk_throw): On some architecture, the thunk to be
executed on restauration of a continuation should be in a global
rather than a local variable.
* Lib/unix.stk: Win32 adaptations
* Lib/menu.stk: Typos and motion.
* Lib/init.stk: Win32 fixes
* Lib/console.stk (console-invoke): fix of STk Error if there were
multiple regions with "input" tag.
((init-console module std-console?)): color missing on HPUX
replaced by its value.
* configure.in: the --prefix option was not correctly propagated
to Tk and Tcl configure scripts.
* Stack/Makefile.in: new entry install.libs
1999-05-21 Erick Gallesio <eg@unice.fr>
* Src/dynload.c:
* Src/number.c:
* Src/port.c:
* Src/env.c: Some typo errors signalled by David Fox.
* Src/tcl-lib.c (Tcl_CreateCommand): bug correction suggested by
David Fox <dsfox@cogsci.ucsd.edu>
1999-05-20 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Filebox.stklos: When the filebox was first
invoked the "all" button was NOT checked, but the filebox displays
all of the files, i.e., the button doesn't match functionality.
Bug signaled and corrected by Brian Denheyer <briand@deldotd.com>.
* STklos/describe.stklos (describe): Extended types were described
as unknown types, whereas a class is automatically defined for
them.
* Lib/init.stk (STk): added the function repl-write which is used
by the repl-display-result to display results at the toplevel. It
was write*, but it doesn't seem to be appreciated. The new value
is a function which use write or write* for list and write* for
other object. Of course it can be changed by just setting the
repl-write result.
* STklos/Tk/Composite/Hierarchy.stklos: Added the remove-item!
method.
* STklos/Tk/Composite/Toolbar.stklos: Modification of the toolbar
code to allow the inclusion of any widget in a toolbar
1999-05-19 Erick Gallesio <eg@unice.fr>
* Lib/www-browser.stklos (WWW:browser):
* Demos/Widget/Wmenu.stklos (demo-menu):
* Demos/amib.stklos (build-interface): Use the new toolbar widget
instead of simple menu as before.
* Demos/stklos-widgets.stklos: Added the font-chooser demo.
1999-05-18 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Toolbar.stklos (map-toolbar): Added the
convention that spaces of length 0 in a toolbar correspond to a
space which takes all the spaces (i.e. it sets the :expand option
of the packer to #t)
* Lib/menu.stk (Tk:menu-escape menu): code was incorrect when
using the Escape key on a cascade menu.
* STklos/Tk/Composite/*.stklos: Added a class to all the composite
widgets, so that it can be initialized from resources.
* STklos/Tk/Composite/Scrollframe.stklos: Modification to take
into account the width and the height of a Scroll frame.
* STklos/Tk/Font.stklos: New <Font> class which allow to
manipulate fonts as widgets.
1999-05-16 Erick Gallesio <eg@unice.fr>
* Src/dynload.c (push_argument): New convention: #f is now
accepted for speicfing a NULL value for a string or a pointer.
This was already the case for returned values but not for
parameters. thsi was requested by terry jones
<terry@cliffs.ucsd.edu>
* STklos/Tk/Composite/Notepad.stklos (initialize): Set the
highlight thickness of tabs to 0, Otherwise the effect was bad
(unluckily this was the defaut value I set in my .Xdefaults)
* Lib/font-chooser.stklos (pretty): The weight of the font was
missing.
1999-05-13 Erick Gallesio <eg@unice.fr>
* STklos/Examples/E3.stklos: Use a require "Tk-classes" instead of
"Canvas", otherwise *top-root* is improperly initialized
1999-05-11 Erick Gallesio <eg@unice.fr>
* STk.prj: Integration of floating toolbars
* STklos/Tk/Tk-classes.stklos: Integration of toolbars
* STklos/Tk/Composite/Toolbar.stklos: New file which implements
the floating toolbar abstraction. This was really a pain to write
(even if it does not seem complicate afterwards :-<). This is not
complete, but it's time to release...
* STklos/Tk/Menu.stklos: Special clone-widget methods for <menu>
and <menu-button>. This was necessary when cloning a toolbar which
contains a menu.
1999-05-10 Erick Gallesio <eg@unice.fr>
* STk.prj: A pseudo-stable version.
* Src/tcl-obj.c (Tcl_EvalObj): Added code for evaluating a Tcl_obj
expression. I forgot to write the code when new handlers were
introduced for 3.99.4 :-<. Bug signalled by many, really many,
users.
* Lib/palette.stk: New functions: make-rgb-color, make-darker-color
make-lighter-color
* STklos/Tk/Basics.stklos (clone-widget): New generic function.
It allows the creation of a clone of the given widget in another
place in the hierarchy.
1999-05-06 Erick Gallesio <eg@unice.fr>
* Tk/generic/tkFrame.c (TkCreateFrame): Small modification to
allow the specification of a :colormap which is the empty string
for Frames and toplevels. This is needed for cloning frames.
1999-05-02 Erick Gallesio <eg@unice.fr>
* Lib/menu.stk: Some global grabs in the Tcl file were reported as
local grab in STk.
* STklos/Tk/Composite/Combobox.stklos (show/hide-combo-list):
Changed the focus policy for combo boxes
1999-05-01 Erick Gallesio <eg@unice.fr>
* Tk/generic/tkPlace.c: Typo error detected in Biglook and which
seems not harmful in STk.
* Src/vector.c (STk_sort): When sorting a list, there was an
unnecessary copy vector which was allocated. Thanks to Manuel for
signalling this bug.
1999-04-25 Erick Gallesio <eg@unice.fr>
* Demos/stkfontsel.stk: New demo.
* Lib/font-chooser.stklos (): When the user exits the widget
without selecting a font, the old font remains the default one.
1999-04-24 Erick Gallesio <eg@unice.fr>
* Lib/font-chooser.stklos: The font chooser has been completely
rewritten. Now it only use one global variable (instead of 6) and
is cleaner than the older one. The chooser also use the Combobox
composite widget.
1999-04-17 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Text.stklos (text-see): typo error signalled by
Brian Denheyer <briand@deldotd.com>
* Src/argv.c: Added the -version option to stk. This options just
prints the version number and exit the interpreter.
1999-04-06 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Combobox.stklos: New Composite widget.
* STklos/Tk/Tk-classes.stklos (STklos+Tk): Adaptation for the new
composite widget.
1999-04-01 Erick Gallesio <eg@unice.fr>
* Lib/trace.stk (Trace): Correction of a bug which deals with
environments. Bug signaled by Jacques Chazarain <jmch@unice.fr>.
* Src/boolean.c (STk_eqv): Now environment can be compared with
eqv?. Consequently, (eqv? (the-environment) (the-environment))
returns now #t.
1999-03-26 Erick Gallesio <eg@unice.fr>
* STklos/describe.stklos (describe): Used ~W instead of ~S in some
format to avoid infinite loops when describing circular structures.
1999-03-24 Erick Gallesio <eg@unice.fr>
* Src/dynload.c (push_argument): Forgot to implement the boolean case
Patch provided by David Fox <dsfox@cogsci.ucsd.edu>.
* configure.in: Application of corrections for FreeBSD provided by
"F. Heinrichmeyer" <fritz.heinrichmeyer@FernUni-Hagen.de>
* STk.prj: Various bug corrections
* STklos/Tk/Image.stklos (initialize): New method: Pixmap
extension need that the :file or :data be passed when the image
is created => we use a new initialize method rather than the
initialize-image scheme used for bitmaps and photos.
Bug signaled by Brian Denheyer <briand@deldotd.com>
1999-03-13 Erick Gallesio <eg@unice.fr>
* Src/io.c (STk_getc): Correction of a bug on Alpha (OSF does not
seem to set errno to 0 before a read!). Bug signaled by Vincent
Granet <vg@unice.fr>
1999-03-11 Erick Gallesio <eg@unice.fr>
* Tk/generic/tkBind.c: patch to make significant only the first
character of a parameter in a binding lambda (i.e. x1 is now
equivalent to x). Strange behaviour signalled by Brian Denheyer
<briand@deldotd.com>.
* Src/primitives.c: New primitive port-closed?.
1999-02-13 Erick Gallesio <eg@unice.fr>
* Demos/widget.stk: Modification of the path for accessing source
in the widget demo. Thanks to Daniel Ortmann <ortmann@us.ibm.com>
1999-02-10 Erick Gallesio <eg@unice.fr>
* Tk/win/tkWinDialog.c (ProcessCDError): compound options for
standard dialog have now a dash (-initialfile => :initial-file, ...)
to be consistent with Unix.
* Tk/win/tkWinFont.c (WinFontFamilyEnumProc): Modified to
transform font-name into strings rather than symbols.
* Lib/menu.stk (Tk:menu-button-button-up): Typo correction (thanks
to Eric Fintzel <tpfintz@fr.ibm.com>)
* STklos/Tk/Composite/Scrollframe.stklos: Rewritten
1999-02-08 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Scrollframe.stklos: New widget <Scroll-Frame>.
1999-02-02 Erick Gallesio <eg@unice.fr>
* Release 3.99.4: This is the last pre 4.0 version. Code for Win32

View File

@ -95,7 +95,7 @@
;;; ------------------- Include files ------------------------
(require "Tk-classes")
(require "unix")
(require "fs")
(require "dialog")

View File

@ -112,6 +112,12 @@ Running demonstration programs in the STk web browser
1.5 Misc
* console-demo.stk
This is a simple demo showing a repl loop in a console.
Run with: ../Src/test-stk -f console.stk
Comment: This demo is useful for Unix users only, since under Win32 STk
is started with such a console.
* colormap.stk
This is a simple color palette written in STk.
Run with: ../Src/test-stk -f colormap.stk
@ -119,6 +125,10 @@ Running demonstration programs in the STk web browser
offers now the function Tk:choose-color which allow to choose a color
by name or by value.
* stkfontsel.stk
This is a simple program which uses the STk font chooser.
Run with: ../Src/test-stk -f stkfontsel.stk
* small-ed.stk
A small editor to create enhanced text
Run with: ../Src/test-stk -f small-ed.stk
@ -182,6 +192,9 @@ Running demonstration programs in the STk web browser
Comment: Here again, what is interesting in this demo is not what it
does, nothing specially fancy, but how it is easy to program, IMHO.
* classbrowse.stklos This demo shows the STklos class browser.
Run with: ../Src/test-stk -f classbrowse.stklos
2.2 STklos widgets
* widget.stklos
@ -241,6 +254,6 @@ Running demonstration programs in the STk web browser
lines.
Run with: ../Src/test-stk -f S-scape.stklos
------------------------------------------------------------------------
Erick Gallesio
Last modified: Mon Mar 9 19:15:46 CET 1998
Last modified: Sun Aug 22 21:16:13 CEST 1999

View File

@ -1,20 +1,21 @@
;;;; animate.stk -- A simple image animation (Demo)
;;;; animate.stk -- A simple image animation (Demo)
;;;;
;;;; Copyright © 1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1998-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;;
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; $Id: animate.stk 1.1 Tue, 10 Mar 1998 21:43:37 +0100 eg $
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 9-Mar-1998 18:51
;;;;Last file update: 9-Mar-1998 21:07
;;;;Last file update: 3-Sep-1999 18:45 (eg)
(define *img* #f)

View File

@ -1,20 +1,20 @@
;;;; puzzle.stk -- A puzzle written in STk (from the Tcl Demo)
;;;;
;;;; Copyright © 1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1998-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;;
;;;; $Id: puzzle.stk 1.1 Tue, 10 Mar 1998 21:43:37 +0100 eg $
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 9-Mar-1998 21:11
;;;;Last file update: 9-Mar-1998 21:37
;;;;Last file update: 3-Sep-1999 18:50 (eg)
(define (display-puzzle parent)

17
Demos/Makefile Executable file → Normal file
View File

@ -1,10 +1,23 @@
#
# Makefile for the Demos directory
#
# Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
#
# Permission to use, copy, modify, distribute,and license this
# software and its documentation for any purpose is hereby granted,
# provided that existing copyright notices are retained in all
# copies and that this notice is included verbatim in any
# distributions. No written agreement, license, or royalty fee is
# required for any of the authorized uses.
# This software is provided ``AS IS'' without express or implied
# warranty.
#
# Last file update: 3-Sep-1999 19:20 (eg)
#
include ../config.make
DEMODIR=$(libdir)/Demos
DEMODIR=$(root)$(libdir)/Demos
what:
@echo "Type make install to install demos"
@ -25,7 +38,7 @@ install:
cp Html-Demos/*.html $(DEMODIR)/Html-Demos
chmod 0644 $(DEMODIR)/Html-Demos/*.html
mkdir $(DEMODIR)/Html-Demos/Images; chmod 0755 $(DEMODIR)/Html-Demos/Images
cp Html-Demos/Images/* $(DEMODIR)/Html-Demos/Images
cp Html-Demos/Images/*.gif $(DEMODIR)/Html-Demos/Images
chmod 0644 $(DEMODIR)/Html-Demos/Images/*
(cd $(DEMODIR)/Html-Demos; ln -s ../amib.stklos ../stklos-widgets .)

View File

@ -1,7 +1,7 @@
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<title>Demo directory README (Version 3.99 - March 1998)</title>
<title>Demo directory README (Version 4.0 - August 1999)</title>
</head>
<body bgcolor="#FFFFFF">
@ -194,6 +194,17 @@
<h4>1.5 Misc </h4>
<ul>
<p><li>
<b>console-demo.stk</b>
<br>
This is a simple demo showing a repl loop in a console.
<br>
<u>Run with</u>:
<A expr=(run "console-demo.stk")> ../Src/test-stk -f console.stk </A>
<br>
<u>Comment</u>: This demo is useful for Unix users only, since under
Win32 <B>STk</B> is started with such a console.
<p><li>
<b>colormap.stk</b>
<br>
@ -206,6 +217,14 @@
<B>STk</B> offers now the function <tt>Tk:choose-color</tt>
which allow to choose a color by name or by value.
<p><li>
<b>stkfontsel.stk</b>
<br>
This is a simple program which uses the STk font chooser.
<br>
<u>Run with</u>:
<A expr=(run "stkfontsel.stk")> ../Src/test-stk -f stkfontsel.stk </A>
<p><li>
<b>small-ed.stk</b>
<br>
@ -444,7 +463,7 @@
<address><a href="mailto:eg@unice.fr">Erick Gallesio</a></address>
<!-- Created: Sun Mar 1 15:56:45 CET 1998 -->
<!-- hhmts start -->
Last modified: Sat Sep 26 18:44:39 CEST 1998
Last modified: Sat Sep 4 15:02:13 CEST 1999
<!-- hhmts end -->
</body>
</html>

22
Demos/S-scape.stklos Executable file → Normal file
View File

@ -3,19 +3,21 @@
;;;;
;;;; S - s c a p e . s t k l o s -- A simple WEB browser
;;;;
;;;; Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Copyright © 1996-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;;
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 3-Nov-1996 18:44
;;;; Last file update: 2-Mar-1998 09:42
;;;; Last file update: 3-Sep-1999 19:13 (eg)
;;;;
(require "www-browser")

View File

@ -34,7 +34,7 @@
`(command :label ,mess :background ,mess
:command ,(lambda () (format #t "You invoked ~S\n" mess))))
(define f (make-menubar w
(define f (make-toolbar w
`(("File"
("Open ..." ,(lambda () (mess "Open ...")))
("New" ,(lambda () (mess "New")))
@ -59,16 +59,16 @@
,(print-hello-goodbye "Hello" "a")
,(print-hello-goodbye "Goodbye" "b")
("Check buttons"
((check :label "Oil checked" :variable oil)
(check :label "Oil checked" :variable oil)
(check :label "Transmission checked" :variable trans)
(check :label "Brakes checked" :variable brakes)
(check :label "Lights checked" :variable lights)
("")
("Show current values"
,(lambda ()
(show-variables w '(oil trans brakes lights))))))
(show-variables w '(oil trans brakes lights)))))
("Radio buttons"
((radio :label "10 point" :variable point-size :value 10)
(radio :label "10 point" :variable point-size :value 10)
(radio :label "14 point" :variable point-size :value 14)
(radio :label "18 point" :variable point-size :value 18)
(radio :label "24 point" :variable point-size :value 24)
@ -79,7 +79,7 @@
(radio :label "Italic" :variable style :value "italic")
("")
("Show current values"
,(lambda () (show-variables w '(style point-size)))))))
,(lambda () (show-variables w '(style point-size))))))
("Icons"
(command :bitmap ,(string-append "@" *stk-images* "/pattern")
:command ,(lambda ()
@ -106,10 +106,10 @@
(slot-set! f 'border-width 3)
(slot-set! f 'relief "raised")
(pack f
(make <Label> :parent w
(let ((lab (make <Label> :parent w
:wrap-length "4i"
:justify "left"
:font demo-font
:text txt)
:expand #t :fill "x")))
:text txt)))
(pack f lab :expand #t :fill "x")
(set! (release-command f) (default-release-toolbar lab)))))

29
Demos/amib.stklos Executable file → Normal file
View File

@ -4,20 +4,20 @@
;;;; a m i b . s t k l o s -- A mini interface builder. I hope it will serve
;;;; as the basis of something more complete...
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Copyright © 1995-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 22-May-1995 14:56
;;;; Last file update: 1-Feb-1999 17:56
;;;; Last file update: 3-Sep-1999 19:13 (eg)
(require "Tk-classes")
@ -162,15 +162,18 @@
("Quit" ,quit))
(" Toplevel "
("Create" ,new-amib-toplevel))
((" Help " :side "right" :fill "x")
0
(" Help "
("About" ,(lambda ()
(stk:show-help-file "amib-abt.html")))
("Help" ,(lambda ()
(stk:show-help-file "amib-hlp.html"))))))
;; Menu bar
(bar (make-menubar *top-root* menus))
;; Widget Panel
(chooser (make <Scroll-Listbox> :value (map car *table-defaults*)))
;; Menu bar
(bar (make-toolbar *top-root* menus :relief "ridge" :border-width 2
:release-command
(default-release-toolbar chooser)))
(lb (listbox-of chooser)))
;; Associate new bindings to the listbox

15
Demos/browse.stk Executable file → Normal file
View File

@ -3,16 +3,25 @@
;;;;
;;;; A simple STk browser
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;;
;;;; This script generates a directory browser, which lists the working
;;;; directory and allows you to open files or subdirectories by
;;;; double-clicking.
;;;; This is a new version of the demo which can be run before STk is installed
;;;;
;;;; $Id: browse.stk 1.4 Tue, 02 Feb 1999 09:04:21 +0100 eg $
;;;; This is a new version of the demo which can be run before STk is installed
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 3-Aug-1993 17:33
;;;; Last file update: 2-Feb-1999 08:45
;;;; Last file update: 3-Sep-1999 19:12 (eg)
(require "unix")

15
Demos/browse.stklos Executable file → Normal file
View File

@ -3,15 +3,24 @@
;;;;
;;;; A simple STk browser
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; This script generates a directory browser, which lists the working
;;;; directory and allows you to open files or subdirectories by
;;;; double-clicking.
;;;;
;;;; $Id: browse.stklos 1.4 Tue, 02 Feb 1999 09:04:21 +0100 eg $
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 3-Aug-1993 17:33
;;;; Last file update: 2-Feb-1999 08:45
;;;; Last file update: 3-Sep-1999 19:12 (eg)
(require "Tk-classes")
(require "unix")

20
Demos/calc.stklos Executable file → Normal file
View File

@ -3,21 +3,21 @@
;;;;
;;;; c a l c . s t k l o s -- A very simplistic calculator
;;;;
;;;; Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1995-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;;
;;;; $Id: calc.stklos 1.2 Mon, 16 Feb 1998 08:28:39 +0100 eg $
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 6-Apr-1995 18:11
;;;; Last file update: 12-Feb-1998 11:28
;;;; Last file update: 3-Sep-1999 19:13 (eg)
(require "Tk-classes")
(define Result 0)

20
Demos/classbrowse.stklos Executable file → Normal file
View File

@ -2,21 +2,21 @@
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;; classbrowse.stk -- Demonstration of the STk class browser
;;;;
;;;; Copyright © 1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1998-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;;
;;;; $Id: classbrowse.stklos 1.1 Sat, 26 Sep 1998 19:19:52 +0200 eg $
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 26-Sep-1998 19:12
;;;; Last file update: 26-Sep-1998 19:13
;;;; Last file update: 3-Sep-1999 18:55 (eg)
;; A Demo which is quite easy to write
(class-browser *top-root*)

17
Demos/colormap.stk Executable file → Normal file
View File

@ -3,17 +3,18 @@
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 19-Aug-1993 15:08
;;;; Last file update: 1-Feb-1999 18:34
;;;; Last file update: 3-Sep-1999 18:56 (eg)
(define Color "#000000")
(define V (vector 0 0 0))

25
Demos/console-demo.stk Normal file
View File

@ -0,0 +1,25 @@
;;;; console-demo.stk -- A simple demo for the console
;;;;
;;;; Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 22-Aug-1999 21:05
;;;; Last file update: 3-Sep-1999 18:56 (eg)
;;; This demo is only useful for Unix users since the console is implicit
;;; for Win32
(require "console")
(make-console)

22
Demos/filebox.stklos Executable file → Normal file
View File

@ -5,22 +5,18 @@
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS
;;;;
;;;; $Id: filebox.stklos 1.3 Tue, 02 Feb 1999 15:29:27 +0100 eg $
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 12-Jun-1994 11:24
;;;; Last file update: 2-Feb-1999 13:56
;;;; Last file update: 3-Sep-1999 18:57 (eg)
(require "Tk-classes")

27
Demos/hanoi.stk Executable file → Normal file
View File

@ -1,11 +1,24 @@
#!/usr/local/bin/stk -f
;;
;; Hanoi - Towers of Hanoi diversion
;;
;; This program is a rewriting in STk of a program found on the net. Original
;; author is Damon A Permezel (probably fubar!dap@natinst.com)
;; Re-writing is very direct and needs much more working
;;
;;;;
;;;; Hanoi - Towers of Hanoi diversion
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Last file update: 3-Sep-1999 19:22 (eg)
;;;; This program is a rewriting in STk of a program found on the net. Original
;;;; author is Damon A Permezel (probably fubar!dap@natinst.com)
;;;; Re-writing is very direct and needs much more working
;;;;
(define *gc-verbose* #f)

16
Demos/hello.stk Executable file → Normal file
View File

@ -1,5 +1,21 @@
#!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Last file update: 3-Sep-1999 19:25 (eg)
;; Simple Tk script to create a button that prints "Hello, world".
;; Click on the button to terminate the program.
;;

16
Demos/hello.stklos Executable file → Normal file
View File

@ -1,5 +1,21 @@
#!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Last file update: 3-Sep-1999 19:25 (eg)
;; Simple Tk script to create a button that prints "Hello, world".
;; Click on the button to terminate the program.
;;

19
Demos/inspector.stk Executable file → Normal file
View File

@ -2,19 +2,20 @@
;;;;
;;;; i n s p e c t o r . s t k -- A very simple demo of the inspector
;;;;
;;;; Copyright © 1993-1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 22-Jan-1995 18:09
;;;; Last file update: 22-Jan-1995 18:10
;;;; Last file update: 3-Sep-1999 18:57 (eg)
(label '.l1 :text "Click on a node of the viewer to see the selected widget"

27
Demos/mc-server.stk Executable file → Normal file
View File

@ -3,22 +3,20 @@
;;;; m c - s e r v e r . s t k -- A simple server which accept
;;;; multiple client connections
;;;;
;;;; Copyright © 1993-1997 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 23-Jul-1996 09:00
;;;; Last file update: 11-Oct-1997 10:14
;;;; Last file update: 3-Sep-1999 18:58 (eg)
(require "posix")
(require "socket")
@ -43,7 +41,7 @@
(flush out)
;; Signal new connection on standard output
(format #t "New connection detected from ~A (~A)\n" who addr)
(format #t "New connection (#~S) detected from ~A (~A)\n" cnt who addr)
;; Create a handler for reading inputs from this new connection
(when-port-readable in
@ -55,7 +53,8 @@
(begin
(when-port-readable in #f)
(socket-shutdown s)
(set! sockets (remove s sockets)))
(set! sockets (remove s sockets))
(format #t "Connection #~S closed.\n" cnt))
;; Just write the line read on the socket
(begin
(format out "On connection #~S I've read --> ~A\n" cnt l)

25
Demos/server.stk Executable file → Normal file
View File

@ -1,24 +1,25 @@
#!/usr/local/bin/stk -f
;;;; s e r v e r . s t k -- A simple sever
;;;;
;;;; Copyright © 1993-1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 4-Feb-1995 18:17
;;;; Last file update: 12-Feb-1995 11:57
;;;; Last file update: 4-Sep-1999 15:32 (eg)
(define s (make-server-socket))
(define p (run-process ; define a var to avoid GC problems
"xterm" "-e" "telnet" "localhost"
(number->string (socket-port-number s))))
(dynamic-wind
;; Init: Launch an xterm with telnet running on the s listening port and connect

View File

@ -1,22 +1,24 @@
#!/bin/sh
:;exec /usr/local/bin/stk -l "$0" "$@"
;;
;; show-vars w var var var ...
;;
;; Create a top-level window that displays a bunch of global variable values
;; and keeps the display up-to-date even when the variables change value
;;
;; Arguments:
;; w - Name to use for new top-level window.
;; var - Name of variable to monitor.
;;
;;
;; Note that this demo is run with the -l option (instead of the classical -f)
;;
;;
;; Author: Erick Gallesio [eg@unice.fr]
;; Creation date: 9-Aug-1993 22:06
;; Last file update: 2-Mar-1998 00:25
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; show-vars w var var var ...
;;;;
;;;; Create a top-level window that displays a bunch of global variable values
;;;; and keeps the display up-to-date even when the variables change value
;;;;
;;;; Arguments:
;;;; w - Name to use for new top-level window.
;;;; var - Name of variable to monitor.
;;;;
;;;;
;;;; Note that this demo is run with the -l option (instead of the classical -f)
;;;;
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 9-Aug-1993 22:06
;;;; Last file update: 3-Sep-1999 19:23 (eg)
(define (show-vars w . args)
(catch (destroy w))

22
Demos/small-ed.stk Executable file → Normal file
View File

@ -2,22 +2,20 @@
;;;; s m a l l - e d . s t k -- A small editor to create enhanced
;;;; text (used for Help page construction)
;;;;
;;;; Copyright © 1993-1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 6-Dec-1993 17:25
;;;; Last file update: 26-Nov-1994 10:41
;;;; Last file update: 3-Sep-1999 18:58 (eg)
(require "editor")

23
Demos/stkfontsel.stk Normal file
View File

@ -0,0 +1,23 @@
;;;; s t k f o n t s e l . s t k l o s -- A demo of the font chooser
;;;;
;;;; Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 25-Apr-1999 19:35
;;;; Last file update: 3-Sep-1999 18:59 (eg)
(require "font-chooser")
(let ((f (make-font-chooser)))
(if f
(format #t "You have selected the font ~S\n" f)
(format #t "You have aborted font selection\n")))

17
Demos/stklos-demo.stklos Executable file → Normal file
View File

@ -4,17 +4,18 @@
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 24-Aug-1993 19:55
;;;; Last file update: 2-Feb-1999 08:45
;;;; Last file update: 3-Sep-1999 19:00 (eg)
(require "Tk-classes")

17
Demos/stklos-demo2.stklos Executable file → Normal file
View File

@ -4,17 +4,18 @@
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 24-Aug-1993 19:55
;;;; Last file update: 2-Feb-1999 08:45
;;;; Last file update: 3-Sep-1999 19:00 (eg)
(require "Tk-classes")

View File

@ -20,7 +20,8 @@
(define composite-widgets '(Choice-box
Color-Box
Default-button
File-box
File-box
Font-chooser
Gauge
Help-Balloon
Hierarchy-Tree
@ -32,6 +33,7 @@
Scroll-Canvas
Scroll-Listbox
Scroll-text
Toolbar
Valued-Gauge))
(for-each (lambda (x)
@ -55,7 +57,7 @@
;=============================================================================
(define (demo-color-box)
(let ((f (make <Color-Box> :value "gray75")))
(let ((f (make <Color-Box> :value "gray75" :title "Color Box Demo")))
(colorbox-wait-result f)))
;=============================================================================
@ -185,9 +187,8 @@
;; Make a Menu bar
;;
(define tl (make <Toplevel> :title "Multiple and Inner windows demo"))
(define top (make <Frame> :parent tl))
(define col '#("violet" "skyblue1" "Misty Rose" "Plum" "grey40"))
(define menu (make-menubar top
(define menu (make-toolbar tl
`(("Menu"
("Add one" ,(let ((counter 0))
(lambda ()
@ -198,14 +199,16 @@
(set! counter (1+ counter)))))
("")
("Quit" ,(lambda () (destroy tl)))))))
(pack menu :side "left" :expand #f)
(pack top :fill "x")
(pack menu :side "top" :expand #f :fill 'x)
;;
;; Make a multiple window
;;
(define f (make <Multiple-window> :parent tl :background "cyan4"))
(pack f :fill "both" :expand #t)
;; Attach the floting toolbar to the f widget
(slot-set! menu 'release-command (default-release-toolbar f))
(define f1 (make <Inner-window> :parent f :title "A Text window"))
(define f2 (make <Inner-window> :parent f :title "A canvas window"))
(demo-scroll-text f1)
@ -272,4 +275,71 @@
(make <Notepad-Tab> :parent f :text "host2" :action Host)
(make <Notepad-Tab> :parent f :text "Multi-line\nlabel" :action Mess)
(make <Notepad-Tab> :parent f :bitmap "questhead" :width 30 :action Host)))
;==============================================================================
(define (demo-toolbar)
(define-macro (P x) ; A macro for printing traces (for this demo)
`(lambda () (display ,x) (newline)))
(define top (make <toplevel> :title "Toolbar Demo"))
(define st (make <Scroll-Text> :parent top :font '(Helvetica 18 bold)
:width 48 :height 12
:value (& "\n\n\n"
"\tTo re-attach a detached toolbar, drag it on\n"
"\tone of the 4 sides of this text editor")))
(define action (default-release-toolbar st))
(define f1
(make-toolbar *top-root*
`(("File"
("---") ;; we want a tear-off
("Open" ,(P "Open"))
("Close" ,(P "Close"))
("") ;; insert a separator
("Exit" ,(lambda() (exit 0))))
("Edit"
("Cut" ,(P "Cut"))
("Copy" ,(P "Copy"))
("Paste" ,(P "Paste"))
("Submenu" ;; a submenu without tear-off
("sub1" ,(P "sub1"))
("sub2" ,(P "sub2")))
;; a completely managed item
(radiobutton :label "Foo" :foreground "blue3")
(radiobutton :label "Bar" :foreground "blue3"))
0
("Help"
("About" ,(P "About"))))
:parent top :background "Bisque3" :release-command action))
(define f2
(make-toolbar *top-root*
`(("tb_console.gif" "Open New Console" ,(P 1))
("tb_edit.gif" "Open New Editor" ,(P 2))
("tb_customize.gif" "Customize Environment" ,(P 3))
20 ; insert a 20 pixels wide space
("tb_fileopen.gif" "Load File" ,(P 4)))
:parent top :background "Bisque4" :release-command action))
(define f3
(make-toolbar *top-root*
`(("tb_copy.gif" "Copy" ,(P 5))
("tb_paste.gif" "Paste" ,(P 6))
("tb_cut.gif" "Cut" ,(P 7))
20
("tb_info.gif" "Help on Console" , (P 8)))
:parent top :background "Wheat2" :release-command action
:orientation "vertical"))
(pack f1 f2 :side "top" :fill 'x)
(pack f3 :side "left" :fill 'y)
(pack st :fill 'both :expand #t :side "bottom"))
;=============================================================================
(define (demo-font-chooser)
(require "font-chooser")
(let ((font (make-font-chooser)))
(if font
(format #t "You have choosed the font ~S\n" font)))
(format #t "**Cancel**"))

21
Demos/term.stk Executable file → Normal file
View File

@ -3,21 +3,20 @@
;;;;
;;;; t e r m . s t k -- A simple terminal emulator written in Scheme
;;;;
;;;; Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; $Id: term.stk 1.2 Mon, 16 Feb 1998 08:28:39 +0100 eg $
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 7-Oct-1995 10:39
;;;; Last file update: 12-Feb-1998 15:31
;;;; Last file update: 3-Sep-1999 19:00 (eg)
(require "sterm")

17
Demos/tkcolor.stklos Executable file → Normal file
View File

@ -1,8 +1,23 @@
#!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;;
;;;; A simple color picker in Tk.
;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Last file update: 3-Sep-1999 19:26 (eg)
;;;;
;;;;
;;;; Clicking button 1 on the color box sets the text color
;;;; to that color; Clicking button 3 sets the background.
;;;; We read /usr/X11R6/lib/X11/rgb.txt by default. Change the

35
Demos/turtle.stk Executable file → Normal file
View File

@ -1,16 +1,31 @@
#!/bin/sh
:; exec /usr/local/bin/stk -f "$0" "$@"
;;;
;;; STkTurtle v1.0
;;;
;;; A (direct) rewritting of the TkTurtle demo found on the net in STk.
;;; Original copyright:
;;; Copyright 1993 James Noble, kjx@comp.vuw.ac.nz
;;;
;;;;
;;;; Copyright © 1994-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; STkTurtle v1.0
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;; This file comports two distinct parts.
;;; First part is the turtle package
;;; Second parts contains a set of examples using the turtle package
;;;; A (direct) rewritting of the TkTurtle demo found on the net in STk.
;;;; Original copyright:
;;;; Copyright 1993 James Noble, kjx@comp.vuw.ac.nz
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 1994
;;;; Last file update: 3-Sep-1999 19:04 (eg)
;;;; This file comports two distinct parts.
;;;; First part is the turtle package
;;;; Second parts contains a set of examples using the turtle package
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

47
Demos/widget.stk Executable file → Normal file
View File

@ -2,6 +2,26 @@
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;; STk adaptation of the Tk widget demo.
;;;;
;;;; Copyright © 1997-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 1997
;;;; Last file update: 3-Sep-1999 19:18 (eg)
;;;;
;;;; This script demonstrates the various widgets provided by Tk, along
;;;; with many of the features of the Tk toolkit. This file only
@ -14,8 +34,10 @@
(define demo-font "-*-Helvetica-Medium-R-Normal--*-140-*-*-*-*-*-*")
(define *STk-images* (string-append *STk-library* "/Images/"))
(set! *load-path* `("./Widget"
,(string-append *STk-library* "/demos")
(set! *load-path* `("."
"./Widget"
"../Demos/Widget"
,(string-append *STk-library* "/Demos")
,@*load-path*))
;;
@ -25,7 +47,6 @@
(let* ((t (make <Toplevel> :title title :geometry "+300+300"))
(f (make <Frame> :parent t))
(b (make <Frame> :parent t)))
;; Pack the demo text
(when text
(pack (make <Label> :font demo-font
@ -69,9 +90,9 @@
:geometry "+400+400"))
(but (make <Frame> :parent top))
(txt (make <Scheme-text> :parent top :wrap "none"
:h-scroll-side "bottom" :font '(Courier -12)
:h-scroll-side "bottom"
:width 85 :height 30
:value (exec (string-append "cat " file)))))
:value (call-with-input-file file port->string))))
(pack txt :side "top" :expand #t :fill "both")
(pack but :side "bottom" :expand #f :fill "x")
@ -89,9 +110,10 @@
#t)
#f))
(let ((file (string-append "W" name ".stklos")))
(unless (show (string-append *STk-library* "/../Demos/Widget/" file))
(unless (show (string-append *STk-library* "/demos/" file))
(error "Unable to show the code of the file ~S" file)))))
(unless (show (string-append *STk-library* "/Demos/" file))
(unless (show (string-append *STk-library* "/../Demos/Widget/" file))
(unless (show (string-append *STk-library* "/Demos/" file))
(error "Unable to show the code of the file ~S" file))))))
;;;; show-variables
@ -135,7 +157,6 @@
(let* ((t (make <Scroll-Text> :wrap "word" :width 60 :height 30
:font demo-font :set-grid #t))
(quit (make <Button> :text "Quit" :command (lambda () (exit 0))))
(title (make <Text-tag> :parent t
:font "-*-Helvetica-Bold-R-Normal--*-180-*-*-*-*-*-*"))
(demo (make <Text-tag> :parent t :lmargin1 "1c" :lmargin2 "1c"))
@ -144,10 +165,14 @@
(list :background "black" :foreground "white")
(list :relief "raised" :border-width 1
:background "SeaGreen3"))))
(tb (make-toolbar *top-root* `(("File"
("Quit" ,(lambda () (exit 0)))))))
(last-line '()))
(pack tb :expand #f :fill 'x)
(slot-set! tb 'release-command (default-release-toolbar t))
(pack t :expand #t :fill "both")
(pack quit :expand #f :fill "x")
;; Associate binfings to tags
(bind demo "<Button-1>"

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -1,20 +1,20 @@
%
% A note on how to extend the STk interpreter
%
% Copyright (C) 1993,1994,1995 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
%
% Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
%
% Permission to use, copy, and/or distribute this software and its
% documentation for any purpose and without fee is hereby granted, provided
% that both the above copyright notice and this permission notice appear in
% all copies and derived works. Fees for distribution or use of this
% software or derived works may only be charged with express written
% permission of the copyright holder.
% This software is provided ``as is'' without express or implied warranty.
% Permission to use, copy, modify, distribute,and license this
% software and its documentation for any purpose is hereby granted,
% provided that existing copyright notices are retained in all
% copies and that this notice is included verbatim in any
% distributions. No written agreement, license, or royalty fee is
% required for any of the authorized uses.
% This software is provided ``AS IS'' without express or implied
% warranty.
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: in 1993
% Last file update: 29-Mar-1997 18:30
% Last file update: 3-Sep-1999 19:36 (eg)
%
\documentclass[10pt]{article}

Binary file not shown.

View File

@ -1,133 +1,128 @@
%!PS-Adobe-2.0
%%Creator: dvips(k) 5.78 Copyright 1998 Radical Eye Software (www.radicaleye.com)
%%Creator: dvips(k) 5.85 Copyright 1999 Radical Eye Software
%%Title: Isotas96.dvi
%%Pages: 21
%%PageOrder: Ascend
%%BoundingBox: 0 0 596 842
%%EndComments
%DVIPSWebPage: (www.radicaleye.com)
%DVIPSCommandLine: dvips -f Isotas96.dvi
%DVIPSParameters: dpi=600, compressed
%DVIPSSource: TeX output 1999.02.02:1526
%DVIPSSource: TeX output 1999.09.03:2218
%%BeginProcSet: texc.pro
%!
/TeXDict 300 dict def TeXDict begin /N{def}def /B{bind def}N /S{exch}N
/X{S N}B /TR{translate}N /isls false N /vsize 11 72 mul N /hsize 8.5 72
mul N /landplus90{false}def /@rigin{isls{[0 landplus90{1 -1}{-1 1}
ifelse 0 0 0]concat}if 72 Resolution div 72 VResolution div neg scale
isls{landplus90{VResolution 72 div vsize mul 0 exch}{Resolution -72 div
hsize mul 0}ifelse TR}if Resolution VResolution vsize -72 div 1 add mul
TR[matrix currentmatrix{dup dup round sub abs 0.00001 lt{round}if}
forall round exch round exch]setmatrix}N /@landscape{/isls true N}B
/@manualfeed{statusdict /manualfeed true put}B /@copies{/#copies X}B
/FMat[1 0 0 -1 0 0]N /FBB[0 0 0 0]N /nn 0 N /IE 0 N /ctr 0 N /df-tail{
/nn 8 dict N nn begin /FontType 3 N /FontMatrix fntrx N /FontBBox FBB N
string /base X array /BitMaps X /BuildChar{CharBuilder}N /Encoding IE N
end dup{/foo setfont}2 array copy cvx N load 0 nn put /ctr 0 N[}B /df{
/sf 1 N /fntrx FMat N df-tail}B /dfs{div /sf X /fntrx[sf 0 0 sf neg 0 0]
N df-tail}B /E{pop nn dup definefont setfont}B /ch-width{ch-data dup
length 5 sub get}B /ch-height{ch-data dup length 4 sub get}B /ch-xoff{
128 ch-data dup length 3 sub get sub}B /ch-yoff{ch-data dup length 2 sub
get 127 sub}B /ch-dx{ch-data dup length 1 sub get}B /ch-image{ch-data
dup type /stringtype ne{ctr get /ctr ctr 1 add N}if}B /id 0 N /rw 0 N
/rc 0 N /gp 0 N /cp 0 N /G 0 N /sf 0 N /CharBuilder{save 3 1 roll S dup
/base get 2 index get S /BitMaps get S get /ch-data X pop /ctr 0 N ch-dx
0 ch-xoff ch-yoff ch-height sub ch-xoff ch-width add ch-yoff
setcachedevice ch-width ch-height true[1 0 0 -1 -.1 ch-xoff sub ch-yoff
.1 sub]/id ch-image N /rw ch-width 7 add 8 idiv string N /rc 0 N /gp 0 N
/cp 0 N{rc 0 ne{rc 1 sub /rc X rw}{G}ifelse}imagemask restore}B /G{{id
gp get /gp gp 1 add N dup 18 mod S 18 idiv pl S get exec}loop}B /adv{cp
add /cp X}B /chg{rw cp id gp 4 index getinterval putinterval dup gp add
/gp X adv}B /nd{/cp 0 N rw exit}B /lsh{rw cp 2 copy get dup 0 eq{pop 1}{
dup 255 eq{pop 254}{dup dup add 255 and S 1 and or}ifelse}ifelse put 1
adv}B /rsh{rw cp 2 copy get dup 0 eq{pop 128}{dup 255 eq{pop 127}{dup 2
idiv S 128 and or}ifelse}ifelse put 1 adv}B /clr{rw cp 2 index string
putinterval adv}B /set{rw cp fillstr 0 4 index getinterval putinterval
adv}B /fillstr 18 string 0 1 17{2 copy 255 put pop}for N /pl[{adv 1 chg}
{adv 1 chg nd}{1 add chg}{1 add chg nd}{adv lsh}{adv lsh nd}{adv rsh}{
adv rsh nd}{1 add adv}{/rc X nd}{1 add set}{1 add clr}{adv 2 chg}{adv 2
chg nd}{pop nd}]dup{bind pop}forall N /D{/cc X dup type /stringtype ne{]
}if nn /base get cc ctr put nn /BitMaps get S ctr S sf 1 ne{dup dup
length 1 sub dup 2 index S get sf div put}if put /ctr ctr 1 add N}B /I{
cc 1 add D}B /bop{userdict /bop-hook known{bop-hook}if /SI save N @rigin
0 0 moveto /V matrix currentmatrix dup 1 get dup mul exch 0 get dup mul
add .99 lt{/QV}{/RV}ifelse load def pop pop}N /eop{SI restore userdict
/eop-hook known{eop-hook}if showpage}N /@start{userdict /start-hook
known{start-hook}if pop /VResolution X /Resolution X 1000 div /DVImag X
/IE 256 array N 2 string 0 1 255{IE S dup 360 add 36 4 index cvrs cvn
put}for pop 65781.76 div /vsize X 65781.76 div /hsize X}N /p{show}N
/RMat[1 0 0 -1 0 0]N /BDot 260 string N /rulex 0 N /ruley 0 N /v{/ruley
X /rulex X V}B /V{}B /RV statusdict begin /product where{pop false[
(Display)(NeXT)(LaserWriter 16/600)]{dup length product length le{dup
length product exch 0 exch getinterval eq{pop true exit}if}{pop}ifelse}
forall}{false}ifelse end{{gsave TR -.1 .1 TR 1 1 scale rulex ruley false
RMat{BDot}imagemask grestore}}{{gsave TR -.1 .1 TR rulex ruley scale 1 1
false RMat{BDot}imagemask grestore}}ifelse B /QV{gsave newpath transform
round exch round exch itransform moveto rulex 0 rlineto 0 ruley neg
rlineto rulex neg 0 rlineto fill grestore}B /a{moveto}B /delta 0 N /tail
{dup /delta X 0 rmoveto}B /M{S p delta add tail}B /b{S p tail}B /c{-4 M}
B /d{-3 M}B /e{-2 M}B /f{-1 M}B /g{0 M}B /h{1 M}B /i{2 M}B /j{3 M}B /k{
4 M}B /w{0 rmoveto}B /l{p -4 w}B /m{p -3 w}B /n{p -2 w}B /o{p -1 w}B /q{
p 1 w}B /r{p 2 w}B /s{p 3 w}B /t{p 4 w}B /x{0 S rmoveto}B /y{3 2 roll p
a}B /bos{/SS save N}B /eos{SS restore}B end
/TeXDict 300 dict def TeXDict begin/N{def}def/B{bind def}N/S{exch}N/X{S
N}B/A{dup}B/TR{translate}N/isls false N/vsize 11 72 mul N/hsize 8.5 72
mul N/landplus90{false}def/@rigin{isls{[0 landplus90{1 -1}{-1 1}ifelse 0
0 0]concat}if 72 Resolution div 72 VResolution div neg scale isls{
landplus90{VResolution 72 div vsize mul 0 exch}{Resolution -72 div hsize
mul 0}ifelse TR}if Resolution VResolution vsize -72 div 1 add mul TR[
matrix currentmatrix{A A round sub abs 0.00001 lt{round}if}forall round
exch round exch]setmatrix}N/@landscape{/isls true N}B/@manualfeed{
statusdict/manualfeed true put}B/@copies{/#copies X}B/FMat[1 0 0 -1 0 0]
N/FBB[0 0 0 0]N/nn 0 N/IEn 0 N/ctr 0 N/df-tail{/nn 8 dict N nn begin
/FontType 3 N/FontMatrix fntrx N/FontBBox FBB N string/base X array
/BitMaps X/BuildChar{CharBuilder}N/Encoding IEn N end A{/foo setfont}2
array copy cvx N load 0 nn put/ctr 0 N[}B/sf 0 N/df{/sf 1 N/fntrx FMat N
df-tail}B/dfs{div/sf X/fntrx[sf 0 0 sf neg 0 0]N df-tail}B/E{pop nn A
definefont setfont}B/Cw{Cd A length 5 sub get}B/Ch{Cd A length 4 sub get
}B/Cx{128 Cd A length 3 sub get sub}B/Cy{Cd A length 2 sub get 127 sub}
B/Cdx{Cd A length 1 sub get}B/Ci{Cd A type/stringtype ne{ctr get/ctr ctr
1 add N}if}B/id 0 N/rw 0 N/rc 0 N/gp 0 N/cp 0 N/G 0 N/CharBuilder{save 3
1 roll S A/base get 2 index get S/BitMaps get S get/Cd X pop/ctr 0 N Cdx
0 Cx Cy Ch sub Cx Cw add Cy setcachedevice Cw Ch true[1 0 0 -1 -.1 Cx
sub Cy .1 sub]/id Ci N/rw Cw 7 add 8 idiv string N/rc 0 N/gp 0 N/cp 0 N{
rc 0 ne{rc 1 sub/rc X rw}{G}ifelse}imagemask restore}B/G{{id gp get/gp
gp 1 add N A 18 mod S 18 idiv pl S get exec}loop}B/adv{cp add/cp X}B
/chg{rw cp id gp 4 index getinterval putinterval A gp add/gp X adv}B/nd{
/cp 0 N rw exit}B/lsh{rw cp 2 copy get A 0 eq{pop 1}{A 255 eq{pop 254}{
A A add 255 and S 1 and or}ifelse}ifelse put 1 adv}B/rsh{rw cp 2 copy
get A 0 eq{pop 128}{A 255 eq{pop 127}{A 2 idiv S 128 and or}ifelse}
ifelse put 1 adv}B/clr{rw cp 2 index string putinterval adv}B/set{rw cp
fillstr 0 4 index getinterval putinterval adv}B/fillstr 18 string 0 1 17
{2 copy 255 put pop}for N/pl[{adv 1 chg}{adv 1 chg nd}{1 add chg}{1 add
chg nd}{adv lsh}{adv lsh nd}{adv rsh}{adv rsh nd}{1 add adv}{/rc X nd}{
1 add set}{1 add clr}{adv 2 chg}{adv 2 chg nd}{pop nd}]A{bind pop}
forall N/D{/cc X A type/stringtype ne{]}if nn/base get cc ctr put nn
/BitMaps get S ctr S sf 1 ne{A A length 1 sub A 2 index S get sf div put
}if put/ctr ctr 1 add N}B/I{cc 1 add D}B/bop{userdict/bop-hook known{
bop-hook}if/SI save N @rigin 0 0 moveto/V matrix currentmatrix A 1 get A
mul exch 0 get A mul add .99 lt{/QV}{/RV}ifelse load def pop pop}N/eop{
SI restore userdict/eop-hook known{eop-hook}if showpage}N/@start{
userdict/start-hook known{start-hook}if pop/VResolution X/Resolution X
1000 div/DVImag X/IEn 256 array N 2 string 0 1 255{IEn S A 360 add 36 4
index cvrs cvn put}for pop 65781.76 div/vsize X 65781.76 div/hsize X}N
/p{show}N/RMat[1 0 0 -1 0 0]N/BDot 260 string N/Rx 0 N/Ry 0 N/V{}B/RV/v{
/Ry X/Rx X V}B statusdict begin/product where{pop false[(Display)(NeXT)
(LaserWriter 16/600)]{A length product length le{A length product exch 0
exch getinterval eq{pop true exit}if}{pop}ifelse}forall}{false}ifelse
end{{gsave TR -.1 .1 TR 1 1 scale Rx Ry false RMat{BDot}imagemask
grestore}}{{gsave TR -.1 .1 TR Rx Ry scale 1 1 false RMat{BDot}
imagemask grestore}}ifelse B/QV{gsave newpath transform round exch round
exch itransform moveto Rx 0 rlineto 0 Ry neg rlineto Rx neg 0 rlineto
fill grestore}B/a{moveto}B/delta 0 N/tail{A/delta X 0 rmoveto}B/M{S p
delta add tail}B/b{S p tail}B/c{-4 M}B/d{-3 M}B/e{-2 M}B/f{-1 M}B/g{0 M}
B/h{1 M}B/i{2 M}B/j{3 M}B/k{4 M}B/w{0 rmoveto}B/l{p -4 w}B/m{p -3 w}B/n{
p -2 w}B/o{p -1 w}B/q{p 1 w}B/r{p 2 w}B/s{p 3 w}B/t{p 4 w}B/x{0 S
rmoveto}B/y{3 2 roll p a}B/bos{/SS save N}B/eos{SS restore}B end
%%EndProcSet
%%BeginProcSet: special.pro
%!
TeXDict begin /SDict 200 dict N SDict begin /@SpecialDefaults{/hs 612 N
/vs 792 N /ho 0 N /vo 0 N /hsc 1 N /vsc 1 N /ang 0 N /CLIP 0 N /rwiSeen
false N /rhiSeen false N /letter{}N /note{}N /a4{}N /legal{}N}B
/@scaleunit 100 N /@hscale{@scaleunit div /hsc X}B /@vscale{@scaleunit
div /vsc X}B /@hsize{/hs X /CLIP 1 N}B /@vsize{/vs X /CLIP 1 N}B /@clip{
/CLIP 2 N}B /@hoffset{/ho X}B /@voffset{/vo X}B /@angle{/ang X}B /@rwi{
10 div /rwi X /rwiSeen true N}B /@rhi{10 div /rhi X /rhiSeen true N}B
/@llx{/llx X}B /@lly{/lly X}B /@urx{/urx X}B /@ury{/ury X}B /magscale
true def end /@MacSetUp{userdict /md known{userdict /md get type
/dicttype eq{userdict begin md length 10 add md maxlength ge{/md md dup
length 20 add dict copy def}if end md begin /letter{}N /note{}N /legal{}
N /od{txpose 1 0 mtx defaultmatrix dtransform S atan/pa X newpath
clippath mark{transform{itransform moveto}}{transform{itransform lineto}
}{6 -2 roll transform 6 -2 roll transform 6 -2 roll transform{
itransform 6 2 roll itransform 6 2 roll itransform 6 2 roll curveto}}{{
closepath}}pathforall newpath counttomark array astore /gc xdf pop ct 39
0 put 10 fz 0 fs 2 F/|______Courier fnt invertflag{PaintBlack}if}N
/txpose{pxs pys scale ppr aload pop por{noflips{pop S neg S TR pop 1 -1
scale}if xflip yflip and{pop S neg S TR 180 rotate 1 -1 scale ppr 3 get
ppr 1 get neg sub neg ppr 2 get ppr 0 get neg sub neg TR}if xflip yflip
not and{pop S neg S TR pop 180 rotate ppr 3 get ppr 1 get neg sub neg 0
TR}if yflip xflip not and{ppr 1 get neg ppr 0 get neg TR}if}{noflips{TR
pop pop 270 rotate 1 -1 scale}if xflip yflip and{TR pop pop 90 rotate 1
-1 scale ppr 3 get ppr 1 get neg sub neg ppr 2 get ppr 0 get neg sub neg
TR}if xflip yflip not and{TR pop pop 90 rotate ppr 3 get ppr 1 get neg
sub neg 0 TR}if yflip xflip not and{TR pop pop 270 rotate ppr 2 get ppr
0 get neg sub neg 0 S TR}if}ifelse scaleby96{ppr aload pop 4 -1 roll add
2 div 3 1 roll add 2 div 2 copy TR .96 dup scale neg S neg S TR}if}N /cp
{pop pop showpage pm restore}N end}if}if}N /normalscale{Resolution 72
div VResolution 72 div neg scale magscale{DVImag dup scale}if 0 setgray}
N /psfts{S 65781.76 div N}N /startTexFig{/psf$SavedState save N userdict
maxlength dict begin /magscale true def normalscale currentpoint TR
/psf$ury psfts /psf$urx psfts /psf$lly psfts /psf$llx psfts /psf$y psfts
/psf$x psfts currentpoint /psf$cy X /psf$cx X /psf$sx psf$x psf$urx
psf$llx sub div N /psf$sy psf$y psf$ury psf$lly sub div N psf$sx psf$sy
scale psf$cx psf$sx div psf$llx sub psf$cy psf$sy div psf$ury sub TR
/showpage{}N /erasepage{}N /copypage{}N /p 3 def @MacSetUp}N /doclip{
TeXDict begin/SDict 200 dict N SDict begin/@SpecialDefaults{/hs 612 N
/vs 792 N/ho 0 N/vo 0 N/hsc 1 N/vsc 1 N/ang 0 N/CLIP 0 N/rwiSeen false N
/rhiSeen false N/letter{}N/note{}N/a4{}N/legal{}N}B/@scaleunit 100 N
/@hscale{@scaleunit div/hsc X}B/@vscale{@scaleunit div/vsc X}B/@hsize{
/hs X/CLIP 1 N}B/@vsize{/vs X/CLIP 1 N}B/@clip{/CLIP 2 N}B/@hoffset{/ho
X}B/@voffset{/vo X}B/@angle{/ang X}B/@rwi{10 div/rwi X/rwiSeen true N}B
/@rhi{10 div/rhi X/rhiSeen true N}B/@llx{/llx X}B/@lly{/lly X}B/@urx{
/urx X}B/@ury{/ury X}B/magscale true def end/@MacSetUp{userdict/md known
{userdict/md get type/dicttype eq{userdict begin md length 10 add md
maxlength ge{/md md dup length 20 add dict copy def}if end md begin
/letter{}N/note{}N/legal{}N/od{txpose 1 0 mtx defaultmatrix dtransform S
atan/pa X newpath clippath mark{transform{itransform moveto}}{transform{
itransform lineto}}{6 -2 roll transform 6 -2 roll transform 6 -2 roll
transform{itransform 6 2 roll itransform 6 2 roll itransform 6 2 roll
curveto}}{{closepath}}pathforall newpath counttomark array astore/gc xdf
pop ct 39 0 put 10 fz 0 fs 2 F/|______Courier fnt invertflag{PaintBlack}
if}N/txpose{pxs pys scale ppr aload pop por{noflips{pop S neg S TR pop 1
-1 scale}if xflip yflip and{pop S neg S TR 180 rotate 1 -1 scale ppr 3
get ppr 1 get neg sub neg ppr 2 get ppr 0 get neg sub neg TR}if xflip
yflip not and{pop S neg S TR pop 180 rotate ppr 3 get ppr 1 get neg sub
neg 0 TR}if yflip xflip not and{ppr 1 get neg ppr 0 get neg TR}if}{
noflips{TR pop pop 270 rotate 1 -1 scale}if xflip yflip and{TR pop pop
90 rotate 1 -1 scale ppr 3 get ppr 1 get neg sub neg ppr 2 get ppr 0 get
neg sub neg TR}if xflip yflip not and{TR pop pop 90 rotate ppr 3 get ppr
1 get neg sub neg 0 TR}if yflip xflip not and{TR pop pop 270 rotate ppr
2 get ppr 0 get neg sub neg 0 S TR}if}ifelse scaleby96{ppr aload pop 4
-1 roll add 2 div 3 1 roll add 2 div 2 copy TR .96 dup scale neg S neg S
TR}if}N/cp{pop pop showpage pm restore}N end}if}if}N/normalscale{
Resolution 72 div VResolution 72 div neg scale magscale{DVImag dup scale
}if 0 setgray}N/psfts{S 65781.76 div N}N/startTexFig{/psf$SavedState
save N userdict maxlength dict begin/magscale true def normalscale
currentpoint TR/psf$ury psfts/psf$urx psfts/psf$lly psfts/psf$llx psfts
/psf$y psfts/psf$x psfts currentpoint/psf$cy X/psf$cx X/psf$sx psf$x
psf$urx psf$llx sub div N/psf$sy psf$y psf$ury psf$lly sub div N psf$sx
psf$sy scale psf$cx psf$sx div psf$llx sub psf$cy psf$sy div psf$ury sub
TR/showpage{}N/erasepage{}N/copypage{}N/p 3 def @MacSetUp}N/doclip{
psf$llx psf$lly psf$urx psf$ury currentpoint 6 2 roll newpath 4 copy 4 2
roll moveto 6 -1 roll S lineto S lineto S lineto closepath clip newpath
moveto}N /endTexFig{end psf$SavedState restore}N /@beginspecial{SDict
begin /SpecialSave save N gsave normalscale currentpoint TR
@SpecialDefaults count /ocount X /dcount countdictstack N}N /@setspecial
{CLIP 1 eq{newpath 0 0 moveto hs 0 rlineto 0 vs rlineto hs neg 0 rlineto
moveto}N/endTexFig{end psf$SavedState restore}N/@beginspecial{SDict
begin/SpecialSave save N gsave normalscale currentpoint TR
@SpecialDefaults count/ocount X/dcount countdictstack N}N/@setspecial{
CLIP 1 eq{newpath 0 0 moveto hs 0 rlineto 0 vs rlineto hs neg 0 rlineto
closepath clip}if ho vo TR hsc vsc scale ang rotate rwiSeen{rwi urx llx
sub div rhiSeen{rhi ury lly sub div}{dup}ifelse scale llx neg lly neg TR
}{rhiSeen{rhi ury lly sub div dup scale llx neg lly neg TR}if}ifelse
CLIP 2 eq{newpath llx lly moveto urx lly lineto urx ury lineto llx ury
lineto closepath clip}if /showpage{}N /erasepage{}N /copypage{}N newpath
}N /@endspecial{count ocount sub{pop}repeat countdictstack dcount sub{
end}repeat grestore SpecialSave restore end}N /@defspecial{SDict begin}
N /@fedspecial{end}B /li{lineto}B /rl{rlineto}B /rc{rcurveto}B /np{
/SaveX currentpoint /SaveY X N 1 setlinecap newpath}N /st{stroke SaveX
SaveY moveto}N /fil{fill SaveX SaveY moveto}N /ellipse{/endangle X
/startangle X /yrad X /xrad X /savematrix matrix currentmatrix N TR xrad
yrad scale 0 0 1 startangle endangle arc savematrix setmatrix}N end
lineto closepath clip}if/showpage{}N/erasepage{}N/copypage{}N newpath}N
/@endspecial{count ocount sub{pop}repeat countdictstack dcount sub{end}
repeat grestore SpecialSave restore end}N/@defspecial{SDict begin}N
/@fedspecial{end}B/li{lineto}B/rl{rlineto}B/rc{rcurveto}B/np{/SaveX
currentpoint/SaveY X N 1 setlinecap newpath}N/st{stroke SaveX SaveY
moveto}N/fil{fill SaveX SaveY moveto}N/ellipse{/endangle X/startangle X
/yrad X/xrad X/savematrix matrix currentmatrix N TR xrad yrad scale 0 0
1 startangle endangle arc savematrix setmatrix}N end
%%EndProcSet
TeXDict begin 39158280 55380996 1000 600 600 (Isotas96.dvi)
@ -793,32 +788,32 @@ FC00FF902601FFFC90383FFF8002076D90B57E021FD9FF0380DA3F03903987E07FF0DA78
3801FFC0010F13F8017F13FF90B67E0003018013E03A07FE003FF0D80FF8EB0FF8001F81
491307003F81491303007F81A300FF1680A9007F1600A36C6C495AA2001F5D6D130F6C6C
495A6C6C495A6C6C6CB45A6C90B55A6C6C91C7FC011F13FC010113C029257DA430>I<01
FFEBFF80B5000F13F8023F7F91B6FCDAFE071380DAF00113C000039039C0007FE04A14F0
91C7123F17F8161F17FCA2160F17FEA917FC161FA217F8163F17F06EEB7FE06E13FFDAF0
0113C0DAFC07138091B5EAFE00023F5B020F13F0020190C7FC91C9FCABB512FCA52F357E
A435>I<9038FE07F000FFEB1FFC4A7E4A7E02F8138002E113C0EA07FF6C13C1A2028013
80A2ED7F00151C91C8FCB3B512FEA522257EA427>114 D<90383FF0383903FFFEF84813
FF121F383FC00FEB0003007E1301140012FEA27E6D130013F8EBFFE06C13FC14FF6C14C0
6C14E06C14F0000314F8C614FC131F9038007FFE14070078130112F814007EA26C14FC6C
1301018013F89038F00FF090B512E000FD14C000F0140038E01FF81F257DA426>I<131F
A55BA45BA25BA25A5A5A001FEBFFE0B6FCA4000390C7FCB115F8A86CEB01F014816CEBC3
E090387FFFC06D13806D1300EB03FC1D357EB425>I<B539F003FFF8A5000390C7EA3E00
6E137E6C157C6E13FC6C5DECE001017F5CA2ECF003013F5CECF807011F5CECFC0F010F5C
151FD907FE90C7FCA26E5A6D133E15FE6D5BA26D5BA36E5AA26E5AA26E5AA26E5A2D257E
A432>118 D<B500F1B538807FFFA50007903B000FF80007E06C6E6C14C0180F6C018016
8082DAC00F141F6C6F14004B5CD97FE0153E17806E48147E013F90393E7FC07C037E14FC
90271FF87C3F5B17E0DAFCFC13E1010F9039F81FF1F014FD9139FFF00FF36DEDFBE017FF
6D496C5BA24B7E6D5EA26D496C90C7FCA36EC75AA2023E147C40257EA445>I<B539F01F
FFF0A500019039C007F0006C5D6D6C485A6D6C485AECF83F6D6C48C7FC010F13FE6DB45A
6D5B5D6D5B7F147F6E7E814A7E14FF497F903803FBFFD907F37F02E17FEB0FC049486C7E
013F6D7ED97F007F01FE6D7E49130FB539803FFFF8A52D257EA432>I<B539F003FFF8A5
000390C7EA3E006E137E6C157C6E13FC6C5DECE001017F5CA2ECF003013F5CECF807011F
5CECFC0F010F5C151FD907FE90C7FCA26E5A6D133E15FE6D5BA26D5BA36E5AA26E5AA26E
5AA26E5AA2141F92C8FC5C003F133E387F807E38FFC07C14FC5CEAF80138FC07F0387E1F
E0387FFFC06C90C9FC6C5AEA07F02D357EA432>I<003FB612C0A4D9F0031380D9C00713
0049485AEB001F007E5C4A5A147F007C495A5D495B5B495B000091C7FC495A131F5C9039
3FF807C0137FEBFFF014E04813C048140F48138014004848EB1F80121F49133F4848137F
397FF003FFB7FCA422257DA42A>I<B812FEA42F04809830>I E
FFEBFF80B5000F13F8023F7F91B6FCDAFE071380DAF00113C000079039C0007FE06C4914
F091C7123F17F8161F17FCA2160F17FEA917FC161FA217F8163F17F06EEB7FE06E13FFDA
F00113C0DAFC07138091B5EAFE00023F5B020F13F0020190C7FC91C9FCABB512FCA52F35
7EA435>I<9038FE07F000FFEB1FFC4A7E4A7E02F8138002E113C0EA07FF6C13C1A20280
1380A2ED7F00151C91C8FCB3B512FEA522257EA427>114 D<90383FF0383903FFFEF848
13FF121F383FC00FEB0003007E1301140012FEA27E6D130013F8EBFFE06C13FC14FF6C14
C06C14E06C14F0000314F8C614FC131F9038007FFE14070078130112F814007EA26C14FC
6C1301018013F89038F00FF090B512E000FD14C000F0140038E01FF81F257DA426>I<13
1FA55BA45BA25BA25A5A5A001FEBFFE0B6FCA4000390C7FCB115F8A86CEB01F014816CEB
C3E090387FFFC06D13806D1300EB03FC1D357EB425>I<B539F003FFF8A5000390C7EA3E
006E137E6C157C6E13FC6C5DECE001017F5CA2ECF003013F5CECF807011F5CECFC0F010F
5C151FD907FE90C7FCA26E5A6D133E15FE6D5BA26D5BA36E5AA26E5AA26E5AA26E5A2D25
7EA432>118 D<B500F1B538807FFFA50007903B000FF80007E06C6E6C14C0180F6C0180
168082DAC00F141F6C6F14004B5CD97FE0153E17806E48147E013F90393E7FC07C037E14
FC90271FF87C3F5B17E0DAFCFC13E1010F9039F81FF1F014FD9139FFF00FF36DEDFBE017
FF6D496C5BA24B7E6D5EA26D496C90C7FCA36EC75AA2023E147C40257EA445>I<B539F0
1FFFF0A500019039C007F0006C5D6D6C485A6D6C485AECF83F6D6C48C7FC010F13FE6DB4
5A6D5B5D6D5B7F147F6E7E814A7E14FF497F903803FBFFD907F37F02E17FEB0FC049486C
7E013F6D7ED97F007F01FE6D7E49130FB539803FFFF8A52D257EA432>I<B539F003FFF8
A5000390C7EA3E006E137E6C157C6E13FC6C5DECE001017F5CA2ECF003013F5CECF80701
1F5CECFC0F010F5C151FD907FE90C7FCA26E5A6D133E15FE6D5BA26D5BA36E5AA26E5AA2
6E5AA26E5AA2141F92C8FC5C003F133E387F807E38FFC07C14FC5CEAF80138FC07F0387E
1FE0387FFFC06C90C9FC6C5AEA07F02D357EA432>I<003FB612C0A4D9F0031380D9C007
130049485AEB001F007E5C4A5A147F007C495A5D495B5B495B000091C7FC495A131F5C90
393FF807C0137FEBFFF014E04813C048140F48138014004848EB1F80121F49133F484813
7F397FF003FFB7FCA422257DA42A>I<B812FEA42F04809830>I E
%EndDVIPSBitmapFont
%DVIPSBitmapFont: Fj cmti10 10 30
/Fj 30 123 df<EE3FFC4BB51280030714C092390FC003E092391F0001F0033C1303037C
@ -1098,21 +1093,21 @@ D<2801FC01FF80EBFFC000FF0107D9E00313F0021FD9F80F13FC027FD9FC3F7F913BFC0F
FE7E07FF270FFDF007EBF8033C07FFC003FFE001028002C0148002001480A2491500B3B5
D8F07FD9F83F13FCA446217DA04B>I<3901FC01FF00FF010F13E04A7F027F7F9138FC1F
FC390FFDE00F6CB4486C7E14801400A25BB3B500F0B512F0A42C217DA031>I<9038FE07
FE00FF90383FFFC090B612F0829138F01FFC00079038C007FE91380003FF4915808117C0
A28117E0A94B13C0A34B138017006D5B9138C00FFE9138F03FFC91B55A4914E0023F1380
DA07FCC7FC91C9FCABB512F0A42B307EA031>112 D<3901FC1F8000FFEB7FF0ECFFF801
FD13FCECE7FE380FFFC76C1387A21407EC03FCEC01F89038FE00601500B1B512F8A41F21
7EA024>114 D<9038FFE1C0000313FF120F5A383F803F387F000F007E130712FEA26C90
C7FC13E013FF14F06C13FC6C13FF15806C14C012076C14E0C66C13F01303EB001F007813
0F00F813077E15E07E6C130F9038C03FC090B51280150000F913FC38E03FE01C217DA023
>I<133EA5137EA313FEA2120112031207121FB61280A4D807FEC7FCB0EC07C0A70003EB
0F8013FF6CEBFF006C5B6D5AEB0FF01A2F7EAE22>I<B539E00FFFC0A4000790390001F8
006C5D148015036C5DECC0076C5DECE00F017F5CECF01F013F91C7FC6E5A011F133EECFC
7E010F137CECFEFCA201075B14FF6D5BA26D5BA26D5BA26E5AA26EC8FCA22A217EA02F>
118 D<B53BC7FFFC07FFE0A43D07FE003FE0007C00A26D011F14FC6C6F5BDA803F13016C
03F85B157F02C014036C03FC5BDAE0FF1307017FD9FBFE5B14E19139F1F1FF0F013F5E02
FB141F011F01E0019FC7FC02FF14BF6D9038C07FFEA36D496C5AA26D496C5AA24A130F01
015DA26D486D5A4A13033B217EA040>I E
FE00FF90383FFFC090B612F0829138F01FFC000F9038C007FE6C90380003FF4915808117
C0A28117E0A94B13C0A34B138017006D5B9138C00FFE9138F03FFC91B55A4914E0023F13
80DA07FCC7FC91C9FCABB512F0A42B307EA031>112 D<3901FC1F8000FFEB7FF0ECFFF8
01FD13FCECE7FE380FFFC76C1387A21407EC03FCEC01F89038FE00601500B1B512F8A41F
217EA024>114 D<9038FFE1C0000313FF120F5A383F803F387F000F007E130712FEA26C
90C7FC13E013FF14F06C13FC6C13FF15806C14C012076C14E0C66C13F01303EB001F0078
130F00F813077E15E07E6C130F9038C03FC090B51280150000F913FC38E03FE01C217DA0
23>I<133EA5137EA313FEA2120112031207121FB61280A4D807FEC7FCB0EC07C0A70003
EB0F8013FF6CEBFF006C5B6D5AEB0FF01A2F7EAE22>I<B539E00FFFC0A4000790390001
F8006C5D148015036C5DECC0076C5DECE00F017F5CECF01F013F91C7FC6E5A011F133EEC
FC7E010F137CECFEFCA201075B14FF6D5BA26D5BA26D5BA26E5AA26EC8FCA22A217EA02F
>118 D<B53BC7FFFC07FFE0A43D07FE003FE0007C00A26D011F14FC6C6F5BDA803F1301
6C03F85B157F02C014036C03FC5BDAE0FF1307017FD9FBFE5B14E19139F1F1FF0F013F5E
02FB141F011F01E0019FC7FC02FF14BF6D9038C07FFEA36D496C5AA26D496C5AA24A130F
01015DA26D486D5A4A13033B217EA040>I E
%EndDVIPSBitmapFont
%DVIPSBitmapFont: Fn cmr9 9 77
/Fn 77 124 df<91391FE007F09139FFF81FF801079038FE7FFC903A0FE01FFC7E903A1F
@ -1158,8 +1153,8 @@ EB3FF8EBFFFC381DF07E381FC01F9038000F8015C0001E1307001C14E0000C14F0C71203
A315F8A31218123E127F5AA215F0A2481307007814E012700078EB0FC0003814806CEB1F
006C133E3807C0FC6CB45A6C13E038007F801D347CB126>I<14FE903807FF804913C090
383F01E090387C00709038F801F03901F003F83803E007EA07C0A2EA0F80001FEB03F0EC
01E048C8FCA35A007E7FEB0FF8EB1FFE38FE3FFF9038700F809038E007C039FFC003E090
388001F015F81300EC00FCA25A15FEA4127EA56C14FCA36CEB01F8A2D80F8013F0EC03E0
01E048C8FCA35A007E7FEB07F8EB1FFE38FE3FFF9038700F809038E007C09038C003E039
FF8001F015F81300EC00FCA25A15FEA4127EA56C14FCA36CEB01F8A2D80F8013F0EC03E0
EA07C03903E007C03901F81F803900FFFE00EB3FFCEB0FE01F347DB126>I<1238123E00
3FB6FCA34814FE15FCA20078C712380070147015E0A248EB01C0EC0380A2C7EA0700140E
5CA25C5CA25C1301A2495AA213075C130FA2131FA349C7FCA35BA55BA8137E133C20347C
@ -1170,7 +1165,7 @@ B126>I<EB0FE0EB7FFC90B5FC3901F01F803903C007C039078003E0380F00014814F012
E0390FC003C03907F01F800001B5120038007FFCEB1FE01F347DB126>I<EB0FE0EB7FF8
EBFFFE3801F83F3903E00F803907C007C0390F8003E0EA1F0048EB01F0A2007E14F8A300
FEEB00FCA515FEA4127E1401A27E14037E380F80063807C00E3803E01C3801FFF86CEBF0
FCEB3FE0EB020090C7FCEC01F8A3000F14F0381F8003D83FC013E0A2EC07C0EC0F800180
FCEB3FC0EB020090C7FCEC01F8A3000F14F0381F8003D83FC013E0A2EC07C0EC0F800180
1300381F001E001E137C380F81F86CB45A6C13C0C66CC7FC1F347DB126>I<121C123E12
7FEAFF80A3EA7F00123E121CC7FCAE121C123E127FEAFF80A3EA7F00123E121C09207A9F
15>I<121C123E127FEAFF80A3EA7F00123E121CC7FCAE121C127E127F5A1380A2127FA2
@ -1483,7 +1478,7 @@ FE13FBEBFF7F496C7EEBFC1F01F87F6E7E6E7EA26E7E6E7EA26E7E157FA2ED3F8016C048
487F4848EB1F80001F15C049130F003F15E0A248C7EA07F0A44815F8A96C15F0A26D130F
003F15E0A26C6CEB1FC0000F15806D133F6C6CEB7F006C6C13FE3900FE03F890387FFFF0
011F13C0D903FEC7FC25277EA52A>I<3903F80FE000FFEB7FFC9038F9FFFE9039FBE07F
803A07FF801FC03A03FE000FE049EB07F0A249EB03F816FC150116FEA3ED00FFA916FE15
803A0FFF801FC03A03FE000FE049EB07F0A249EB03F816FC150116FEA3ED00FFA916FE15
01A316FC150316F86DEB07F0ED0FE06D14C09039FF803F809039FBE07F009038F9FFFE90
38F87FF8EC1FC091C8FCAB487EB512E0A328357EA42E>I<903903F801C090381FFE03EB
7FFF9038FE07873901FC01C73903F000EF0007147F4848133F485A003F141F5B127FA390
@ -1605,7 +1600,7 @@ D<913801FFE0021F13FE91B612C0010315F0010F15FC499038807FFE903B7FFC000FFF80
80A400FF18C0AC007F1880A3003F18006D5DA26C5FA26C6D4A5AA26C6D4A5A6C5F6C6D49
5B6C01F801075B6D6C495B90273FFF807F90C7FC010F90B512FC6D5D010015C0023F91C8
FC020113E03A387CB643>I<D93FF8EB7FF0B50103B5FC031F14E0037F14F802F9B612FE
02FB01007FDAFFF8011F7F000102E06D7F6C4A6D7F92C76C7F4A6E7F4A8283727EA28584
02FB01007FDAFFF8011F7F000302E06D7FC64A6D7F92C76C7F4A6E7F4A8283727EA28584
A21A80A284A21AC0AB1A8060A31A006061A24E5AA26E4A5B6E5C6103C0495B6F011F5B6F
495B9227FE01FFFEC7FC02FDB65ADAFC7F14F0031F14C0030749C8FC030013E093CAFCB0
B612FCA6424D7CB54B>I<90393FF003FCB5EB1FFF4B13C092B512F002F114F89238FC7F
@ -1753,29 +1748,30 @@ b(the)i(solid)e(basis)h(pro)n(vided)f(b)n(y)i(the)g(Sc)n(heme)f
(large-scale)d(soft)n(w)n(are)i(dev)n(elopmen)n(t.)f(In)j(particular,)
681 3668 y(the)e(lac)n(k)f(of)h(an)g(ob)5 b(ject)26 b(mec)n(hanism)d
(increases)h(the)i(programming)21 b(complexit)n(y)i(of)j(large)681
3768 y(applications.)31 b Fh(STklos)o Fo(,)36 b(the)g(ob)5
b(ject)35 b(extension)f(of)h Fh(STk)p Fo(,)g(has)g(b)r(een)h(de\014ned)
f(to)g(alle-)681 3867 y(viate)e(this)h(problem.)e(This)h(extension)g
(pro)n(vides)f(meta)i(classes,)e(m)n(ultiple)f(inheritance)681
3967 y(and)38 b(generic)e(functions)h Fj(\022)-42 b(a)40
b(la)f Fo(CLOS)24 b([7,)38 b(15)o(])g(or)g(Dylan)24 b([2)o(].)38
b Fh(STklos)g Fo(has)f(also)f(b)r(een)681 4066 y(used)e(to)f(em)n(b)r
(o)r(dy)g(the)h(prede\014ned)g(Tk)g(widgets)e(in)h(a)h(hierarc)n(h)n(y)
d(of)i(classes.)f(Usage)h(of)681 4166 y(these)22 b(classes)f
(simpli\014es)e(the)k(core)e(Tk)i(usage)e(b)n(y)i(pro)n(viding)c(an)k
(homogeneous)c(access)j(to)681 4266 y(widget)i(options)g(and)h(b)n(y)g
(hiding)f(the)h(Tk)h(widgets)e(lo)n(w)f(lev)n(el)g(idiosyncrasies.)d
(Moreo)n(v)n(er,)681 4365 y(as)33 b(exp)r(ected,)h(usage)e(of)i(ob)5
b(jects)33 b(facilitates)e(co)r(de)i(reuse)g(and)g(de\014nition)g(of)g
(new)h(wid-)681 4465 y(gets)27 b(classes.)d(Finally)-7
b(,)25 b(w)n(e)i(think)f(that)i(the)f(ob)5 b(ject)27
b(orien)n(tation)d(of)j Fh(STklos)p Fo(,)g(as)f(w)n(ell)f(as)681
4565 y(the)30 b(solid)d(basis)h(of)h(the)h(Sc)n(heme)f(programming)24
b(language,)j(a\013ord)i(therefore)f(the)i(to)r(ols)681
4664 y(necessary)c(to)h(en)n(vision)e(writing,)g(and)i(main)n(taining,)
c(complex)j(GUI.)805 4764 y(The)h(rest)f(of)h(this)f(pap)r(er)g(is)f
(divided)g(in)h(three)h(sections.)e(The)i(next)f(section)g(presen)n(ts)
681 4863 y(the)31 b Fh(STk)f Fo(pac)n(k)-5 b(age)28 b(and)j(its)e(ob)5
3768 y(applications.)f Fh(STklos)o Fo(,)30 b(the)f(ob)5
b(ject)29 b(extension)f(of)h Fh(STk)p Fo(,)g(has)g(b)r(een)h(de\014ned)
f(to)h(allevi-)681 3867 y(ate)24 b(this)g(problem.)d(This)j(extension)f
(pro)n(vides)f(meta)h(classes,)f(m)n(ultiple)f(inheritance)h(and)681
3967 y(generic)34 b(functions)h Fj(\022)-42 b(a)37 b(la)g
Fo(CLOS)24 b([7,)36 b(15)o(])g(or)e(Dylan)24 b([2].)36
b Fh(STklos)f Fo(has)g(also)f(b)r(een)i(used)681 4066
y(to)c(em)n(b)r(o)r(dy)f(the)h(prede\014ned)g(Tk)g(widgets)f(in)g(a)h
(hierarc)n(h)n(y)d(of)j(classes.)e(Usage)h(of)h(these)681
4166 y(classes)23 b(simpli\014es)e(the)k(core)f(Tk)h(usage)f(b)n(y)g
(pro)n(viding)e(an)j(homogeneous)d(access)i(to)h(wid-)681
4266 y(get)i(options)g(and)g(b)n(y)h(hiding)e(the)i(Tk)g(widgets)e(lo)n
(w)g(lev)n(el)g(idiosyncrasies.)c(Moreo)n(v)n(er,)j(as)681
4365 y(exp)r(ected,)34 b(usage)e(of)h(ob)5 b(jects)33
b(facilitates)d(co)r(de)k(reuse)e(and)i(de\014nition)d(of)j(new)f
(widget-)681 4465 y(s)i(classes.)f(Finally)-7 b(,)33
b(w)n(e)i(think)g(that)h(the)g(ob)5 b(ject)36 b(orien)n(tation)c(of)k
Fh(STklos)o Fo(,)g(as)f(w)n(ell)e(as)681 4565 y(the)d(solid)d(basis)h
(of)h(the)h(Sc)n(heme)f(programming)24 b(language,)j(a\013ord)i
(therefore)f(the)i(to)r(ols)681 4664 y(necessary)c(to)h(en)n(vision)e
(writing,)g(and)i(main)n(taining,)c(complex)j(GUI.)805
4764 y(The)h(rest)f(of)h(this)f(pap)r(er)g(is)f(divided)g(in)h(three)h
(sections.)e(The)i(next)f(section)g(presen)n(ts)681 4863
y(the)31 b Fh(STk)f Fo(pac)n(k)-5 b(age)28 b(and)j(its)e(ob)5
b(ject)30 b(system.)f(W)-7 b(rapping)29 b(the)i(standard)e(Tk)h
(widgets)f(in)p eop
%%Page: 3 3
@ -1917,62 +1913,62 @@ b(alue)27 b(of)i(the)g Fe(y)g Fo(slot)f(of)g Fe(p)h Fo(could)f(b)r(e)h
(een)i(de\014ned)f(for)f(slot)f Fe(y)p Fo(.)h(This)g(slot)f(can)i(b)r
(e)g(set)g(b)n(y)f(the)365 487 y(generalized)24 b Fe(set!)i
Fo(form,)h(as)g(illustrated)d(b)n(y)j(the)h(follo)n(wing)c(example:)506
644 y Ff(\(set!)41 b(\(y-of)f(p\))g(1\))302 b Fd(;)27
b(or)h(\(slot-set!)i(p)e('y)f(1\))365 810 y Fo(No)n(w,)g(w)n(e)h(can)f
646 y Ff(\(set!)41 b(\(y-of)f(p\))g(1\))302 b Fd(;)27
b(or)h(\(slot-set!)i(p)e('y)f(1\))365 813 y Fo(No)n(w,)g(w)n(e)h(can)f
(de\014ne)h(the)g Fe(Rectangle)c Fo(class)h(whic)n(h)i(inherits)e(from)
i(the)h Fe(Point)d Fo(class:)506 967 y Ff(\(define-class)43
b(Rectangle)e(\(Point\))585 1059 y(\(\(width)80 b(:init-keyword)42
b(:width)80 b(:accessor)41 b(width-of\))624 1150 y(\(height)g
i(the)h Fe(Point)d Fo(class:)506 972 y Ff(\(define-class)43
b(Rectangle)e(\(Point\))585 1063 y(\(\(width)80 b(:init-keyword)42
b(:width)80 b(:accessor)41 b(width-of\))624 1155 y(\(height)g
(:init-keyword)h(:height)f(:accessor)g(height-of\)\)\))365
1315 y Fo(The)30 b(instances)e(of)h(this)g(class)f(ha)n(v)n(e)g(four)h
1322 y Fo(The)30 b(instances)e(of)h(this)g(class)f(ha)n(v)n(e)g(four)h
(slots)f(\()p Fe(x)p Fo(,)i Fe(y)p Fo(,)f Fe(width)f
Fo(and)h Fe(height)p Fo(\).)f(Metho)r(ds)3210 1285 y
Fc(1)365 1415 y Fo(de\014ned)37 b(for)f(instances)e(of)i(the)h
Fo(and)h Fe(height)p Fo(\).)f(Metho)r(ds)3210 1292 y
Fc(1)365 1421 y Fo(de\014ned)37 b(for)f(instances)e(of)i(the)h
Fe(Point)d Fo(class)h(can)g(also)g(b)r(e)h(used)g(for)g(instances)f(of)
h(the)365 1515 y Fe(Rectangle)22 b Fo(class.)i(F)-7 b(or)25
h(the)365 1521 y Fe(Rectangle)22 b Fo(class.)i(F)-7 b(or)25
b(example,)e(the)j Fe(x)f Fo(co)r(ordinate)e(of)j(a)f
Fe(Rectangle)c Fo(can)26 b(b)r(e)f(accessed)365 1614
Fe(Rectangle)c Fo(can)26 b(b)r(e)f(accessed)365 1621
y(with)i(the)h(accessor)e(metho)r(d)h Fe(x-of)f Fo(de\014ned)i(b)r
(efore.)490 1714 y(Previous)20 b(class)g(de\014nition)h(represen)n(ts)g
(efore.)490 1721 y(Previous)20 b(class)g(de\014nition)h(represen)n(ts)g
(rectangles)g(with)h(a)g(reference)g(p)r(oin)n(t,)f(a)i(width)365
1814 y(and)k(a)f(heigh)n(t.)f(This)g(represen)n(tation)f(for)i
1820 y(and)k(a)f(heigh)n(t.)f(This)g(represen)n(tation)f(for)i
(rectangles)e(is,)i(most)f(of)h(the)h(time,)e(con)n(v)n(enien)n(t)365
1913 y(but)33 b(w)n(e)e(sometimes)d(need)k(a)f(represen)n(tation)e
1920 y(but)33 b(w)n(e)e(sometimes)d(need)k(a)f(represen)n(tation)e
(using)h(the)i(co)r(ordinates)d(of)j(t)n(w)n(o)f(opp)r(osite)365
2013 y(corners.)e(In)h(that)g(case,)g Fj(virtual)i(slots)f
2019 y(corners.)e(In)h(that)g(case,)g Fj(virtual)i(slots)f
Fo(can)e(b)r(e)i(used.)f(A)g(virtual)e(slot)h(is)g(a)h(slot)e(whic)n(h)
h(is)365 2112 y(de\014ned)j(as)f(a)h(normal)c(slot)j(but)h(whose)f
h(is)365 2119 y(de\014ned)j(as)f(a)h(normal)c(slot)j(but)h(whose)f
(allo)r(cation)d(is)i(declared)g(as)h Fe(:virtual)p Fo(.)e(Suc)n(h)j(a)
365 2212 y(slot)c(has)g(a)g(n)n(ull)f(allo)r(cation)e(and)k(its)f
365 2219 y(slot)c(has)g(a)g(n)n(ull)f(allo)r(cation)e(and)k(its)f
(reading)e(\(resp.)j(writing\))d(pro)n(v)n(ok)n(es)g(the)k(execution)
365 2312 y(of)24 b(a)g(getter)g(\(resp.)g(setter\))g(function)g(whic)n
365 2318 y(of)24 b(a)g(getter)g(\(resp.)g(setter\))g(function)g(whic)n
(h)f(m)n(ust)g(b)r(e)i(pro)n(vided)d(b)n(y)i(the)g(user)g(within)f(the)
365 2411 y(class)i(de\014nition.)f(The)j(getter)e(and)h(setter)g
365 2418 y(class)i(de\014nition.)f(The)j(getter)e(and)h(setter)g
(functions)g(are)f(de\014ned)i(with)e(the)i Fe(:slot-ref)365
2511 y Fo(and)k Fe(:slot-set!)26 b Fo(options.)j(Here)h(is)f(another)g
2518 y Fo(and)k Fe(:slot-set!)26 b Fo(options.)j(Here)h(is)f(another)g
(writing)f(of)j(the)f Fe(Rectangle)d Fo(class)i(using)365
2611 y(virtual)c(slots:)506 2784 y Ff(\(define-class)43
b(Rectangle)e(\(Point\))585 2876 y(\(\(width)80 b(:init-keyword)42
b(:width)80 b(:accessor)41 b(width-of\))624 2967 y(\(height)g
2617 y(virtual)c(slots:)506 2793 y Ff(\(define-class)43
b(Rectangle)e(\(Point\))585 2884 y(\(\(width)80 b(:init-keyword)42
b(:width)80 b(:accessor)41 b(width-of\))624 2976 y(\(height)g
(:init-keyword)h(:height)f(:accessor)g(height-of\))624
3141 y(\(x2)197 b(:init-keyword)42 b(:x2)197 b(:accessor)41
b(x2-of)938 3232 y(:allocation)120 b(:virtual)938 3323
3152 y(\(x2)197 b(:init-keyword)42 b(:x2)197 b(:accessor)41
b(x2-of)938 3243 y(:allocation)120 b(:virtual)938 3334
y(:slot-ref)80 b(\(lambda)41 b(\(obj\))g(\(+)e(\(x-of)i(obj\))f
(\(width-of)h(obj\)\)\))938 3415 y(:slot-set!)g(\(lambda)g(\(obj)f
(val\))1448 3506 y(\(set!)g(\(width-of)i(obj\))e(\(-)f(val)h(\(x-of)h
(obj\)\)\)\)\))624 3680 y(\(y2)197 b(:init-keyword)42
b(:y2)e(:accessor)h(y2-of)938 3771 y(:allocation)120
b(:virtual)938 3863 y(:slot-ref)80 b(\(lambda)41 b(\(obj\))g(\(+)e
(\(y-of)i(obj\))f(\(height-of)h(obj\)\)\))938 3954 y(:slot-set!)g
(\(lambda)g(\(obj)f(val\))1448 4045 y(\(set!)g(\(height-of)i(obj\))e
(\(-)g(val)f(\(y-of)i(obj\)\)\)\)\)\)\))365 4227 y Fo(In)27
(\(width-of)h(obj\)\)\))938 3426 y(:slot-set!)g(\(lambda)g(\(obj)f
(val\))1448 3517 y(\(set!)g(\(width-of)i(obj\))e(\(-)f(val)h(\(x-of)h
(obj\)\)\)\)\))624 3693 y(\(y2)197 b(:init-keyword)42
b(:y2)e(:accessor)h(y2-of)938 3784 y(:allocation)120
b(:virtual)938 3875 y(:slot-ref)80 b(\(lambda)41 b(\(obj\))g(\(+)e
(\(y-of)i(obj\))f(\(height-of)h(obj\)\)\))938 3967 y(:slot-set!)g
(\(lambda)g(\(obj)f(val\))1448 4058 y(\(set!)g(\(height-of)i(obj\))e
(\(-)g(val)f(\(y-of)i(obj\)\)\)\)\)\)\))365 4242 y Fo(In)27
b(this)e(new)i(de\014nition)d(of)j Fe(Rectangle)p Fo(,)22
b Fe(x2)k Fo(and)g Fe(y2)g Fo(are)f(virtual)f(slots.)g(The)j(getter)e
(and)365 4327 y(setter)33 b(asso)r(ciated)e(functions)h(are)g(lam)n(b)r
(and)365 4342 y(setter)33 b(asso)r(ciated)e(functions)h(are)g(lam)n(b)r
(da)f(expressions)f(whic)n(h)i(compute)g(or)g(set)h(their)365
4427 y(v)-5 b(alue)32 b(dep)r(ending)g(on)h(other)f(slots)f(v)-5
4441 y(v)-5 b(alue)32 b(dep)r(ending)g(on)h(other)f(slots)f(v)-5
b(alue.)32 b(Note)h(that)g(a)f(virtual)e(slot)i(accessor)e(closure)365
4526 y(can)e(c)n(hange)e(the)i(v)-5 b(alue)26 b(of)i(standard)f(slots)f
4541 y(can)e(c)n(hange)e(the)i(v)-5 b(alue)26 b(of)i(standard)f(slots)f
(in)g(order)h(to)g(k)n(eep)g(the)h(system)f(coheren)n(t.)p
365 4595 473 4 v 382 4649 a Fb(1)442 4681 y Fn(In)22
b Fl(STklos)q Fn([5)q(],)h(the)f(execution)h(of)g(a)g(metho)r(d)f(rely)
@ -2437,75 +2433,75 @@ eop
8 7 bop 822 356 a Ff(\(define-class)42 b(<Button>)f(\(<Label>\))940
448 y(\(\(command)g(:accessor)g(command)g(:init-keyword)h(:command)1332
539 y(:allocation)g(:tk-virtual\)\))940 630 y(:metaclass)f
(<Tk-metaclass>\))681 747 y Fo(This)19 b(new)i(class)e(inherits)f(from)
(<Tk-metaclass>\))681 750 y Fo(This)19 b(new)i(class)e(inherits)f(from)
h Fe(<Label>)f Fo(and)j(o)n(wns)e(an)i(extra)e(slot)h(called)e
Fe(command)p Fo(.)g(The)681 846 y(allo)r(cation)j(of)26
Fe(command)p Fo(.)g(The)681 850 y(allo)r(cation)j(of)26
b(this)f(slot)f(is)g(quali\014ed)g(with)h Fe(:tk-virtual)p
Fo(.)c(Tk-virtual)h(slots)i(are)h(sp)r(ecial)681 946
Fo(.)c(Tk-virtual)h(slots)i(are)h(sp)r(ecial)681 949
y(purp)r(ose)f(slots:)e(they)j(can)f(b)r(e)h(used)f(as)g(normal)d
(slots)i(but)i(they)f(are)g(not)g(allo)r(cated)e(in)h(the)681
1046 y(Sc)n(heme)j(w)n(orld)f(\()p Fj(i.e.)k Fo(their)d(v)-5
1049 y(Sc)n(heme)j(w)n(orld)f(\()p Fj(i.e.)k Fo(their)d(v)-5
b(alue)25 b(is)h(stored)g(in)h(one)f(of)h(the)h(structures)e
(manipulated)e(b)n(y)681 1145 y(the)k(Tk)f(library)d(instead)j(of)g(in)
(manipulated)e(b)n(y)681 1149 y(the)k(Tk)f(library)d(instead)j(of)g(in)
g(a)g(Sc)n(heme)g(ob)5 b(ject\).)27 b(Consequen)n(tly)-7
b(,)26 b(reading)f(or)i(writing)681 1245 y(suc)n(h)e(a)g(slot)f(is)h
b(,)26 b(reading)f(or)i(writing)681 1248 y(suc)n(h)e(a)g(slot)f(is)h
(done)g(in)g(a)g(particular)d(w)n(a)n(y:)i(access)h(to)g(Tk-virtual)e
(slot)h(uses)h(in)g(turn)g(the)681 1344 y(standard)19
(slot)h(uses)h(in)g(turn)g(the)681 1348 y(standard)19
b(Tk)i Fe(configure)16 b Fo(op)r(eration)j(as)h(in)f(2.1.)h(Tk-virtual)
d(widgets)j(slots)f(are)g(a)h(sp)r(ecial)681 1444 y(kind)37
d(widgets)j(slots)f(are)g(a)h(sp)r(ecial)681 1448 y(kind)37
b(of)i(virtual)d(slots)h(whic)n(h)g(are)h(managed)e(b)n(y)i(the)h(meta)
f(class)e Fe(<Tk-metaclass>)p Fo(.)681 1544 y(De\014ning)26
f(class)e Fe(<Tk-metaclass>)p Fo(.)681 1547 y(De\014ning)26
b(a)h(class)e(using)h(this)g(meta)g(class)f(allo)n(ws)f(the)j(mo)r
(di\014cation)d(of)j(a)f(slot)g(accessors)681 1643 y(at)e(the)g(lo)n(w)
(di\014cation)d(of)j(a)f(slot)g(accessors)681 1647 y(at)e(the)g(lo)n(w)
n(est)e(lev)n(el.)f(Therefore,)i(the)h(v)-5 b(alue)23
b(of)h(a)f(virtual)f(slot)g(alw)n(a)n(ys)f(re\015ect)j(the)g(actual)681
1743 y(v)-5 b(alue)29 b(of)i(the)g(asso)r(ciated)d(Tk)j(option)e
1746 y(v)-5 b(alue)29 b(of)i(the)g(asso)r(ciated)d(Tk)j(option)e
(\(remem)n(b)r(er)f(that)j(no)f(space)g(is)g(reserv)n(ed)e(for)i(this)
681 1843 y(slot)e(in)g(the)i(Sc)n(heme)e(core)g(and)h(that)g(accesses)f
681 1846 y(slot)e(in)g(the)i(Sc)n(heme)e(core)g(and)h(that)g(accesses)f
(are)g(directly)f(done)i(within)f(the)h(Tk)g(data)681
1942 y(structures\).)j(The)h(sp)r(eci\014cation)d(of)i(the)h(meta)f
1946 y(structures\).)j(The)h(sp)r(eci\014cation)d(of)i(the)h(meta)f
(class)e(of)j(the)g Fe(<Button>)c Fo(class)i(in)h(giv)n(en)681
2042 y(with)f(the)h Fe(:metaclass)c Fo(option)1721 2012
y Fc(5)1757 2042 y Fo(.)k(It)g(is)f(imp)r(ortan)n(t)e(to)j(note)g(that)
g(the)g(construction)e(of)681 2141 y(the)k(slot)e(accessors)f(is)i
2045 y(with)f(the)h Fe(:metaclass)c Fo(option)1721 2015
y Fc(5)1757 2045 y Fo(.)k(It)g(is)f(imp)r(ortan)n(t)e(to)j(note)g(that)
g(the)g(construction)e(of)681 2145 y(the)k(slot)e(accessors)f(is)i
(made)f(at)i(class)e(creation)f(so)i(that)h(no)g(particular)c
(computation)681 2241 y(is)e(necessary)f(when)i(accessing)e(suc)n(h)i
(computation)681 2245 y(is)e(necessary)f(when)i(accessing)e(suc)n(h)i
(a)f(slot.)g(Th)n(us,)h(customizing)d(a)j(widget)f(b)n(y)g(using)g(a)
681 2341 y(slot)i(access)g(at)h(the)h Fh(STklos)f Fo(lev)n(el)e(is)h
681 2344 y(slot)i(access)g(at)h(the)h Fh(STklos)f Fo(lev)n(el)e(is)h
Fi(as)36 b(e\016cien)m(t)g(as)31 b Fo(using)f(a)h(standard)g(Tk)g
(option)681 2440 y(con\014guration)25 b(at)i(the)h Fh(STk)g
Fo(base)f(lev)n(el.)805 2540 y(The)i(previous)d(de\014nition)h(of)i
(option)681 2444 y(con\014guration)25 b(at)i(the)h Fh(STk)g
Fo(base)f(lev)n(el.)805 2543 y(The)i(previous)d(de\014nition)h(of)i
Fe(<Button>)c Fo(is)j(not)g(su\016cien)n(t)g(for)g(a)g(complete)e(in)n
(tegra-)681 2640 y(tion)f(of)i(the)g(Tk)f(button)h(widget)e(in)h(a)g
(tegra-)681 2643 y(tion)f(of)i(the)g(Tk)f(button)h(widget)e(in)h(a)g
Fh(STklos)g Fo(class.)e(Indeed,)j(the)g(MOP)f(ensures)f(that)681
2739 y Fe(Tk-constructor)e Fo(is)29 b(called)e(when)i(creating)e(a)i
2743 y Fe(Tk-constructor)e Fo(is)29 b(called)e(when)i(creating)e(a)i
(new)h Fe(<Tk-widget>)24 b Fo(\(and)30 b Fe(<Button>)c
Fo(is)681 2839 y(an)36 b(indirect)f(instance)h(of)h Fe(<Tk-widget>)32
Fo(is)681 2842 y(an)36 b(indirect)f(instance)h(of)h Fe(<Tk-widget>)32
b Fo(as)k(sho)n(wn)h(in)f(Fig.)23 b(1\).)37 b(This)f(function)h(m)n
(ust)681 2938 y(determine)32 b(the)j(Tk)g(library)c(function)j(\(a)g
(ust)681 2942 y(determine)32 b(the)j(Tk)g(library)c(function)j(\(a)g
Fj(Tk-c)l(ommand)p Fo(\))i(whic)n(h)e(has)f(to)i(b)r(e)g(called)d(to)
681 3038 y(create)24 b(the)i(new)f(widget.)f(The)h(follo)n(wing)c
681 3042 y(create)24 b(the)i(new)f(widget.)f(The)h(follo)n(wing)c
(metho)r(d)k(for)g Fe(Tk-constructor)19 b Fo(su\016ces)25
b(to)g(do)681 3138 y(this)i(job:)822 3265 y Ff(\(define-method)42
b(Tk-constructor)h(\(\(b)d(<Button>\)\))940 3356 y(button\))681
3491 y Fo(The)33 b(previous)f Fe(<Button>)e Fo(class)h(and)j
b(to)g(do)681 3141 y(this)i(job:)822 3271 y Ff(\(define-method)42
b(Tk-constructor)h(\(\(b)d(<Button>\)\))940 3362 y(button\))681
3500 y Fo(The)33 b(previous)f Fe(<Button>)e Fo(class)h(and)j
Fe(Tk-constructor)27 b Fo(metho)r(d)33 b(de\014nitions)f(are)g(the)681
3591 y(t)n(w)n(o)40 b(only)g(things)g(necessary)f(for)i(de\014ning)f(a)
3600 y(t)n(w)n(o)40 b(only)g(things)g(necessary)f(for)i(de\014ning)f(a)
h(new)g Fh(STklos)f Fo(widget.)g(This)h(p)r(oin)n(t)f(is)681
3690 y(particularly)25 b(imp)r(ortan)n(t)i(since)h(it)h(p)r(ermits)e
3699 y(particularly)25 b(imp)r(ortan)n(t)i(since)h(it)h(p)r(ermits)e
(to)j(minimize)25 b(the)k(in)n(tegration)d(cost)j(of)h(new)681
3790 y(Tk)24 b(widgets)f(and,)h(consequen)n(tly)-7 b(,)23
3799 y(Tk)24 b(widgets)f(and,)h(consequen)n(tly)-7 b(,)23
b(to)h Fj(fol)t(low)j Fo(future)e(Tk)f(releases)e(with)h(minimal)d(co)r
(ding.)805 3889 y(The)28 b(follo)n(wing)23 b(v)-5 b(ariable)25
(ding.)805 3899 y(The)28 b(follo)n(wing)23 b(v)-5 b(ariable)25
b(de\014nition)h(sho)n(ws)g(ho)n(w)h(w)n(e)g(can)g(use)h(the)g(ab)r(o)n
(v)n(e)e Fe(<Button>)681 3989 y Fo(class:)822 4116 y
(v)n(e)e Fe(<Button>)681 3998 y Fo(class:)822 4128 y
Ff(\(define)41 b(b)e(\(make)i(<Button>)g(:font)f("fixed")1803
4207 y(:command)h(\(lambda)f(\(\))g(\(display)h("Hello\\n"\)\)\)\))681
4342 y Fo(This)27 b(expression)f(assigns)g(to)j(the)g(sym)n(b)r(ol)d
4219 y(:command)h(\(lambda)f(\(\))g(\(display)h("Hello\\n"\)\)\)\))681
4357 y Fo(This)27 b(expression)f(assigns)g(to)j(the)g(sym)n(b)r(ol)d
Fe(b)i Fo(a)g(new)h(instance)e(of)h Fe(<Button>)p Fo(.)e(Changing)681
4442 y(the)f(fon)n(t)g(or)f(the)h(command)e(asso)r(ciated)f(to)j(this)f
4457 y(the)f(fon)n(t)g(or)f(the)h(command)e(asso)r(ciated)f(to)j(this)f
(ob)5 b(ject)25 b(could)f(b)r(e)h(done)g(b)n(y)f(using)g(either)681
4541 y(the)k Fe(slot-set)p Fo(!)c(or)j(the)h(generalized)c
4556 y(the)k Fe(slot-set)p Fo(!)c(or)j(the)h(generalized)c
Fe(set)p Fo(!)j(primitiv)n(es)c(as)k(sho)n(wn)f(in)f(2.2.)p
681 4595 473 4 v 697 4649 a Fb(5)758 4681 y Fn(In)c(fact,)i(this)f
(meta)g(class)h(citation)g(can)f(b)r(e)g(omitted)g(since)g
@ -2595,61 +2591,61 @@ eop
%%Page: 10 10
10 9 bop 822 387 a Ff(\(bind)40 b(r)g("<Enter>")h(\(lambda)g(\(x)f(y\))
1646 479 y(\(format)h(#t)e("Mouse)i(enters)f(in)g(~A)g(~A~\045")g(x)g
(y\)\)\))681 649 y Fo(a)25 b(message)d(is)j(displa)n(y)n(ed,)d(eac)n(h)
(y\)\)\))681 650 y Fo(a)25 b(message)d(is)j(displa)n(y)n(ed,)d(eac)n(h)
i(times)g(the)i(mouse)d(en)n(ters)i(the)g Fe(r)g Fo(rectangle.)f(It)h
(is)f(imp)r(or-)681 749 y(tan)n(t)d(to)h(note)f(here)g(that)h(w)n(e)f
(is)f(imp)r(or-)681 750 y(tan)n(t)d(to)h(note)f(here)g(that)h(w)n(e)f
(w)n(ould)f(use)i Fj(exactly)g Fo(the)g(same)e(expression)f(to)i(asso)r
(ciate)e(suc)n(h)681 848 y(a)29 b(binding)g(to)g(a)h(simple)d(widget)i
(ciate)e(suc)n(h)681 850 y(a)29 b(binding)g(to)g(a)h(simple)d(widget)i
(suc)n(h)h(as)f(a)g(button)i(or)e(a)h(lab)r(el,)e(whereas)g(it)i(needs)
g(t)n(w)n(o)681 948 y(di\013eren)n(t)d(syn)n(tactic)g(forms)g(in)h
g(t)n(w)n(o)681 949 y(di\013eren)n(t)d(syn)n(tactic)g(forms)g(in)h
(Tcl/Tk,)e(since)i(the)g(pro)r(cedures)f(whic)n(h)h(access)f(a)h(can)n
(v)-5 b(as)681 1048 y(item)26 b(or)h(an)g(in)n(terface)f(widget)g(are)h
(di\013eren)n(t.)681 1304 y Fi(Uniform)22 b(Access)i(to)f(the)g(T)-8
(v)-5 b(as)681 1049 y(item)26 b(or)h(an)g(in)n(terface)f(widget)g(are)h
(di\013eren)n(t.)681 1307 y Fi(Uniform)22 b(Access)i(to)f(the)g(T)-8
b(o)s(olkit)35 b Fo(Usage)19 b(of)h(generic)e(functions)i(is)f(also)g
(a)h(signi\014can)n(t)681 1404 y(impro)n(v)n(emen)n(t)29
(a)h(signi\014can)n(t)681 1407 y(impro)n(v)n(emen)n(t)29
b(o)n(v)n(er)j(the)j(Tk)e(basic)f(lev)n(el)g(programming)c(since)33
b(it)g(allo)n(ws)e(an)i(homoge-)681 1503 y(neous)24 b(access)f(to)i(Tk)
b(it)g(allo)n(ws)e(an)i(homoge-)681 1507 y(neous)24 b(access)f(to)i(Tk)
f(commands.)f(Supp)r(ose)h(that)h(w)n(e)g(w)n(an)n(t)f(to)g(giv)n(e)f
(access)g(to)i(the)g(v)-5 b(alue)681 1603 y(of)27 b(a)f
(access)g(to)i(the)g(v)-5 b(alue)681 1606 y(of)27 b(a)f
Fe(scale)f Fo(or)i(an)f Fe(entry)f Fo(widget)h(with)h(the)g(generic)e
(function)i Fe(value)p Fo(.)e(This)h(can)h(easily)681
1702 y(b)r(e)h(done)f(b)n(y)g(the)h(follo)n(wing)c(metho)r(d)j(in)g
Fh(STklos)o Fo(:)822 1884 y Ff(\(define-method)42 b(value)f(\(\(obj)f
(<Tk-simple-widget>\)\))940 1975 y(\(\(Id)g(obj\))g('get\)\))805
2164 y Fo(In)29 b(this)f(case,)g(one)g(metho)r(d)g(is)g(su\016cien)n(t)
1706 y(b)r(e)h(done)f(b)n(y)g(the)h(follo)n(wing)c(metho)r(d)j(in)g
Fh(STklos)o Fo(:)822 1890 y Ff(\(define-method)42 b(value)f(\(\(obj)f
(<Tk-simple-widget>\)\))940 1981 y(\(\(Id)g(obj\))g('get\)\))805
2171 y Fo(In)29 b(this)f(case,)g(one)g(metho)r(d)g(is)g(su\016cien)n(t)
g(to)g(implemen)n(t)e(the)j(getter)f(function)g(since)681
2264 y(the)21 b(Tk)f(sub-option)f(for)h(reading)e(the)j(v)-5
2271 y(the)21 b(Tk)f(sub-option)f(for)h(reading)e(the)j(v)-5
b(alue)19 b(of)h(a)g(scale)f(or)h(an)g(en)n(try)g(is)f(the)i(same.)e(W)
-7 b(riting)681 2363 y(the)33 b(setter)g(function)f(for)h(those)f
-7 b(riting)681 2371 y(the)33 b(setter)g(function)f(for)h(those)f
(widgets)g(is)g(a)h(little)d(bit)j(more)e(complicated)f(since)h(the)681
2463 y(w)n(a)n(y)k(of)h(c)n(hanging)e(a)i(scale)e(v)-5
2470 y(w)n(a)n(y)k(of)h(c)n(hanging)e(a)i(scale)e(v)-5
b(alue)36 b(is)f(di\013eren)n(t)g(from)g(the)i(w)n(a)n(y)e(of)h(c)n
(hanging)e(an)i(en)n(try)681 2562 y(v)-5 b(alue)26 b(in)h(Tk:)822
2744 y Ff(\(define-method)42 b(\(setter)f(value\))g(\(\(obj)f
(<Scale>\))h(v\))900 2835 y(\(\(Id)g(obj\))f('set)g(v\)\))822
3018 y(\(define-method)i(\(setter)f(value\))g(\(\(obj)f(<Entry>\))h
(v\))900 3109 y(\(\(Id)g(obj\))f('delete)g(0)g('end\))900
3201 y(\(\(Id)h(obj\))f('insert)g(0)g(v\)\))805 3389
(hanging)e(an)i(en)n(try)681 2570 y(v)-5 b(alue)26 b(in)h(Tk:)822
2754 y Ff(\(define-method)42 b(\(setter)f(value\))g(\(\(obj)f
(<Scale>\))h(v\))900 2845 y(\(\(Id)g(obj\))f('set)g(v\)\))822
3028 y(\(define-method)i(\(setter)f(value\))g(\(\(obj)f(<Entry>\))h
(v\))900 3119 y(\(\(Id)g(obj\))f('delete)g(0)g('end\))900
3210 y(\(\(Id)h(obj\))f('insert)g(0)g(v\)\))805 3400
y Fo(Using)21 b(the)h(same)e(generic)g(function)i(\(with)f(t)n(w)n(o)g
(di\013eren)n(t)g(metho)r(ds\))h(p)r(ermits)e(to)h(hide)681
3489 y(to)34 b(the)g(user)g(these)g(lo)n(w)f(lev)n(el)f(details)f(and)k
3500 y(to)34 b(the)g(user)g(these)g(lo)n(w)f(lev)n(el)f(details)f(and)k
(giv)n(es)d(him/her)f(a)j(coheren)n(t)f(access)g(to)h(the)681
3588 y(to)r(olkit.)25 b(In)j(the)g(call,)822 3752 y Ff(\(set!)40
b(\(value)h(x\))f(100\))681 3922 y Fo(the)27 b(system)e(c)n(ho)r(oses)g
3600 y(to)r(olkit.)25 b(In)j(the)g(call,)822 3765 y Ff(\(set!)40
b(\(value)h(x\))f(100\))681 3937 y Fo(the)27 b(system)e(c)n(ho)r(oses)g
(the)i(metho)r(d)f(to)g(apply)f(dep)r(ending)h(on)g(the)h(class)e(of)h
Fe(x)p Fo(.)g(Of)h(course,)681 4022 y(an)k(error)978
3992 y Fc(6)1044 4022 y Fo(will)d(b)r(e)k(signaled)c(if)j
Fe(x)p Fo(.)g(Of)h(course,)681 4036 y(an)k(error)978
4006 y Fc(6)1044 4036 y Fo(will)d(b)r(e)k(signaled)c(if)j
Fe(x)g Fo(is)f(not)h(an)g(en)n(try)f(or)h(a)g(scale.)e(Note)i(that)h
(this)e(notion)681 4122 y(of)35 b(widget)g(v)-5 b(alue)35
(this)e(notion)681 4136 y(of)35 b(widget)g(v)-5 b(alue)35
b(could)f(also)g(b)r(e)i(easily)c(implemen)n(ted)h(with)i(a)g(virtual)e
(slot)i(\(see)24 b(2.2\))681 4221 y(ev)n(en)35 b(if)g
(slot)i(\(see)24 b(2.2\))681 4236 y(ev)n(en)35 b(if)g
Fe(:value)e Fo(do)r(es)j(not)f(exist)g(as)g(a)g(Tk)g(option)g
Fj(p)l(er)25 b(se)p Fo(.)36 b(This)f(approac)n(h,)e(whic)n(h)i(is)681
4321 y(the)29 b(one)g(c)n(hosen)e(in)i(the)g(curren)n(t)f(released)e
4335 y(the)29 b(one)g(c)n(hosen)e(in)i(the)g(curren)n(t)f(released)e
(library)-7 b(,)26 b(allo)n(ws)g(in)n(trosp)r(ecting)g(functions)i(to)
681 4421 y(manage)22 b(the)j(v)-5 b(alue)23 b(of)i(a)f(widget)f(as)h(a)
681 4435 y(manage)22 b(the)j(v)-5 b(alue)23 b(of)i(a)f(widget)f(as)h(a)
g(standard)g(slot.)f(In)h(particular,)e(this)h(library)f(o\013ers)681
4520 y(a)27 b(small)e(in)n(terface)h(builder)g(whic)n(h)h(hea)n(vily)e
4535 y(a)27 b(small)e(in)n(terface)h(builder)g(whic)n(h)h(hea)n(vily)e
(use)j(in)n(trosp)r(ection)d(to)j(automatically)23 b(build)p
681 4595 473 4 v 697 4649 a Fb(6)758 4681 y Fn(more)31
b(exactly)-6 b(,)32 b(the)f(system)g(calls)j(the)d Ff
@ -2738,17 +2734,17 @@ eop
%%Page: 12 12
12 11 bop 822 387 a Fo(con)n(v)n(en)n(tions\))30 b(for)i(the)h(widget)e
(whic)n(h)g(will)f(implemen)n(t)f(the)k(new)f(instance.)g(Then,)822
487 y(the)c(instance)e(creation)f(argumen)n(ts)h(list)f(m)n(ust)i(b)r
(e)h(\014ltered)f(to)g(distinguish)d(the)k(user)822 587
y(argumen)n(ts)16 b(whic)n(h)i(concern)g(only)f Fh(STklos)h
Fo(\()p Fj(e.g.)27 b Fo(the)19 b Fe(parent)d Fo(slot)i(discussed)f(in)h
(3.1\))822 686 y(from)25 b(those)i(whic)n(h)f(corresp)r(ond)f(to)i(Tk)g
(options.)e(This)h(distinction)e(among)h(param-)822 786
y(eters)j(is)f(necessary)f(b)r(ecause)i(the)g(Tk)g(library)d(raises)h
(an)i(error)e(when)i(it)g(encoun)n(ters)822 886 y(a)f(parameter)e(it)i
(do)r(es)h(not)f(kno)n(w)g(ho)n(w)g(to)g(manage.)733
987 y Fi({)41 b Fo(the)25 b(p)r(ossibilit)n(y)c(to)j(de\014ne)h(slots)f
(with)g(sp)r(ecial)e(b)r(eha)n(viour)h(and)i(allo)r(cation)20
487 y(the)g(instance)e(creation)f(argumen)n(ts)g(list)g(m)n(ust)i(b)r
(e)h(\014ltered)e(to)h(distinguish)d(the)k(us-)822 587
y(er)k(argumen)n(ts)e(whic)n(h)h(concern)g(only)g Fh(STklos)g
Fo(\()p Fj(e.g.)27 b Fo(the)36 b Fe(parent)e Fo(slot)h(discussed)822
686 y(in)28 b(3.1\))h(from)f(those)g(whic)n(h)g(corresp)r(ond)g(to)h
(Tk)g(options.)e(This)h(distinction)f(among)822 786 y(parameters)i(is)i
(necessary)f(b)r(ecause)h(the)i(Tk)e(library)e(raises)g(an)j(error)e
(when)i(it)f(en-)822 886 y(coun)n(ters)26 b(a)i(parameter)d(it)i(do)r
(es)g(not)h(kno)n(w)e(ho)n(w)h(to)h(manage.)733 987 y
Fi({)41 b Fo(the)25 b(p)r(ossibilit)n(y)c(to)j(de\014ne)h(slots)f(with)
g(sp)r(ecial)e(b)r(eha)n(viour)h(and)i(allo)r(cation)20
b(sc)n(hemes.)822 1086 y(In)31 b(e\013ect,)g(b)r(ey)n(ond)g(virtual)d
(slots)h(already)f(discussed)h(in)h(2.2,)g(the)h(proto)r(col)e(should)
822 1186 y(allo)n(w)38 b(to)j(map)f(the)h(Tk)g(widget)f(options)f(as)i
@ -2977,124 +2973,123 @@ y Fo(metho)r(d)i(for)f(can)n(v)-5 b(as)28 b(items)f(follo)n(ws)f(the)k
2170 y(w)n(e)e(will)d(compare)h(the)i Fh(STk)g Fo(basic)e(la)n(y)n(er)f
(with)j(Tcl/Tk)e(\014rst)i(and)f(then)i(w)n(e)e(will)f(compare)365
2270 y Fh(STk)28 b Fo(and)f Fh(STklos)o Fo(.)490 2370
y(Tcl)g(is)g(b)n(y)h(nature)g(an)g(in)n(terpreted)e(language)g(and)i
(some)e(of)j(its)e(asp)r(ects)h(mak)n(e)e(di\016-)365
2470 y(cult)d(the)g(writing)d(of)j(a)f(compiler)e(for)i(this)g
(language.)e(F)-7 b(urthermore,)21 b(the)i(fact)g(that)h(Tcl)d(is)365
2570 y(a)h(string)f(language)f(implies)f(that)j(the)h(v)-5
b(alues)21 b(manipulated)f(b)n(y)i(a)g(program)e(m)n(ust)h(alw)n(a)n
(ys)365 2669 y(b)r(e)33 b(con)n(v)n(erted)f(to)g(strings,)f(whic)n(h)h
(is)g(time)f(consuming.)f(This)i(explains)e(the)k(p)r(o)r(or)e(p)r(er-)
365 2769 y(formances)25 b(of)i(the)g(curren)n(t)f(Tcl)g(in)n
(terpreter.)e(Some)i(compilers)d(for)j(this)g(language)e(ha)n(v)n(e)365
2869 y(b)r(een)k(announced)f(but,)i(to)e(our)g(kno)n(wledge,)e(none)j
(has)f(b)r(een)h(ac)n(hiev)n(ed)d(at)j(this)f(date.)490
2969 y Fh(STk)k Fo(curren)n(t)f(implemen)n(tation)c(also)j(relies)g(on)
h(an)h(in)n(terpreter.)e(Ho)n(w)n(ev)n(er,)g(the)j(se-)365
3069 y(man)n(tic)24 b(of)j(the)f(Sc)n(heme)g(programming)21
y(Tcl)34 b(is)g(b)n(y)h(nature)g(an)g(in)n(terpreted)f(language)f(and)i
(some)e(of)j(its)e(asp)r(ects)h(mak)n(e)e(d-)365 2470
y(i\016cult)g(the)h(writing)d(of)i(a)h(compiler)c(for)j(this)g
(language.)e(F)-7 b(urthermore,)31 b(the)j(fact)g(that)365
2570 y(Tcl)25 b(is)f(a)h(string)f(language)f(implies)f(that)k(the)g(v)
-5 b(alues)24 b(manipulated)e(b)n(y)k(a)f(program)d(m)n(ust)365
2669 y(alw)n(a)n(ys)g(b)r(e)k(con)n(v)n(erted)e(to)h(strings,)e(whic)n
(h)h(is)g(time)f(consuming.)g(This)h(explains)e(the)k(p)r(o)r(or)365
2769 y(p)r(erformances)32 b(of)i(the)h(curren)n(t)e(Tcl)g(in)n
(terpreter.)f(Some)h(compilers)d(for)k(this)f(language)365
2869 y(ha)n(v)n(e)k(b)r(een)g(announced)g(but,)h(to)g(our)e(kno)n
(wledge,)g(none)h(has)g(b)r(een)g(ac)n(hiev)n(ed)f(at)h(this)365
2968 y(date.)490 3069 y Fh(STk)31 b Fo(curren)n(t)f(implemen)n(tation)c
(also)j(relies)g(on)h(an)h(in)n(terpreter.)e(Ho)n(w)n(ev)n(er,)g(the)j
(se-)365 3169 y(man)n(tic)24 b(of)j(the)f(Sc)n(heme)g(programming)21
b(language)i(has)j(b)r(een)h(designed)e(to)h(allo)n(w)d(simple)365
3169 y(and)f(e\016cien)n(t)g(in)n(terpreters)d(or)j(compilers)c
3268 y(and)f(e\016cien)n(t)g(in)n(terpreters)d(or)j(compilers)c
(implemen)n(tations.)f Fh(STk)22 b Fo(in)n(terpreter)e(is)h(hence)365
3268 y(small)h(an)i(o\013ers)g(go)r(o)r(d)g(p)r(erformances.)f(In)i
3368 y(small)h(an)i(o\013ers)g(go)r(o)r(d)g(p)r(erformances.)f(In)i
(particular,)c(it)j(runs)h(4)f(to)h(7)f(times)f(faster)h(than)365
3368 y(Tcl)c(in)n(terpreter)e(on)j(general)d(purp)r(ose)i
3467 y(Tcl)c(in)n(terpreter)e(on)j(general)d(purp)r(ose)i
(computations.)e(When)j(using)e(the)i(Tk)g(to)r(olkit,)d(Tcl)365
3467 y(tak)n(es)24 b(adv)-5 b(an)n(tage)24 b(of)h(the)g(w)n(a)n(y)f
3567 y(tak)n(es)24 b(adv)-5 b(an)n(tage)24 b(of)h(the)g(w)n(a)n(y)f
(argumen)n(ts)e(are)i(passed)h(to)f(the)i(functions)e(of)h(the)g
(library)-7 b(.)365 3567 y(In)27 b(e\013ect,)g(the)g(Tk)g(to)r(olkit)d
(library)-7 b(.)365 3667 y(In)27 b(e\013ect,)g(the)g(Tk)g(to)r(olkit)d
(uses)i(the)h(C)g(language)d Fe(argc/argv)f Fo(classical)f(con)n(v)n
(en)n(tion)i(for)365 3667 y(argumen)n(ts)j(passing.)g(Giv)n(en)i(these)
(en)n(tion)i(for)365 3766 y(argumen)n(ts)j(passing.)g(Giv)n(en)i(these)
g(con)n(v)n(en)n(tions,)d(the)k Fh(STk)f Fo(in)n(terpreter)e(m)n(ust)i
(con)n(v)n(ert)365 3766 y(to)d(strings)e(the)j(parameters)c(giv)n(en)h
(con)n(v)n(ert)365 3866 y(to)d(strings)e(the)j(parameters)c(giv)n(en)h
(to)i Fj(Tk)j(c)l(ommands)p Fo(,)e(whereas)d(this)i(con)n(v)n(ersion)c
(is)j(un-)365 3866 y(necessary)i(in)h(Tcl)g(since)f(ev)n(erything)g(is)
(is)j(un-)365 3966 y(necessary)i(in)h(Tcl)g(since)f(ev)n(erything)g(is)
g(k)n(ept)i(as)f(strings)f(in)h(the)h(in)n(terpreter.)d(Ho)n(w)n(ev)n
(er,)365 3966 y(the)i(p)r(enalt)n(y)f(induced)g(b)n(y)g(these)g(con)n
(er,)365 4065 y(the)i(p)r(enalt)n(y)f(induced)g(b)n(y)g(these)g(con)n
(v)n(ersions)d(is)j(generally)d(negligible)e(facing)k(the)i(o)n(v)n
(er-)365 4065 y(all)d(computation)f(time)i(of)h(a)f(program,)e(and)j
(er-)365 4165 y(all)d(computation)f(time)i(of)h(a)f(program,)e(and)j
(in)n(terfaces)e(written)h(with)g Fh(STk)h Fo(tend)g(to)g(b)r(e)365
4165 y(faster)g(than)h(Tcl)f(ones.)490 4266 y(Let)39
4264 y(faster)g(than)h(Tcl)f(ones.)490 4365 y(Let)39
b(us)g(consider)e(no)n(w)i(the)g(p)r(erformances)e(of)i
Fh(STklos)f Fo(comparing)e(to)j Fh(STk)p Fo(.)g(In)365
4365 y Fh(STklos)o Fo(,)30 b(as)e(in)g(CLOS,)h(the)g(generic)e
4465 y Fh(STklos)o Fo(,)30 b(as)e(in)g(CLOS,)h(the)g(generic)e
(function)i(call)e(mec)n(hanism)e(costs)k(a)f(lot.)g(Because)365
4465 y(this)e(mec)n(hanism)c(can)k(b)r(e)g(the)h(b)r(ottlenec)n(k)e(of)
4565 y(this)e(mec)n(hanism)c(can)k(b)r(e)g(the)h(b)r(ottlenec)n(k)e(of)
h(a)f(MOP)h(based)f(arc)n(hitecture,)f(it)h(has)h(b)r(een)365
4565 y(implemen)n(ted)19 b(in)j(C)h(to)f(b)r(e)h(as)f(fast)g(as)g(p)r
4664 y(implemen)n(ted)19 b(in)j(C)h(to)f(b)r(e)h(as)f(fast)g(as)g(p)r
(ossible.)e(Ho)n(w)n(ev)n(er,)h(the)i(curren)n(t)e(implemen)n(tation)
365 4664 y(is)31 b(relativ)n(ely)d(direct)j(and)g(don't)i(use)e(y)n(et)
365 4764 y(is)31 b(relativ)n(ely)d(direct)j(and)g(don't)i(use)e(y)n(et)
h(the)h(optimizations)27 b(whic)n(h)k(can)g(generally)e(b)r(e)365
4764 y(applied)h(on)h(generic)e(function)i(calls.)e(This)h(explains)f
(the)j(relativ)n(e)c(p)r(o)r(or)j(p)r(erformances)365
4863 y(of)42 b(generic)d(function)i(calls)e(compared)g(to)i(closure)f
(in)n(v)n(o)r(cation.)e(Actually)-7 b(,)39 b(a)i(generic)p
eop
4863 y(applied)h(on)h(generic)e(function)i(calls.)e(This)h(explains)f
(the)j(relativ)n(e)c(p)r(o)r(or)j(p)r(erformances)p eop
%%Page: 16 16
16 15 bop 681 387 a Fo(function)23 b(call)f(is)h(6)h(times)e(slo)n(w)n
16 15 bop 681 387 a Fo(of)41 b(generic)f(function)g(calls)f(compared)g
(to)j(closure)d(in)n(v)n(o)r(cation.)f(Actually)-7 b(,)40
b(a)h(generic)681 487 y(function)23 b(call)f(is)h(6)h(times)e(slo)n(w)n
(er)f(than)j(a)g(simple)d(Sc)n(heme)i(function)h(call.)d(Consequen)n
(tly)-7 b(,)681 487 y(an)25 b(in)n(terface)f(written)g(in)h
(tly)-7 b(,)681 587 y(an)25 b(in)n(terface)f(written)g(in)h
Fh(STklos)f Fo(is)h(far)f(m)n(uc)n(h)h(slo)n(w)n(er)d(than)k(an)f
(application)c(resorting)681 587 y(only)28 b(on)h(simple)d
(application)c(resorting)681 686 y(only)28 b(on)h(simple)d
Fh(STk)j Fo(constructs.)g(The)h(generic)d(function)i(o)n(v)n(erhead)e
(can)i(ev)n(en)g(mak)n(es)681 686 y Fh(STklos)40 b Fo(programs,)e
(can)i(ev)n(en)g(mak)n(es)681 786 y Fh(STklos)40 b Fo(programs,)e
(under)j(certain)f(circumstances,)e(a)j(little)e(bit)i(slo)n(w)n(er)d
(than)k(Tcl)681 786 y(programs.)26 b(Ho)n(w)n(ev)n(er,)h(applying)g
(than)k(Tcl)681 886 y(programs.)26 b(Ho)n(w)n(ev)n(er,)h(applying)g
Fj(memoization)k Fo(optimization)25 b(tec)n(hniques)j(suc)n(h)h(as)f
(the)681 886 y(one)35 b(presen)n(ted)g(in)g([10])h(will)d(decrease)h
(the)681 985 y(one)35 b(presen)n(ted)g(in)g([10])h(will)d(decrease)h
(the)i(ratio)e(b)r(et)n(w)n(een)i(generic)d(and)j(non)g(generic)681
985 y(functions)27 b(to)g(pro)n(vide)f(p)r(erformances)f(close)h(to)h
(the)h(basic)e(la)n(y)n(er.)681 1262 y Fk(5)112 b(Conclusion)681
1470 y Fo(W)-7 b(e)38 b(ha)n(v)n(e)f(sho)n(wn)h(in)g(this)f(pap)r(er)h
1085 y(functions)27 b(to)g(pro)n(vide)f(p)r(erformances)f(close)h(to)h
(the)h(basic)e(la)n(y)n(er.)681 1347 y Fk(5)112 b(Conclusion)681
1540 y Fo(W)-7 b(e)38 b(ha)n(v)n(e)f(sho)n(wn)h(in)g(this)f(pap)r(er)h
(the)h Fh(STklos)e Fo(ob)5 b(ject)38 b(system)f(and)h(ho)n(w)g(it)f
(can)h(b)r(e)681 1569 y(tailored)31 b(to)j(pro)n(vide)e(an)h(easy)h
(can)h(b)r(e)681 1640 y(tailored)31 b(to)j(pro)n(vide)e(an)h(easy)h
(access)e(to)i(a)g(standard)f(graphical)e(to)r(olkit.)h(One)h(of)h(the)
681 1669 y(ma)5 b(jor)31 b(b)r(ene\014ts)j(of)f(this)g(system)f(is)h
681 1739 y(ma)5 b(jor)31 b(b)r(ene\014ts)j(of)f(this)g(system)f(is)h
(that)h(it)e(allo)n(ws)f(a)i(neat)g Fj(r)l(ei\014c)l(ation)h
Fo(of)g(a)f(class-less)681 1769 y(to)r(olkit.)i(This)h(p)r(oin)n(t)g
Fo(of)g(a)f(class-less)681 1839 y(to)r(olkit.)i(This)h(p)r(oin)n(t)g
(is)g(imp)r(ortan)n(t)e(since)i(it)g(is)g(generally)e(admitted)h(that)i
(an)g(ob)5 b(ject)681 1868 y(vision)25 b(of)i(widgets)g(greatly)e
(an)g(ob)5 b(ject)681 1939 y(vision)25 b(of)i(widgets)g(greatly)e
(impro)n(v)n(es)f(the)k(lev)n(el)d(of)i(GUI)i(programming.)805
1970 y Fh(STklos)g Fo(pro)n(vides)e(a)h(real)g(programming)c(language)j
(for)h(the)i(Tk)f(to)r(olkit.)e(F)-7 b(urther-)681 2069
2038 y Fh(STklos)g Fo(pro)n(vides)e(a)h(real)g(programming)c(language)j
(for)h(the)i(Tk)f(to)r(olkit.)e(F)-7 b(urther-)681 2138
y(more,)28 b(the)i(underlying)d(meta)h(ob)5 b(ject)30
b(proto)r(col)d(of)j Fh(STklos)f Fo(pro)n(vides)e(a)i(pleasan)n(t)f(w)n
(a)n(y)681 2169 y(to)d(access)f(the)h(to)r(olkit)e(options)g(for)i(eac)
(a)n(y)681 2237 y(to)d(access)f(the)h(to)r(olkit)e(options)g(for)i(eac)
n(h)f(widget)g(and)h(it)g(allo)n(ws)c(us)k(to)g(hide)f(most)g(of)h(the)
681 2269 y(idiosyncrasies)20 b(of)26 b(this)e(to)r(olkit)g(in)h(a)g
681 2337 y(idiosyncrasies)20 b(of)26 b(this)e(to)r(olkit)g(in)h(a)g
(clean)f(w)n(a)n(y)-7 b(.)24 b(It)i(mak)n(es)e(easier)f(the)j(dev)n
(elop)r(emen)n(t)d(of)681 2368 y(large)29 b(Graphical)g(User)i(In)n
(elop)r(emen)n(t)d(of)681 2437 y(large)29 b(Graphical)g(User)i(In)n
(terfaces)g(with)h(Tk,)f(and)h(extend)g(hence)g(the)g(in)n(terest)f(of)
g(this)681 2468 y(to)r(olkit.)681 2725 y Fi(Av)-5 b(ailabilit)m(y)681
2899 y Fh(STklos)37 b Fo(is)h(distributed)e(with)i(the)h
g(this)681 2536 y(to)r(olkit.)681 2779 y Fi(Av)-5 b(ailabilit)m(y)681
2939 y Fh(STklos)37 b Fo(is)h(distributed)e(with)i(the)h
Fh(STk)f Fo(pac)n(k)-5 b(age)37 b(and)h(runs)g(on)g(a)g(wide)f(v)-5
b(ariet)n(y)37 b(of)681 2999 y(arc)n(hitectures)32 b(and)i(systems.)f
b(ariet)n(y)37 b(of)681 3038 y(arc)n(hitectures)32 b(and)i(systems.)f
(The)h(last)f(v)n(ersion)f(of)i(this)f(pac)n(k)-5 b(age)33
b(is)g(a)n(v)-5 b(ailable)30 b(at)k(the)681 3099 y(follo)n(wing)23
b(is)g(a)n(v)-5 b(ailable)30 b(at)k(the)681 3138 y(follo)n(wing)23
b(address:)k Fe(ftp://kaolin.uni)o(ce)o(.f)o(r/p)o(ub)o(/ST)o(k.)o(ta)o
(r.g)o(z)-6 b Fo(.)681 3376 y Fk(References)719 3575
(r.g)o(z)-6 b Fo(.)681 3400 y Fk(References)719 3585
y Fn(1.)42 b(William)20 b(Clinger)g(and)e(Jonathan)26
b(Rees)19 b(\(editors\).)32 b Fa(R)q(ev)s(ised)2634 3543
y Fb(4)2686 3575 y Fn(Rep)r(ort)18 b(on)h(the)g(Algorithmic)820
3666 y(Language)27 b(Sc)n(heme.)33 b Fd(A)n(CM)27 b(Lisp)h(Pointers)p
Fn(,)f(4\(3\),)g(1991.)719 3759 y(2.)42 b(Apple)33 b(Computer.)58
b(Rees)19 b(\(editors\).)32 b Fa(R)q(ev)s(ised)2634 3553
y Fb(4)2686 3585 y Fn(Rep)r(ort)18 b(on)h(the)g(Algorithmic)820
3676 y(Language)27 b(Sc)n(heme.)33 b Fd(A)n(CM)27 b(Lisp)h(Pointers)p
Fn(,)f(4\(3\),)g(1991.)719 3768 y(2.)42 b(Apple)33 b(Computer.)58
b Fd(Dylan:)35 b(an)g(Obje)l(ct)g(Oriente)l(d)h(Dynamic)f(L)l(anguage)p
Fn(.)60 b(Apple,)34 b(April)820 3851 y(1992.)719 3944
Fn(.)60 b(Apple,)34 b(April)820 3859 y(1992.)719 3950
y(3.)42 b(Eric)n(k)23 b(Gallesio.)36 b(Em)n(b)r(edding)21
b(a)i(sc)n(heme)e(in)n(terpreter)h(in)h(the)f(Tk)g(to)r(olkit.)34
b(In)22 b(La)n(wrence)k(A.)820 4035 y(Ro)n(w)n(e,)h(editor,)f
b(In)22 b(La)n(wrence)k(A.)820 4041 y(Ro)n(w)n(e,)h(editor,)f
Fd(First)i(Tcl/Tk)g(Workshop,)g(Berkeley)p Fn(,)f(pages)g(103{109,)i
(June)c(1993.)719 4128 y(4.)42 b(Eric)n(k)36 b(Gallesio.)66
(June)c(1993.)719 4133 y(4.)42 b(Eric)n(k)36 b(Gallesio.)66
b Fl(STklos)q Fn(:)36 b(A)f(sc)n(heme)g(ob)t(ject)i(orien)n(ted)e
(system)g(dealing)h(with)g(the)f(tk)820 4219 y(to)r(olkit.)h(In)25
(system)g(dealing)h(with)g(the)f(tk)820 4224 y(to)r(olkit.)h(In)25
b(ICS,)g(editor,)i Fd(Xhibition)g(94,)g(San)h(Jose,)g(CA)p
Fn(,)e(pages)h(63{71,)h(June)d(1994.)719 4312 y(5.)42
Fn(,)e(pages)h(63{71,)h(June)d(1994.)719 4315 y(5.)42
b(Eric)n(k)27 b(Gallesio.)40 b Fl(STk)26 b Fn(reference)h(man)n(ual.)37
b(T)-6 b(ec)n(hnical)27 b(Rep)r(ort)f(R)-6 b(T)25 b(95-31a,)j(I3S)f
(CNRS)e(/)820 4404 y(Univ)n(ersit)n(\023)-36 b(e)26 b(de)f(Nice)h(-)f
(Sophia)h(An)n(tip)r(olis,)g(juillet)h(1995.)719 4496
(CNRS)e(/)820 4407 y(Univ)n(ersit)n(\023)-36 b(e)26 b(de)f(Nice)h(-)f
(Sophia)h(An)n(tip)r(olis,)g(juillet)h(1995.)719 4498
y(6.)42 b(Jim)26 b(de)e(Rivi)n(\022)-36 b(eres)26 b(Gregor)g(Kic)n
(kzales)h(and)e(Daniel)g(G.)h(Bobro)n(w.)36 b Fd(The)28
b(A)n(rt)g(of)f(Meta)h(Obje)l(ct)820 4588 y(Pr)l(oto)l(c)l(ol)p
b(A)n(rt)g(of)f(Meta)h(Obje)l(ct)820 4589 y(Pr)l(oto)l(c)l(ol)p
Fn(.)36 b(MIT)27 b(Press,)g(1991.)719 4681 y(7.)42 b(Daniel)19
b(D.)g(Bobro)n(w,)h(Linda)e(G)h(DeMic)n(hiel,)g(Ric)n(hard)f(P)-6
b(.)19 b(Gabriel,)26 b(Son)n(y)n(a)18 b(E.)h(Keene,)f(Gregor)820
@ -3135,14 +3130,14 @@ b(Digital)35 b(Press,)f(12)505 1757 y(Crosb)n(y)26 b(Driv)n(e,)f
b(A)f(Minimal)i(Meta)f(Ob)6 b(ject)38 b(Proto)s(col)f(for)g(Tk)365
2338 y Fo(Hereafter)32 b(is)f(a)h(minimal)27 b(implemen)n(tation)h(of)k
(the)h(Meta)f(Ob)5 b(ject)32 b(Proto)r(col)d(describ)r(ed)365
2429 y(in)d(section)f(3.)h(Three)g(widgets)e(classes)g(\()p
Fe(<Canvas>)p Fo(,)g Fe(<Label>)f Fo(and)k Fe(<Button>)p
Fo(\))c(and)j(t)n(w)n(o)365 2521 y(can)n(v)-5 b(as)28
b(items)f(\()p Fe(<Line>)f Fo(and)i Fe(<Rectangle>)p
Fo(\))d(are)j(de\014ned)h(using)e(this)h(MOP)-7 b(.)28
b(The)g(pro-)365 2612 y(to)r(col)35 b(exp)r(osed)g(here)h(has)f(b)r
(een)h(simpli\014ed)d(to)j(\014t)g(in)f(the)h(limited)d(size)i(of)h
(this)f(pap)r(er)365 2703 y(and)c(de\014ned)g(widgets)e(recognize)g
2429 y(in)j(section)f(3.)i(Three)f(widgets)f(classes)f(\()p
Fe(<Canvas>)p Fo(,)g Fe(<Label>)g Fo(and)i Fe(<Button>)p
Fo(\))e(and)i(t-)365 2521 y(w)n(o)h(can)n(v)-5 b(as)31
b(items)h(\()p Fe(<Line>)f Fo(and)h Fe(<Rectangle>)p
Fo(\))d(are)j(de\014ned)i(using)d(this)i(MOP)-7 b(.)32
b(The)365 2612 y(proto)r(col)25 b(exp)r(osed)i(here)g(has)g(b)r(een)h
(simpli\014ed)23 b(to)28 b(\014t)f(in)g(the)h(limited)c(size)i(of)h
(this)g(pap)r(er)365 2703 y(and)k(de\014ned)g(widgets)e(recognize)g
(only)g(a)h(small)e(subset)i(of)h(the)g(Tk)g(options.)e(Ho)n(w)n(ev)n
(er,)365 2795 y(in)e(spite)g(of)h(this)e(size,)h(this)g(MOP)f(is)h
(completely)d(op)r(erational.)393 3037 y Fd(;;;;)393

View File

@ -1,19 +1,20 @@
#
# Documentation Makefile
#
# Copyright (C) 1993,1994,1995 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
# Copyright © 1994-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
#
# Permission to use, copy, and/or distribute this software and its
# documentation for any purpose and without fee is hereby granted, provided
# that both the above copyright notice and this permission notice appear in
# all copies and derived works. Fees for distribution or use of this
# software or derived works may only be charged with express written
# permission of the copyright holder.
# This software is provided ``as is'' without express or implied warranty.
# Permission to use, copy, modify, distribute,and license this
# software and its documentation for any purpose is hereby granted,
# provided that existing copyright notices are retained in all
# copies and that this notice is included verbatim in any
# distributions. No written agreement, license, or royalty fee is
# required for any of the authorized uses.
# This software is provided ``AS IS'' without express or implied
# warranty.
#
# Author: Erick Gallesio [eg@unice.fr]
# Creation date: 21-Oct-1994 11:25
# Last file update: 20-Aug-1997 14:00
# Last file update: 3-Sep-1999 21:22 (eg)
include ../config.make

View File

@ -1,16 +1,17 @@
# Copyright (C) 1993,1994,1995 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
# Copyright © 1994-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
#
# Permission to use, copy, and/or distribute this software and its
# documentation for any purpose and without fee is hereby granted, provided
# that both the above copyright notice and this permission notice appear in
# all copies and derived works. Fees for distribution or use of this
# software or derived works may only be charged with express written
# permission of the copyright holder.
# This software is provided ``as is'' without express or implied warranty.
# Permission to use, copy, modify, distribute,and license this
# software and its documentation for any purpose is hereby granted,
# provided that existing copyright notices are retained in all
# copies and that this notice is included verbatim in any
# distributions. No written agreement, license, or royalty fee is
# required for any of the authorized uses.
# This software is provided ``AS IS'' without express or implied
# warranty.
#
# Author: Erick Gallesio [eg@unice.fr]
# Creation date: 21-Oct-1994 11:25
# Last file update: 20-Apr-1998 21:43
# Last file update: 3-Sep-1999 21:19 (eg)
include ../../config.make
@ -64,7 +65,7 @@ install.man:
# ../../Src/test-stk -no -file make-link $(MANN_DIR)
clean:
rm -f *~
rm -f *~ man-pages.ps
very-clean: clean
rm -f *.ps

47
Doc/Manual/ed.n Normal file
View File

@ -0,0 +1,47 @@
'\" Color=Green
'\"
'\" Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\"
'\" Permission to use, copy, modify, distribute,and license this
'\" software and its documentation for any purpose is hereby granted,
'\" provided that existing copyright notices are retained in all
'\" copies and that this notice is included verbatim in any
'\" distributions. No written agreement, license, or royalty fee is
'\" required for any of the authorized uses.
'\" This software is provided ``AS IS'' without express or implied
'\" warranty.
'\"
'\" Author: Erick Gallesio [eg@unice.fr]
'\" Creation date: 19-Jul-1996 15:21
'\" Last file update: 3-Sep-1999 21:20 (eg)
'\"
'\"
.so STk-man.macros
.TH ed n 4.0 STk "Tk Built-In Commands"
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
ed \- Launch an editor
.SH SYNOPSIS
(\fBed\fR)
.br
(\fBed\fI \fIfilename\fR)
.SH DESCRIPTION
.PP
The \fBed\fR procedure creates a new Scheme editor in a toplevel
window. If a filename is provided, its content is displayed in the
editor window.
.LP
.SH "DEFAULT BINDINGS"
.PP
The defaults bindings are identical to the \fBtext\fR
bindings. Furthermore, if a the interpreter uses a console to interact
with the user (by default on Windows, or by using the \fB\-console\fR
option of \fBstk\fR on Unix), the Enter key of the numerical keyboard
or the sequence Control-Return sends the previous complete sexpr to
the interpreter.
.SH SEE ALSO
text

View File

@ -1,18 +1,19 @@
'\" Color=Yellow
'\"
'\" Copyright © 1996-1997 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\" Copyright © 1996-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\"
'\" Permission to use, copy, and/or distribute this software and its
'\" documentation for any purpose and without fee is hereby granted, provided
'\" that both the above copyright notice and this permission notice appear in
'\" all copies and derived works. Fees for distribution or use of this
'\" software or derived works may only be charged with express written
'\" permission of the copyright holder.
'\" This software is provided ``as is'' without express or implied warranty.
'\" Permission to use, copy, modify, distribute,and license this
'\" software and its documentation for any purpose is hereby granted,
'\" provided that existing copyright notices are retained in all
'\" copies and that this notice is included verbatim in any
'\" distributions. No written agreement, license, or royalty fee is
'\" required for any of the authorized uses.
'\" This software is provided ``AS IS'' without express or implied
'\" warranty.
'\"
'\" Author: Erick Gallesio [eg@unice.fr]
'\" Creation date: 8-Jul-1996 08:16
'\" Last file update: 28-Dec-1997 21:54
'\" Last file update: 3-Sep-1999 21:17 (eg)
'\"
.so STk-man.macros
.TH ftp n 3.1 STk "STk procedures"

View File

@ -1,18 +1,19 @@
'\" Color=Green
'\"
'\" Copyright © 1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\" Copyright © 1996-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\"
'\" Permission to use, copy, and/or distribute this software and its
'\" documentation for any purpose and without fee is hereby granted, provided
'\" that both the above copyright notice and this permission notice appear in
'\" all copies and derived works. Fees for distribution or use of this
'\" software or derived works may only be charged with express written
'\" permission of the copyright holder.
'\" This software is provided ``as is'' without express or implied warranty.
'\" Permission to use, copy, modify, distribute,and license this
'\" software and its documentation for any purpose is hereby granted,
'\" provided that existing copyright notices are retained in all
'\" copies and that this notice is included verbatim in any
'\" distributions. No written agreement, license, or royalty fee is
'\" required for any of the authorized uses.
'\" This software is provided ``AS IS'' without express or implied
'\" warranty.
'\"
'\" Author: Erick Gallesio [eg@unice.fr]
'\" Creation date: 19-Jul-1996 15:21
'\" Last file update: 9-Nov-1996 18:39
'\" Last file update: 3-Sep-1999 21:18 (eg)
'\"
'\"
.so STk-man.macros

52
Doc/Manual/make-console.n Normal file
View File

@ -0,0 +1,52 @@
'\" Color=Green
'\"
'\" Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\"
'\" Permission to use, copy, modify, distribute,and license this
'\" software and its documentation for any purpose is hereby granted,
'\" provided that existing copyright notices are retained in all
'\" copies and that this notice is included verbatim in any
'\" distributions. No written agreement, license, or royalty fee is
'\" required for any of the authorized uses.
'\" This software is provided ``AS IS'' without express or implied
'\" warranty.
'\"
'\" Author: Erick Gallesio [eg@unice.fr]
'\" Creation date: 19-Jul-1996 15:21
'\" Last file update: 3-Sep-1999 21:20 (eg)
'\"
'\"
.so STk-man.macros
.TH console n 4.0 STk "Tk Built-In Commands"
.BS
'\" Note: do not modify the .SH NAME line immediately below!
.SH NAME
make-console \- Create a console
.SH SYNOPSIS
(\fBmake\-console\fR)
.br
(\fBmake\-console\fI \fB:module\fR \fImodule\fR)
.SH DESCRIPTION
.PP
The \fBmake\-console\fR procedure creates a new console in a new
toplevel window. By default the interaction loop is placed in the
current module (and changes if the current module is changed). If the
console is created in a given module, thanks to the \fB:module\fR
option, it is tied to this module. This second form of console
creation is particularly useful in debugging phases to set or consult
variables which are not exported in a module.
.LP
.SH INITIALIZATION
.PP
Use \fB(require "console")\fR to load the console package.
.LP
.SH "DEFAULT BINDINGS"
.PP
The defaults bindings are identical to the \fBtext\fR bindings except the
up and down arrow of on the prompt line which allow to scan the command history.
.SH SEE ALSO
text

View File

@ -1,18 +1,19 @@
'\" Color=Yellow
'\"
'\" Copyright © 1996 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\" Copyright © 1996-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
'\"
'\" Permission to use, copy, and/or distribute this software and its
'\" documentation for any purpose and without fee is hereby granted, provided
'\" that both the above copyright notice and this permission notice appear in
'\" all copies and derived works. Fees for distribution or use of this
'\" software or derived works may only be charged with express written
'\" permission of the copyright holder.
'\" This software is provided ``as is'' without express or implied warranty.
'\" Permission to use, copy, modify, distribute,and license this
'\" software and its documentation for any purpose is hereby granted,
'\" provided that existing copyright notices are retained in all
'\" copies and that this notice is included verbatim in any
'\" distributions. No written agreement, license, or royalty fee is
'\" required for any of the authorized uses.
'\" This software is provided ``AS IS'' without express or implied
'\" warranty.
'\"
'\" Author: Erick Gallesio [eg@unice.fr]
'\" Creation date: 8-Jul-1996 08:16
'\" Last file update: 19-Jul-1996 14:47
'\" Last file update: 3-Sep-1999 21:18 (eg)
'\"
.so STk-man.macros
.TH posix n 3.1 STk "STk procedures"

View File

@ -21,7 +21,6 @@
'\" ON AN "AS IS" BASIS, AND THE UNIVERSITY OF CALIFORNIA HAS NO OBLIGATION TO
'\" PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
'\"
'\" $Id: stk.1 1.2 Mon, 20 Apr 1998 22:15:01 +0200 eg $
'\"
.so STk-man.macros
.TH STk 1 4.0 STk "January_1998"
@ -78,7 +77,9 @@ Set the default size for the heap to \fInumber\fR cells. The given number is
also the amount of cells used when extending the heap. Default value is 20000.
.IP "\fB\-interactive\fR" 15
Tell the interpreter that it is used interactively (even if it doesn't
think so).
think so).
.IP "\fB\-help\fR" 15
Print the version of the system and abort execution.
.IP "\fB\-help\fR" 15
Print a summary of the command-line options and exit.
.IP "\fB\-\|\-\fR" 15

View File

@ -1,6 +1,6 @@
%!PS-Adobe-3.0
%%Creator: groff version 1.11
%%CreationDate: Mon Sep 14 15:35:30 1998
%%CreationDate: Fri Sep 3 22:18:26 1999
%%DocumentNeededResources: font Times-Roman
%%+ font Times-Bold
%%+ font Times-Italic
@ -268,139 +268,142 @@ F0(,)A F3(pseudocolor)4.11 E F0(,)A F3(staticcolor)4.11 E F0(,)A F3
(ll the interpreter that it is used interacti).7 E -.15(ve)-.25 G
(ly \(e).15 E -.15(ve)-.25 G 2.5(ni).15 G 2.5(fi)-2.5 G 2.5(td)-2.5 G
(oesn')-2.5 E 2.5(tt)-.18 G(hink so\).)-2.5 E F2(\255help)108 540 Q F0
(Print the v)50.96 E(ersion of the system and abort e)-.15 E -.15(xe)
-.15 G(cution.).15 E F2(\255help)108 556.8 Q F0
(Print a summary of the command-line options and e)50.96 E(xit.)-.15 E
F2 1.666<adad>108 556.8 S F0 -.15(Pa)60.268 G 1.029(ss all remaining ar)
F2 1.666<adad>108 573.6 S F0 -.15(Pa)60.268 G 1.029(ss all remaining ar)
.15 F 1.029(guments through to the script')-.18 F(s)-.55 E F2(ar)3.529 E
(gv)-.1 E F0 -.25(va)3.529 G 1.029(riable without interpreting).25 F
4.36(them. This)183 568.8 R(pro)4.36 E 1.859
4.36(them. This)183 585.6 R(pro)4.36 E 1.859
(vides a mechanism for passing ar)-.15 F 1.859(guments such as)-.18 F F2
(\255name)4.359 E F0 1.859(to a script)4.359 F(instead of ha)183 580.8 Q
(ving)-.2 E F2(wish)2.5 E F0(interpret them.)2.5 E .4 LW 64.5 585.3 64.5
595.3 DL 64.5 575.3 64.5 585.3 DL 64.5 565.3 64.5 575.3 DL 64.5 555.3
64.5 565.3 DL 64.5 545.3 64.5 555.3 DL 64.5 535.3 64.5 545.3 DL 64.5
525.3 64.5 535.3 DL 64.5 515.3 64.5 525.3 DL 64.5 505.3 64.5 515.3 DL
64.5 495.3 64.5 505.3 DL 64.5 485.3 64.5 495.3 DL 64.5 475.3 64.5 485.3
DL 64.5 465.3 64.5 475.3 DL 64.5 455.3 64.5 465.3 DL 64.5 445.3 64.5
455.3 DL 64.5 435.3 64.5 445.3 DL 64.5 425.3 64.5 435.3 DL 64.5 415.3
64.5 425.3 DL 64.5 405.3 64.5 415.3 DL 64.5 395.3 64.5 405.3 DL 64.5
385.3 64.5 395.3 DL 64.5 375.3 64.5 385.3 DL 64.5 365.3 64.5 375.3 DL
64.5 355.3 64.5 365.3 DL 64.5 345.3 64.5 355.3 DL 64.5 335.3 64.5 345.3
DL 64.5 325.3 64.5 335.3 DL 64.5 315.3 64.5 325.3 DL 64.5 305.3 64.5
315.3 DL 64.5 295.3 64.5 305.3 DL 64.5 285.3 64.5 295.3 DL 64.5 275.3
64.5 285.3 DL 64.5 265.3 64.5 275.3 DL 64.5 255.3 64.5 265.3 DL 64.5
245.3 64.5 255.3 DL 64.5 235.3 64.5 245.3 DL 64.5 225.3 64.5 235.3 DL
64.5 215.3 64.5 225.3 DL 64.5 205.3 64.5 215.3 DL 64.5 195.3 64.5 205.3
DL 64.5 185.3 64.5 195.3 DL 64.5 175.3 64.5 185.3 DL 64.5 165.3 64.5
175.3 DL 64.5 155.3 64.5 165.3 DL 64.5 145.3 64.5 155.3 DL 64.5 135.3
64.5 145.3 DL 64.5 125.3 64.5 135.3 DL 64.5 115.3 64.5 125.3 DL 64.5
105.3 64.5 115.3 DL 64.5 95.3 64.5 105.3 DL 64.5 85.3 64.5 95.3 DL 64.5
75.3 64.5 85.3 DL 64.5 74.5 64.5 84.5 DL 69.5 74.5 64.5 74.5 DL 72.5
74.5 67.5 74.5 DL 77.5 74.5 72.5 74.5 DL 82.5 74.5 77.5 74.5 DL 87.5
74.5 82.5 74.5 DL 92.5 74.5 87.5 74.5 DL 97.5 74.5 92.5 74.5 DL 102.5
74.5 97.5 74.5 DL 107.5 74.5 102.5 74.5 DL 112.5 74.5 107.5 74.5 DL
117.5 74.5 112.5 74.5 DL 122.5 74.5 117.5 74.5 DL 127.5 74.5 122.5 74.5
DL 132.5 74.5 127.5 74.5 DL 137.5 74.5 132.5 74.5 DL 142.5 74.5 137.5
74.5 DL 147.5 74.5 142.5 74.5 DL 152.5 74.5 147.5 74.5 DL 157.5 74.5
152.5 74.5 DL 162.5 74.5 157.5 74.5 DL 167.5 74.5 162.5 74.5 DL 172.5
74.5 167.5 74.5 DL 177.5 74.5 172.5 74.5 DL 182.5 74.5 177.5 74.5 DL
187.5 74.5 182.5 74.5 DL 192.5 74.5 187.5 74.5 DL 197.5 74.5 192.5 74.5
DL 202.5 74.5 197.5 74.5 DL 207.5 74.5 202.5 74.5 DL 212.5 74.5 207.5
74.5 DL 217.5 74.5 212.5 74.5 DL 222.5 74.5 217.5 74.5 DL 227.5 74.5
222.5 74.5 DL 232.5 74.5 227.5 74.5 DL 237.5 74.5 232.5 74.5 DL 242.5
74.5 237.5 74.5 DL 247.5 74.5 242.5 74.5 DL 252.5 74.5 247.5 74.5 DL
257.5 74.5 252.5 74.5 DL 262.5 74.5 257.5 74.5 DL 267.5 74.5 262.5 74.5
DL 272.5 74.5 267.5 74.5 DL 277.5 74.5 272.5 74.5 DL 282.5 74.5 277.5
74.5 DL 287.5 74.5 282.5 74.5 DL 292.5 74.5 287.5 74.5 DL 297.5 74.5
292.5 74.5 DL 302.5 74.5 297.5 74.5 DL 307.5 74.5 302.5 74.5 DL 312.5
74.5 307.5 74.5 DL 317.5 74.5 312.5 74.5 DL 322.5 74.5 317.5 74.5 DL
327.5 74.5 322.5 74.5 DL 332.5 74.5 327.5 74.5 DL 337.5 74.5 332.5 74.5
DL 342.5 74.5 337.5 74.5 DL 347.5 74.5 342.5 74.5 DL 352.5 74.5 347.5
74.5 DL 357.5 74.5 352.5 74.5 DL 362.5 74.5 357.5 74.5 DL 367.5 74.5
362.5 74.5 DL 372.5 74.5 367.5 74.5 DL 377.5 74.5 372.5 74.5 DL 382.5
74.5 377.5 74.5 DL 387.5 74.5 382.5 74.5 DL 392.5 74.5 387.5 74.5 DL
397.5 74.5 392.5 74.5 DL 402.5 74.5 397.5 74.5 DL 407.5 74.5 402.5 74.5
DL 412.5 74.5 407.5 74.5 DL 417.5 74.5 412.5 74.5 DL 422.5 74.5 417.5
74.5 DL 427.5 74.5 422.5 74.5 DL 432.5 74.5 427.5 74.5 DL 437.5 74.5
432.5 74.5 DL 442.5 74.5 437.5 74.5 DL 447.5 74.5 442.5 74.5 DL 452.5
74.5 447.5 74.5 DL 457.5 74.5 452.5 74.5 DL 462.5 74.5 457.5 74.5 DL
467.5 74.5 462.5 74.5 DL 472.5 74.5 467.5 74.5 DL 477.5 74.5 472.5 74.5
DL 482.5 74.5 477.5 74.5 DL 487.5 74.5 482.5 74.5 DL 492.5 74.5 487.5
74.5 DL 497.5 74.5 492.5 74.5 DL 502.5 74.5 497.5 74.5 DL 507.5 74.5
502.5 74.5 DL 512.5 74.5 507.5 74.5 DL 517.5 74.5 512.5 74.5 DL 522.5
74.5 517.5 74.5 DL 527.5 74.5 522.5 74.5 DL 532.5 74.5 527.5 74.5 DL
537.5 74.5 532.5 74.5 DL 542.5 74.5 537.5 74.5 DL 547.5 74.5 542.5 74.5
DL 547.5 74.5 547.5 84.5 DL 547.5 75.3 547.5 85.3 DL 547.5 85.3 547.5
95.3 DL 547.5 95.3 547.5 105.3 DL 547.5 105.3 547.5 115.3 DL 547.5 115.3
547.5 125.3 DL 547.5 125.3 547.5 135.3 DL 547.5 135.3 547.5 145.3 DL
547.5 145.3 547.5 155.3 DL 547.5 155.3 547.5 165.3 DL 547.5 165.3 547.5
175.3 DL 547.5 175.3 547.5 185.3 DL 547.5 185.3 547.5 195.3 DL 547.5
195.3 547.5 205.3 DL 547.5 205.3 547.5 215.3 DL 547.5 215.3 547.5 225.3
DL 547.5 225.3 547.5 235.3 DL 547.5 235.3 547.5 245.3 DL 547.5 245.3
547.5 255.3 DL 547.5 255.3 547.5 265.3 DL 547.5 265.3 547.5 275.3 DL
547.5 275.3 547.5 285.3 DL 547.5 285.3 547.5 295.3 DL 547.5 295.3 547.5
305.3 DL 547.5 305.3 547.5 315.3 DL 547.5 315.3 547.5 325.3 DL 547.5
325.3 547.5 335.3 DL 547.5 335.3 547.5 345.3 DL 547.5 345.3 547.5 355.3
DL 547.5 355.3 547.5 365.3 DL 547.5 365.3 547.5 375.3 DL 547.5 375.3
547.5 385.3 DL 547.5 385.3 547.5 395.3 DL 547.5 395.3 547.5 405.3 DL
547.5 405.3 547.5 415.3 DL 547.5 415.3 547.5 425.3 DL 547.5 425.3 547.5
435.3 DL 547.5 435.3 547.5 445.3 DL 547.5 445.3 547.5 455.3 DL 547.5
455.3 547.5 465.3 DL 547.5 465.3 547.5 475.3 DL 547.5 475.3 547.5 485.3
DL 547.5 485.3 547.5 495.3 DL 547.5 495.3 547.5 505.3 DL 547.5 505.3
547.5 515.3 DL 547.5 515.3 547.5 525.3 DL 547.5 525.3 547.5 535.3 DL
547.5 535.3 547.5 545.3 DL 547.5 545.3 547.5 555.3 DL 547.5 555.3 547.5
565.3 DL 547.5 565.3 547.5 575.3 DL 547.5 575.3 547.5 585.3 DL 547.5
585.3 547.5 595.3 DL 69.5 595.3 64.5 595.3 DL 72.5 595.3 67.5 595.3 DL
77.5 595.3 72.5 595.3 DL 82.5 595.3 77.5 595.3 DL 87.5 595.3 82.5 595.3
DL 92.5 595.3 87.5 595.3 DL 97.5 595.3 92.5 595.3 DL 102.5 595.3 97.5
595.3 DL 107.5 595.3 102.5 595.3 DL 112.5 595.3 107.5 595.3 DL 117.5
595.3 112.5 595.3 DL 122.5 595.3 117.5 595.3 DL 127.5 595.3 122.5 595.3
DL 132.5 595.3 127.5 595.3 DL 137.5 595.3 132.5 595.3 DL 142.5 595.3
137.5 595.3 DL 147.5 595.3 142.5 595.3 DL 152.5 595.3 147.5 595.3 DL
157.5 595.3 152.5 595.3 DL 162.5 595.3 157.5 595.3 DL 167.5 595.3 162.5
595.3 DL 172.5 595.3 167.5 595.3 DL 177.5 595.3 172.5 595.3 DL 182.5
595.3 177.5 595.3 DL 187.5 595.3 182.5 595.3 DL 192.5 595.3 187.5 595.3
DL 197.5 595.3 192.5 595.3 DL 202.5 595.3 197.5 595.3 DL 207.5 595.3
202.5 595.3 DL 212.5 595.3 207.5 595.3 DL 217.5 595.3 212.5 595.3 DL
222.5 595.3 217.5 595.3 DL 227.5 595.3 222.5 595.3 DL 232.5 595.3 227.5
595.3 DL 237.5 595.3 232.5 595.3 DL 242.5 595.3 237.5 595.3 DL 247.5
595.3 242.5 595.3 DL 252.5 595.3 247.5 595.3 DL 257.5 595.3 252.5 595.3
DL 262.5 595.3 257.5 595.3 DL 267.5 595.3 262.5 595.3 DL 272.5 595.3
267.5 595.3 DL 277.5 595.3 272.5 595.3 DL 282.5 595.3 277.5 595.3 DL
287.5 595.3 282.5 595.3 DL 292.5 595.3 287.5 595.3 DL 297.5 595.3 292.5
595.3 DL 302.5 595.3 297.5 595.3 DL 307.5 595.3 302.5 595.3 DL 312.5
595.3 307.5 595.3 DL 317.5 595.3 312.5 595.3 DL 322.5 595.3 317.5 595.3
DL 327.5 595.3 322.5 595.3 DL 332.5 595.3 327.5 595.3 DL 337.5 595.3
332.5 595.3 DL 342.5 595.3 337.5 595.3 DL 347.5 595.3 342.5 595.3 DL
352.5 595.3 347.5 595.3 DL 357.5 595.3 352.5 595.3 DL 362.5 595.3 357.5
595.3 DL 367.5 595.3 362.5 595.3 DL 372.5 595.3 367.5 595.3 DL 377.5
595.3 372.5 595.3 DL 382.5 595.3 377.5 595.3 DL 387.5 595.3 382.5 595.3
DL 392.5 595.3 387.5 595.3 DL 397.5 595.3 392.5 595.3 DL 402.5 595.3
397.5 595.3 DL 407.5 595.3 402.5 595.3 DL 412.5 595.3 407.5 595.3 DL
417.5 595.3 412.5 595.3 DL 422.5 595.3 417.5 595.3 DL 427.5 595.3 422.5
595.3 DL 432.5 595.3 427.5 595.3 DL 437.5 595.3 432.5 595.3 DL 442.5
595.3 437.5 595.3 DL 447.5 595.3 442.5 595.3 DL 452.5 595.3 447.5 595.3
DL 457.5 595.3 452.5 595.3 DL 462.5 595.3 457.5 595.3 DL 467.5 595.3
462.5 595.3 DL 472.5 595.3 467.5 595.3 DL 477.5 595.3 472.5 595.3 DL
482.5 595.3 477.5 595.3 DL 487.5 595.3 482.5 595.3 DL 492.5 595.3 487.5
595.3 DL 497.5 595.3 492.5 595.3 DL 502.5 595.3 497.5 595.3 DL 507.5
595.3 502.5 595.3 DL 512.5 595.3 507.5 595.3 DL 517.5 595.3 512.5 595.3
DL 522.5 595.3 517.5 595.3 DL 527.5 595.3 522.5 595.3 DL 532.5 595.3
527.5 595.3 DL 537.5 595.3 532.5 595.3 DL 542.5 595.3 537.5 595.3 DL
547.5 595.3 542.5 595.3 DL F1(DESCRIPTION)72 621.6 Q F2(Stk)108 633.6 Q
F0 .019(is a Scheme R4RS interpreter which pro)2.519 F .02
(\255name)4.359 E F0 1.859(to a script)4.359 F(instead of ha)183 597.6 Q
(ving)-.2 E F2(wish)2.5 E F0(interpret them.)2.5 E .4 LW 64.5 602.1 64.5
612.1 DL 64.5 592.1 64.5 602.1 DL 64.5 582.1 64.5 592.1 DL 64.5 572.1
64.5 582.1 DL 64.5 562.1 64.5 572.1 DL 64.5 552.1 64.5 562.1 DL 64.5
542.1 64.5 552.1 DL 64.5 532.1 64.5 542.1 DL 64.5 522.1 64.5 532.1 DL
64.5 512.1 64.5 522.1 DL 64.5 502.1 64.5 512.1 DL 64.5 492.1 64.5 502.1
DL 64.5 482.1 64.5 492.1 DL 64.5 472.1 64.5 482.1 DL 64.5 462.1 64.5
472.1 DL 64.5 452.1 64.5 462.1 DL 64.5 442.1 64.5 452.1 DL 64.5 432.1
64.5 442.1 DL 64.5 422.1 64.5 432.1 DL 64.5 412.1 64.5 422.1 DL 64.5
402.1 64.5 412.1 DL 64.5 392.1 64.5 402.1 DL 64.5 382.1 64.5 392.1 DL
64.5 372.1 64.5 382.1 DL 64.5 362.1 64.5 372.1 DL 64.5 352.1 64.5 362.1
DL 64.5 342.1 64.5 352.1 DL 64.5 332.1 64.5 342.1 DL 64.5 322.1 64.5
332.1 DL 64.5 312.1 64.5 322.1 DL 64.5 302.1 64.5 312.1 DL 64.5 292.1
64.5 302.1 DL 64.5 282.1 64.5 292.1 DL 64.5 272.1 64.5 282.1 DL 64.5
262.1 64.5 272.1 DL 64.5 252.1 64.5 262.1 DL 64.5 242.1 64.5 252.1 DL
64.5 232.1 64.5 242.1 DL 64.5 222.1 64.5 232.1 DL 64.5 212.1 64.5 222.1
DL 64.5 202.1 64.5 212.1 DL 64.5 192.1 64.5 202.1 DL 64.5 182.1 64.5
192.1 DL 64.5 172.1 64.5 182.1 DL 64.5 162.1 64.5 172.1 DL 64.5 152.1
64.5 162.1 DL 64.5 142.1 64.5 152.1 DL 64.5 132.1 64.5 142.1 DL 64.5
122.1 64.5 132.1 DL 64.5 112.1 64.5 122.1 DL 64.5 102.1 64.5 112.1 DL
64.5 92.1 64.5 102.1 DL 64.5 82.1 64.5 92.1 DL 64.5 74.5 64.5 84.5 DL
69.5 74.5 64.5 74.5 DL 72.5 74.5 67.5 74.5 DL 77.5 74.5 72.5 74.5 DL
82.5 74.5 77.5 74.5 DL 87.5 74.5 82.5 74.5 DL 92.5 74.5 87.5 74.5 DL
97.5 74.5 92.5 74.5 DL 102.5 74.5 97.5 74.5 DL 107.5 74.5 102.5 74.5 DL
112.5 74.5 107.5 74.5 DL 117.5 74.5 112.5 74.5 DL 122.5 74.5 117.5 74.5
DL 127.5 74.5 122.5 74.5 DL 132.5 74.5 127.5 74.5 DL 137.5 74.5 132.5
74.5 DL 142.5 74.5 137.5 74.5 DL 147.5 74.5 142.5 74.5 DL 152.5 74.5
147.5 74.5 DL 157.5 74.5 152.5 74.5 DL 162.5 74.5 157.5 74.5 DL 167.5
74.5 162.5 74.5 DL 172.5 74.5 167.5 74.5 DL 177.5 74.5 172.5 74.5 DL
182.5 74.5 177.5 74.5 DL 187.5 74.5 182.5 74.5 DL 192.5 74.5 187.5 74.5
DL 197.5 74.5 192.5 74.5 DL 202.5 74.5 197.5 74.5 DL 207.5 74.5 202.5
74.5 DL 212.5 74.5 207.5 74.5 DL 217.5 74.5 212.5 74.5 DL 222.5 74.5
217.5 74.5 DL 227.5 74.5 222.5 74.5 DL 232.5 74.5 227.5 74.5 DL 237.5
74.5 232.5 74.5 DL 242.5 74.5 237.5 74.5 DL 247.5 74.5 242.5 74.5 DL
252.5 74.5 247.5 74.5 DL 257.5 74.5 252.5 74.5 DL 262.5 74.5 257.5 74.5
DL 267.5 74.5 262.5 74.5 DL 272.5 74.5 267.5 74.5 DL 277.5 74.5 272.5
74.5 DL 282.5 74.5 277.5 74.5 DL 287.5 74.5 282.5 74.5 DL 292.5 74.5
287.5 74.5 DL 297.5 74.5 292.5 74.5 DL 302.5 74.5 297.5 74.5 DL 307.5
74.5 302.5 74.5 DL 312.5 74.5 307.5 74.5 DL 317.5 74.5 312.5 74.5 DL
322.5 74.5 317.5 74.5 DL 327.5 74.5 322.5 74.5 DL 332.5 74.5 327.5 74.5
DL 337.5 74.5 332.5 74.5 DL 342.5 74.5 337.5 74.5 DL 347.5 74.5 342.5
74.5 DL 352.5 74.5 347.5 74.5 DL 357.5 74.5 352.5 74.5 DL 362.5 74.5
357.5 74.5 DL 367.5 74.5 362.5 74.5 DL 372.5 74.5 367.5 74.5 DL 377.5
74.5 372.5 74.5 DL 382.5 74.5 377.5 74.5 DL 387.5 74.5 382.5 74.5 DL
392.5 74.5 387.5 74.5 DL 397.5 74.5 392.5 74.5 DL 402.5 74.5 397.5 74.5
DL 407.5 74.5 402.5 74.5 DL 412.5 74.5 407.5 74.5 DL 417.5 74.5 412.5
74.5 DL 422.5 74.5 417.5 74.5 DL 427.5 74.5 422.5 74.5 DL 432.5 74.5
427.5 74.5 DL 437.5 74.5 432.5 74.5 DL 442.5 74.5 437.5 74.5 DL 447.5
74.5 442.5 74.5 DL 452.5 74.5 447.5 74.5 DL 457.5 74.5 452.5 74.5 DL
462.5 74.5 457.5 74.5 DL 467.5 74.5 462.5 74.5 DL 472.5 74.5 467.5 74.5
DL 477.5 74.5 472.5 74.5 DL 482.5 74.5 477.5 74.5 DL 487.5 74.5 482.5
74.5 DL 492.5 74.5 487.5 74.5 DL 497.5 74.5 492.5 74.5 DL 502.5 74.5
497.5 74.5 DL 507.5 74.5 502.5 74.5 DL 512.5 74.5 507.5 74.5 DL 517.5
74.5 512.5 74.5 DL 522.5 74.5 517.5 74.5 DL 527.5 74.5 522.5 74.5 DL
532.5 74.5 527.5 74.5 DL 537.5 74.5 532.5 74.5 DL 542.5 74.5 537.5 74.5
DL 547.5 74.5 542.5 74.5 DL 547.5 74.5 547.5 84.5 DL 547.5 82.1 547.5
92.1 DL 547.5 92.1 547.5 102.1 DL 547.5 102.1 547.5 112.1 DL 547.5 112.1
547.5 122.1 DL 547.5 122.1 547.5 132.1 DL 547.5 132.1 547.5 142.1 DL
547.5 142.1 547.5 152.1 DL 547.5 152.1 547.5 162.1 DL 547.5 162.1 547.5
172.1 DL 547.5 172.1 547.5 182.1 DL 547.5 182.1 547.5 192.1 DL 547.5
192.1 547.5 202.1 DL 547.5 202.1 547.5 212.1 DL 547.5 212.1 547.5 222.1
DL 547.5 222.1 547.5 232.1 DL 547.5 232.1 547.5 242.1 DL 547.5 242.1
547.5 252.1 DL 547.5 252.1 547.5 262.1 DL 547.5 262.1 547.5 272.1 DL
547.5 272.1 547.5 282.1 DL 547.5 282.1 547.5 292.1 DL 547.5 292.1 547.5
302.1 DL 547.5 302.1 547.5 312.1 DL 547.5 312.1 547.5 322.1 DL 547.5
322.1 547.5 332.1 DL 547.5 332.1 547.5 342.1 DL 547.5 342.1 547.5 352.1
DL 547.5 352.1 547.5 362.1 DL 547.5 362.1 547.5 372.1 DL 547.5 372.1
547.5 382.1 DL 547.5 382.1 547.5 392.1 DL 547.5 392.1 547.5 402.1 DL
547.5 402.1 547.5 412.1 DL 547.5 412.1 547.5 422.1 DL 547.5 422.1 547.5
432.1 DL 547.5 432.1 547.5 442.1 DL 547.5 442.1 547.5 452.1 DL 547.5
452.1 547.5 462.1 DL 547.5 462.1 547.5 472.1 DL 547.5 472.1 547.5 482.1
DL 547.5 482.1 547.5 492.1 DL 547.5 492.1 547.5 502.1 DL 547.5 502.1
547.5 512.1 DL 547.5 512.1 547.5 522.1 DL 547.5 522.1 547.5 532.1 DL
547.5 532.1 547.5 542.1 DL 547.5 542.1 547.5 552.1 DL 547.5 552.1 547.5
562.1 DL 547.5 562.1 547.5 572.1 DL 547.5 572.1 547.5 582.1 DL 547.5
582.1 547.5 592.1 DL 547.5 592.1 547.5 602.1 DL 547.5 602.1 547.5 612.1
DL 69.5 612.1 64.5 612.1 DL 72.5 612.1 67.5 612.1 DL 77.5 612.1 72.5
612.1 DL 82.5 612.1 77.5 612.1 DL 87.5 612.1 82.5 612.1 DL 92.5 612.1
87.5 612.1 DL 97.5 612.1 92.5 612.1 DL 102.5 612.1 97.5 612.1 DL 107.5
612.1 102.5 612.1 DL 112.5 612.1 107.5 612.1 DL 117.5 612.1 112.5 612.1
DL 122.5 612.1 117.5 612.1 DL 127.5 612.1 122.5 612.1 DL 132.5 612.1
127.5 612.1 DL 137.5 612.1 132.5 612.1 DL 142.5 612.1 137.5 612.1 DL
147.5 612.1 142.5 612.1 DL 152.5 612.1 147.5 612.1 DL 157.5 612.1 152.5
612.1 DL 162.5 612.1 157.5 612.1 DL 167.5 612.1 162.5 612.1 DL 172.5
612.1 167.5 612.1 DL 177.5 612.1 172.5 612.1 DL 182.5 612.1 177.5 612.1
DL 187.5 612.1 182.5 612.1 DL 192.5 612.1 187.5 612.1 DL 197.5 612.1
192.5 612.1 DL 202.5 612.1 197.5 612.1 DL 207.5 612.1 202.5 612.1 DL
212.5 612.1 207.5 612.1 DL 217.5 612.1 212.5 612.1 DL 222.5 612.1 217.5
612.1 DL 227.5 612.1 222.5 612.1 DL 232.5 612.1 227.5 612.1 DL 237.5
612.1 232.5 612.1 DL 242.5 612.1 237.5 612.1 DL 247.5 612.1 242.5 612.1
DL 252.5 612.1 247.5 612.1 DL 257.5 612.1 252.5 612.1 DL 262.5 612.1
257.5 612.1 DL 267.5 612.1 262.5 612.1 DL 272.5 612.1 267.5 612.1 DL
277.5 612.1 272.5 612.1 DL 282.5 612.1 277.5 612.1 DL 287.5 612.1 282.5
612.1 DL 292.5 612.1 287.5 612.1 DL 297.5 612.1 292.5 612.1 DL 302.5
612.1 297.5 612.1 DL 307.5 612.1 302.5 612.1 DL 312.5 612.1 307.5 612.1
DL 317.5 612.1 312.5 612.1 DL 322.5 612.1 317.5 612.1 DL 327.5 612.1
322.5 612.1 DL 332.5 612.1 327.5 612.1 DL 337.5 612.1 332.5 612.1 DL
342.5 612.1 337.5 612.1 DL 347.5 612.1 342.5 612.1 DL 352.5 612.1 347.5
612.1 DL 357.5 612.1 352.5 612.1 DL 362.5 612.1 357.5 612.1 DL 367.5
612.1 362.5 612.1 DL 372.5 612.1 367.5 612.1 DL 377.5 612.1 372.5 612.1
DL 382.5 612.1 377.5 612.1 DL 387.5 612.1 382.5 612.1 DL 392.5 612.1
387.5 612.1 DL 397.5 612.1 392.5 612.1 DL 402.5 612.1 397.5 612.1 DL
407.5 612.1 402.5 612.1 DL 412.5 612.1 407.5 612.1 DL 417.5 612.1 412.5
612.1 DL 422.5 612.1 417.5 612.1 DL 427.5 612.1 422.5 612.1 DL 432.5
612.1 427.5 612.1 DL 437.5 612.1 432.5 612.1 DL 442.5 612.1 437.5 612.1
DL 447.5 612.1 442.5 612.1 DL 452.5 612.1 447.5 612.1 DL 457.5 612.1
452.5 612.1 DL 462.5 612.1 457.5 612.1 DL 467.5 612.1 462.5 612.1 DL
472.5 612.1 467.5 612.1 DL 477.5 612.1 472.5 612.1 DL 482.5 612.1 477.5
612.1 DL 487.5 612.1 482.5 612.1 DL 492.5 612.1 487.5 612.1 DL 497.5
612.1 492.5 612.1 DL 502.5 612.1 497.5 612.1 DL 507.5 612.1 502.5 612.1
DL 512.5 612.1 507.5 612.1 DL 517.5 612.1 512.5 612.1 DL 522.5 612.1
517.5 612.1 DL 527.5 612.1 522.5 612.1 DL 532.5 612.1 527.5 612.1 DL
537.5 612.1 532.5 612.1 DL 542.5 612.1 537.5 612.1 DL 547.5 612.1 542.5
612.1 DL F1(DESCRIPTION)72 638.4 Q F2(Stk)108 650.4 Q F0 .019
(is a Scheme R4RS interpreter which pro)2.519 F .02
(vide a simple access to the X11 Tk toolkit. If the)-.15 F F2(\255no-tk)
2.52 E F0(option)2.52 E 1.378(is pro)108 645.6 R 1.378
2.52 E F0(option)2.52 E 1.378(is pro)108 662.4 R 1.378
(vided to the interpreter)-.15 F 3.878(,t)-.4 G 1.378
(he Tk library is not initialized and no main windo)-3.878 F 3.878(wi)
-.25 G 3.878(sc)-3.878 G 3.878(reated. If)-3.878 F F2(stk)3.877 E F0(is)
3.877 E(in)108 657.6 Q -.2(vo)-.4 G -.1(ke).2 G 3.009(dw).1 G .509
3.877 E(in)108 674.4 Q -.2(vo)-.4 G -.1(ke).2 G 3.009(dw).1 G .509
(ith no)-3.009 F F2<ad66>3.009 E F0 .509(option then it reads Scheme e)
3.009 F .509(xpressions interacti)-.15 F -.15(ve)-.25 G .51
(ly from standard input.).15 F .51(It will con-)5.51 F .493
(tinue processing commands until all windo)108 669.6 R .493(ws ha)-.25 F
(tinue processing commands until all windo)108 686.4 R .493(ws ha)-.25 F
.793 -.15(ve b)-.2 H .492
(een deleted or until end-of-\214le is reached on standard).15 F(input.)
108 681.6 Q 208.58(STk 4.0)72 768 R(1)222.75 E EP
108 698.4 Q 208.58(STk 4.0)72 768 R(1)222.75 E EP
%%Page: 2 2
%%BeginPageSetup
BP

View File

@ -1,7 +1,7 @@
STk(1) STk(1)
STk(1) January_1998 STk(1)
_________________________________________________________________
@ -20,6 +20,10 @@ OOPPTTIIOONNSS
tions for the --hheellpp option).
--ccoolloorrmmaapp nneeww Specifies that the window should have a new
private colormap instead of using the
default colormap for the screen.
--ddiissppllaayy _d_i_s_p_l_a_y
Display (and screen) on which to display
window.
@ -38,10 +42,6 @@ OOPPTTIIOONNSS
the window, and as the name of the inter­
preter for sseenndd commands.
--nneeww--ccoolloorrmmaapp Specifies that the main window should have
a new private colormap instead of using the
default colormap for the screen.
--ssyynncc Execute all X server commands syn­
chronously, so that errors are reported
immediately. This will result in much
@ -61,13 +61,13 @@ OOPPTTIIOONNSS
July_1996 3.1 1
STk 4.0 1
STk(1) STk(1)
STk(1) January_1998 STk(1)
input.
@ -86,58 +86,67 @@ STk(1) STk(1)
--iinntteerraaccttiivvee Tell the interpreter that it is used inter­
actively (even if it doesn't think so).
--hheellpp Print the version of the system and abort
execution.
--hheellpp Print a summary of the command-line options
and exit.
---- Pass all remaining arguments through to the
script's aarrggvv variable without interpreting
them. This provides a mechanism for pass­
ing arguments such as --nnaammee to a script
them. This provides a mechanism for pass­
ing arguments such as --nnaammee to a script
instead of having wwiisshh interpret them.
_________________________________________________________________
DDEESSCCRRIIPPTTIIOONN
SSttkk is a Scheme R4RS interpreter which provide a simple
SSttkk is a Scheme R4RS interpreter which provide a simple
access to the X11 Tk toolkit. If the --nnoo--ttkk option is pro­
vided to the interpreter, the Tk library is not initial­
ized and no main window is created. If ssttkk is invoked
with no --ff option then it reads Scheme expressions inter­
vided to the interpreter, the Tk library is not initial­
ized and no main window is created. If ssttkk is invoked
with no --ff option then it reads Scheme expressions inter­
actively from standard input. It will continue processing
commands until all windows have been deleted or until end-
of-file is reached on standard input.
SSnnooww is a _l_i_g_h_t version of the ssttkk interpreter which does
not provide support for the Tk toolkit. This interpreter
does not recognize the options --ddiissppllaayy, --ggeeoommeettrryy, --ssyynncc
nneeww--ccoolloorrmmaapp, vviissuuaall and --nnoo--ttkk which are meaningless
without Tk. This interpreter is called, rather than the
standard one, when the shell DISPLAY variable is not ini­
tialized.
SSnnooww is a _l_i_g_h_t version of the ssttkk interpreter which does
not provide support for the Tk toolkit. This interpreter
does not recognize the options --ddiissppllaayy, --ggeeoommeettrryy, --ssyynncc
--ccoolloorrmmaapp, --vviissuuaall and --nnoo--ttkk which are meaningless with­
out Tk. This interpreter is called, rather than the stan­
dard one, when the shell DISPLAY variable is not initial­
ized.
If the --ffiillee option is provided to Tk, then ssttkk reads
Scheme forms from the file named in the --ffiillee option.
These forms will normally create an interactive interface
consisting of one or more widgets. When the end of the
STk 4.0 2
STk(1) January_1998 STk(1)
If the --ffiillee option is provided to Tk, then ssttkk reads
Scheme forms from the file named in the --ffiillee option.
These forms will normally create an interactive interface
consisting of one or more widgets. When the end of the
command file is reached, ssttkk will continue to respond to X
events until all windows have been deleted.
July_1996 3.1 2
STk(1) STk(1)
NNoottee:: The --ffiillee exits for compatibility reasons and can be
eventually ommited. In there is no --ffiillee option used, the
first argument in the command line is taken as the name of
the script file to execute. To launch an interactive
script with an argument, you have to use the ---- option.
The --iinntteerraaccttiivvee option forces the interpreter in interac­
tive mode. In this mode, standard output and standard
tive mode. In this mode, standard output and standard
error are unbuffered. Use this option when you launch ssttkk
from eemmaaccss.
@ -147,17 +156,18 @@ VVAARRIIAABBLLEESS
Following Scheme variables are set when SSttkk starts:
**aarrggcc** Contains a count of the number of _a_r_g argu­
ments (0 if none), not including the
ments (0 if none), not including the
options described above.
**aarrggvv** Contains a Scheme list whose elements are
the _a_r_g arguments (not including the
options described above), in order, or an
**aarrggvv** Contains a Scheme list whose elements are
the _a_r_g arguments (not including the
options described above), in order, or an
empty list if there are no _a_r_g arguments.
**pprrooggrraamm--nnaammee** Contains _f_i_l_e_N_a_m_e if it was specified.
Otherwise, contains the name by which ssttkk
was invoked.
**pprrooggrraamm--nnaammee** Contains _f_i_l_e_N_a_m_e if it was provided (in a
--ffiillee option or as first argument of the
command line). Otherwise, contains the
name by which the interpreter was invoked.
@ -170,7 +180,9 @@ SSCCRRIIPPTT FFIILLEESS
shell if you mark it as executable. This assumes that ssttkk
has been installed in the default location in
/usr/local/bin; if it's installed somewhere else then
you'll have to modify the above line to match.
you'll have to modify the above line to match. Note that
--ff which was necessary with pre-4.0 versions of SSTTkk is no
more necessary and can be omitted.
EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS
@ -178,6 +190,18 @@ EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS
_S_T_K___L_I_B_R_A_R_Y This variable indicates where the library
files are located. This variable allows to
STk 4.0 3
STk(1) January_1998 STk(1)
overload the default value of the Scheme
variable _*_s_t_k_-_l_i_b_r_a_r_y_* which is automati­
cally calculated by the interpreter.(i.e.
@ -189,22 +213,16 @@ EENNVVIIRROONNMMEENNTT VVAARRIIAABBLLEESS
command.
_S_T_K___H_E_L_P___P_A_T_H This variable serves to initialize the
_*_h_e_l_p_-_p_a_t_h_* Scheme variable. It must
_*_h_e_l_p_-_p_a_t_h_* Scheme variable. It must con­
tain a list of documentation directories.
This variable is used by the help proce­
dure.
July_1996 3.1 3
STk(1) STk(1)
contain a list of documentation directo­
ries. This variable is used by the help
procedure.
_S_T_K___I_M_A_G_E___P_A_T_H This variable serves to initialize the
_*_i_m_a_g_e_-_p_a_t_h_* Scheme variable. It must con­
tain a list of images directories. This
variable is used by the make-image proce­
dure.
@ -223,9 +241,9 @@ FFIILLEESS
_~_/_._s_t_k_r_c Standard _i_n_i_t_._s_t_k file tries to load the
file _~_/_._s_t_k_r_c. This file can be used to
store function definitions or variables
store functions definitions or variables
settings that you want to be executed at
each interpretater invocation.
each interpreter invocation.
SSEEEE AALLSSOO
@ -241,24 +259,6 @@ SSEEEE AALLSSOO
July_1996 3.1 4
STk 4.0 4

View File

@ -874,20 +874,20 @@ If the specified range contains embedded windows, no information
about them is included in the returned string.
.TP
(\fwidget\-name \fB'image \fIoption \fR?\fIarg arg ...\fR?)
(\fIwidget\-name \fB'image \fIoption \fR?\fIarg arg ...\fR?)
This command is used to manipulate embedded images.
The behavior of the command depends on the \fIoption\fR argument
that follows the \fBtag\fR argument.
The following forms of the command are currently supported:
.RS
.TP
(\fwidget\-name \fB'image 'cget\fR \fIindex option\fR)
(\fIwidget\-name \fB'image 'cget\fR \fIindex option\fR)
Returns the value of a configuration option for an embedded image.
\fIIndex\fR identifies the embedded image, and \fIoption\fR
specifies a particular configuration option, which must be one of
the ones listed in the section EMBEDDED IMAGES.
.TP
(\fwidget\-name \fB'image 'configure \fIindex\fR ?\fIoption value ...\fR?)
(\fIwidget\-name \fB'image 'configure \fIindex\fR ?\fIoption value ...\fR?)
Query or modify the configuration options for an embedded image.
If no \fIoption\fR is specified, returns a list describing all of
the available options for the embedded image at \fIindex\fR
@ -902,7 +902,7 @@ this case the command returns an empty string.
See EMBEDDED IMAGES for information on the options that
are supported.
.TP
(\fwidget\-name \fB'image 'create \fIindex\fR ?\fIoption value ...\fR?)
(\fIWidget\-name \fB'image 'create \fIindex\fR ?\fIoption value ...\fR?)
This command creates a new image annotation, which will appear
in the text at the position given by \fIindex\fR.
Any number of \fIoption\-value\fR pairs may be specified to
@ -912,7 +912,7 @@ this image.
See EMBEDDED IMAGES for information on the options that
are supported, and a description of the identifier returned.
.TP
(\fwidget\-name \fB'image 'names\fR)
(\fIWidget\-name \fB'image 'names\fR)
Returns a list whose elements are the names of all image instances currently
embedded in \fIwindow\fR.
.RE

View File

@ -3,7 +3,7 @@
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: 22-May-1994 22:13
% Last file update: 22-Apr-1998 11:04
% Last file update: 5-Jun-1999 14:48
%
\section{Introduction}
@ -608,11 +608,11 @@ addition.
To terminate our implementation (integration?) of complex numbers, we can
redefine standard Scheme predicates in the following manner:
\begin{scheme}
(define-method complex? (c <complex>) \schtrue)
(define-method complex? (c) \schfalse)
(define-method complex? ((c <complex>)) \schtrue)
(define-method complex? (c) \schfalse)
(define-method number? (n <number>) \schtrue)
(define-method number? (n) \schfalse)
(define-method number? ((n <number>)) \schtrue)
(define-method number? (n) \schfalse)
...
...
\end{scheme}

View File

@ -3,7 +3,7 @@
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: 21-Dec-1997 20:09
% Last file update: 2-Feb-1999 15:25
% Last file update: 1-Sep-1999 23:17 (eg)
%
\section*{Introduction}
@ -16,6 +16,14 @@ the various recent versions of STk. Differences with older versions
as well as implementation changes are described in the CHANGES file
located in the main directory of the STk distribution.
\section*{Release 4.0.0}
\small{\emph{Release date: 09/03/99}}
Mains changes/modifications since 3.99.4:
\begin{itemize}
\item define-syntax
\item Integration of SRFI-{0,2,6,8}
\end{itemize}
\section*{Release 3.99.4}
\small{\emph{Release date: 02/02/99}}
Mains changes/modifications since 3.99.3:

View File

@ -3,7 +3,7 @@
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:??
% Last file update: 30-May-1998 23:04
% Last file update: 31-Aug-1999 13:04 (eg)
%
\section*{Introduction}
@ -518,6 +518,24 @@ Returns \schtrue{} if \var{obj} is a symbol, otherwise returns {\schfalse}.
\doc
\end{entry}
\begin{entry}{%
\proto{string->uninterned-symbol}{ string}{procedure}}
\saut
Returns a symbol whose print name is made from the characters of
\ide{string}. This symbol is guaranteed to be \emph{unique} (i.e. not
\ide{eq?} to any other symbol):
\begin{scheme}
(let ((ua (string->uninterned-symbol "a")))
(list (eq? 'a ua)
(eqv? 'a ua)
(eq? ua (string->uninterned-symbol "a"))
(eqv? ua (string->uninterned-symbol "a"))))
\lev (\schfalse{} \schtrue{} \schfalse{} \schtrue{})
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{gensym}{}{procedure}
\proto{gensym}{ prefix}{procedure}}
@ -1021,13 +1039,24 @@ returns the body of \hyper{procedure}. If \hyper{procedure} is not a closure,
\label{inputoutput}
The {\rrrr} states that ports represent input and output devices.
However, it defines only ports which are attached to files. In
{\stk}, ports can also be attached to strings or to a external command
input or output. String ports are similar to file ports, except that
characters are read from (or written to) a string rather than a file.
External command input or output ports are implemented with Unix pipes
and are called pipe ports. A pipe port is created by specifying the
command to execute prefixed with the string {\tt "|~"}. Specification
of a pipe port can occur everywhere a file name is needed.
{\stk}, ports can also be attached to strings, to a external command
input or output, or even be completely virtual (i.e. the behavior of
the port is given by the user).
\begin{itemize}
\item String ports are similar to file ports, except that characters
are read from (or written to) a string rather than a file.
\item External command input or output ports are implemented with
Unix pipes and are called pipe ports. A pipe port is created by
specifying the command to execute prefixed with the string {\tt
"|~"}. Specification of a pipe port can occur everywhere a file
name is needed.
\item Virtual ports creation needs that the basic I/O functions are
at the port creation time. This functions will be used to simulate
low level accesses a ``virtual device''. This kind of port is
particularly convenient for reading or writing in a graphical window
as if it was a file. Once virtual port is created, it can be accessed
as a normal port with the standard Scheme primitives.
\end{itemize}
\begin{entry}{%
@ -1072,6 +1101,14 @@ containing all the text that has been written on the string port.
\doc
\end{entry}
\begin{entry}{%
\proto{input-file-port?}{ obj}{procedure}
\proto{output-file-port?}{ obj}{procedure}}
\saut
Returns \schtrue{} if \var{obj} is either an input or an output file port,
otherwise returns {\schfalse}.
\end{entry}
\begin{entry}{%
\proto{input-string-port?}{ obj}{procedure}
\proto{output-string-port?}{ obj}{procedure}}
@ -1080,6 +1117,16 @@ Returns \schtrue{} if \var{obj} is either an input or an output string port,
otherwise returns {\schfalse}.
\end{entry}
\begin{entry}{%
\proto{input-virtual-port?}{ obj}{procedure}
\proto{output-virtual-port?}{ obj}{procedure}}
\saut
Returns \schtrue{} if \var{obj} is either an input or an output virtual port,
otherwise returns {\schfalse}.
\end{entry}
\begin{entry}{%
\proto{current-input-port}{}{procedure}
\proto{current-output-port}{}{procedure}}
@ -1095,14 +1142,18 @@ Returns the current default error port.
\begin{entry}{%
\proto{with-input-from-file}{ string thunk}{procedure}
\proto{with-output-to-file}{ string thunk}{procedure}}
\proto{with-output-to-file}{ string thunk}{procedure}
\proto{with-error-to-file}{ string thunk}{procedure}}
\saut
\doc
The following example uses a pipe port opened for reading. It permits
to read all the lines produced by an external {\tt ls} command
(i.e. the ouput of the {\tt ls} command is {\em redirected} to the
Scheme pipe port).
\ide{With-input-from-file} and \ide{with-output-to-file} are identical
to \rrrr{}. \ide{With-error-to-file} is similar to \ide{with-output-to-file}
except that this is the error port which is redirected to the file.
The following example uses a pipe port opened for
reading. It permits to read all the lines produced by an external {\tt
ls} command (i.e. the ouput of the {\tt ls} command is {\em
redirected} to the Scheme pipe port).
\begin{scheme}
(with-input-from-file "\verb+|+ ls -ls"
@ -1122,6 +1173,29 @@ it is the standard input of the Unix command which is redirected.
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{with-input-from-port}{ port thunk}{procedure}
\proto{with-output-to-port}{ port thunk}{procedure}
\proto{with-error-to-port}{ port thunk}{procedure}}
\saut
These procedure are similar to the above function except that the
thunk is called with the input, output or error port redirected to
the given port (port can be any kind of port)
\begin{scheme}
(let ((p (open-input-string "123 456")))
(with-input-from-port p
(lambda ()
(read p))))
\lev 123
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{with-input-from-string}{ string thunk}{procedure}}
\saut
@ -1148,6 +1222,20 @@ returns the string containing all the text written on the string port.
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{with-error-to-string}{ thunk}{procedure}}
\saut
A string port is opened for output. \ide{Current-error-port}
is set to it and \var{thunk} is called. When the \var{thunk} returns,
the previous default error port is restored. \ide{With-error-to-string}
returns the string containing all the text written on the string port.
\begin{scheme}
(with-error-to-string (lambda () (write 123 (current-error-port))))
\lev "123"
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{open-input-file}{ filename}{procedure}
\proto{open-output-file}{ filename}{procedure}}
@ -1187,9 +1275,87 @@ output string \var{port}.
\end{entry}
\begin{entry}{%
\proto{open-input-virtual}{ getc readyp eofp close}{procedure}}
\saut
Returns a virtual port using the \var{getc} procedure to read a
character from the port, \var{readyp} to know if there is to read from
the port, \var{eofp} to know if the end of file is reached on the port
and finally \var{close} to close the port. All theses procedure takes
one parameter which is the port from which the input is done.
\var{Open-input-virtual} accepts also the special value \schfalse{} for
the I/O procedures with the following conventions:
\begin{itemize}
\item if \var{getc} or \var{eofp} is \schfalse{} any attempt to read
the virtual port will an eof object;
\item if \var{readyp} is \schfalse{}, the file will always be ready
for reading;
\item if \var{clos} is \schfalse{}, no action is done when the port is
closed.
\end{itemize}
Hereafter is a possible implementation of \ide{open-input-string}
using virtual ports:
\begin{scheme}
(define (open-input-string str)
(let ((index 0))
(open-input-virtual
(lambda (p) ;; getc
;; test on eof is already done by the system
(let ((res (string-ref str index)))
(set! index (+ index 1))
res))
\schfalse ;; readyp
(lambda (p) (= index (string-length str))) ;; eofp
(lambda (p) (set! index 0))))) ;; close
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{open-output-virtual}{ wrtc wrts flush close}{procedure}}
\saut
Returns a virtual port using the \var{wrtc} procedure to write a
character to the port, \var{wrts} to write a string to the port,
\var{flush} to flush the character on the port and finally \var{close}
to close the port. \var{Wrtc} takes two parameters: a character and
the port to which the output must be done. \var{Wrts} takes two
parameters: a string and a port. \var{Flush} and \var{close} takes one
parameter which is the port on which the action must be done.
\var{Open-input-virtual} accepts also the special value \schfalse{}
for the I/O procedures. If a procedure is \schfalse{} nothing is done
on the corresponding action.
Hereafter is an (very inefficient) implementation of a variant of
\ide{open-output-string} using virtual ports. The value of the output
string is printed when the port is closed:
\begin{scheme}
(define (open-output-string)
(let ((str ""))
(open-output-virtual
(lambda (c p) ;; wrtc
(set! str (string-append str (char->sting c))))
(lambda (s p) ;; wrts
(set! str (string-append str s)))
\schfalse{} ;; flush
(lambda (p) (write str) (newline))))) ;; close
;; Example
(let ((p (open-output-string)))
(display "Hello, world" p)
(close-port p)) \lev prints "Hello, world" on current output port
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{close-input-port}{ port}{procedure}
a\proto{close-output-port}{ port}{procedure}}
\proto{close-output-port}{ port}{procedure}}
\saut
\doc
\end{entry}
@ -1306,17 +1472,6 @@ printed on the specified port.
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{get-output-string}{ port}{procedure}}
\saut
Returns the string associated with the output string \var{port}.
\begin{scheme}
(let ((p (open-output-string)))
(display "Hello, world" p)
(get-output-string p)) \lev "Hello, world"
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{flush}{}{procedure}
\proto{flush}{ port}{procedure}}
@ -1431,13 +1586,6 @@ subsequent loads of this file. \ide{Provided?} returns {\schtrue} if
\var{string} was already provided; it returns {\schfalse} otherwise.
\end{entry}
\begin{entry}{%
\proto{transcript-on}{ filename}{procedure}\nopagebreak{}
\proto{transcript-off}{}{procedure}}
\saut
Not implemented.
\end{entry}
\begin{entry}{%
\proto{open-file}{ filename mode}{procedure}}
\saut
@ -1457,12 +1605,40 @@ reading or writing on this port is disallowed.
\end{entry}
\begin{entry}{%
\proto{transcript-on}{ filename}{procedure}\nopagebreak{}
\proto{transcript-off}{}{procedure}}
\proto{copy-port}{ src dst}{procedure}}
\saut
Not implemented.
Copies the content of the input port \var{src} to the output-port \var{dest}.
\begin{scheme}
(define copy-file
(lambda (src dst)
(with-input-from-file src (lambda ()
(with-output-to-file dst (lambda ()
(copy-port (current-input-port)
(current-output-port))))))))
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{port-closed?}{ port}{procedure}}
\saut
Returns \schtrue{} if \var{port} has been closed, \schfalse{} otherwise.
\end{entry}
\begin{entry}{%
\proto{copy-port}{ src dst}{procedure}}
\saut
Copies the content of the input port \var{src} to the output-port \var{dest}.
\begin{scheme}
(define copy-file
(lambda (src dst)
(with-input-from-file src (lambda ()
(with-output-to-file dst (lambda ()
(copy-port (current-input-port)
(current-output-port))))))))
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{port->string}{ port}{procedure}
\proto{port->list}{ reader port}{procedure}
@ -1511,6 +1687,14 @@ connected on the machine running the {\stk} interpreter.
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{transcript-on}{ filename}{procedure}\nopagebreak{}
\proto{transcript-off}{}{procedure}}
\saut
Not implemented.
\end{entry}
%%% Local Variables:
%%% mode: latex
%%% TeX-master: "manual"

View File

@ -3,7 +3,7 @@
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:??
% Last file update: 20-Apr-1998 11:58
% Last file update: 16-Aug-1999 20:21
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@ -429,6 +429,13 @@ Returns the list symbols that ere defined in \var{module}.
\end{entry}
\begin{entry}{%
\proto{all-modules}{ } {procedure}}
\saut
Returns a list of all the living modules.
\end{entry}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%
%%%% Section 6.13: Environments
@ -974,6 +981,12 @@ a vector of all the signal handlers currently in effect.
\end{entry}
\begin{entry}{%
\proto{send-signal}{ sig} {procedure}}
\saut
Sends the signal \var{sig} to the running program.
\end{entry}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%
%%%% Section 6.18: Hash tables

View File

@ -3,7 +3,7 @@
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: 16-Dec-1997 14:00
% Last file update: 8-Apr-1998 11:04
% Last file update: 17-May-1999 00:07
%
@ -371,7 +371,7 @@ equivalence). All the types defined in Table~\ref{FfiTypes}, except
Hereafter, there are some commented definitions of external functions:
\begin{scheme}
(define-external isatty ((fd :int))
(define-external isatty ((fd :int))
:return-type :boolean)
(define-external system ((cmd (:char *))) \emph{;; or ((cmd :string))}
@ -468,6 +468,11 @@ column of Table~\ref{FfiTypes}. Some examples using the \texttt{printf} function
(system l))
\end{scheme}
\end{note}
\begin{note}
The same convention also applies for parameters of type
\texttt{:string}, \texttt{:dynamic-ptr} or \texttt{:static-ptr}: they accept
the special value \schfalse{} as a synonym of the C \texttt{NULL} pointer.
\end{note}
\end{entry}
\begin{entry}{

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -1,19 +1,19 @@
%
% STk Reference manual (Main file)
%
% Copyright (C) 1993,1994,1995 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
%
% Permission to use, copy, and/or distribute this software and its
% documentation for any purpose and without fee is hereby granted, provided
% that both the above copyright notice and this permission notice appear in
% all copies and derived works. Fees for distribution or use of this
% software or derived works may only be charged with express written
% permission of the copyright holder.
% This software is provided ``as is'' without express or implied warranty.
% Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
% Permission to use, copy, modify, distribute,and license this
% software and its documentation for any purpose is hereby granted,
% provided that existing copyright notices are retained in all
% copies and that this notice is included verbatim in any
% distributions. No written agreement, license, or royalty fee is
% required for any of the authorized uses.
% This software is provided ``AS IS'' without express or implied
% warranty.
%
% Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:??
% Last file update: 30-May-1998 22:49
% Last file update: 3-Sep-1999 19:34 (eg)
%
\documentclass[11pt,a4paper]{book}
@ -44,7 +44,7 @@
%
% Some new commands
%
\newcommand{\stkversion}{3.99}
\newcommand{\stkversion}{4.0}
\newcommand{\stk}{{\sc STk}}
\newcommand{\stklos}{{\sc STklos}}
\newcommand{\doc}{{\em Identical to R$^{4}$RS.}}
@ -78,7 +78,7 @@ email: eg@unice.fr}
\end{center}
\vskip8cm
\begin{flushright}
June 1998
September 1999
\end{flushright}
\newpage
\thispagestyle{empty}

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -1,18 +1,19 @@
#
# Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
# Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
#
#
# Permission to use, copy, and/or distribute this software and its
# documentation for any purpose and without fee is hereby granted, provided
# that both the above copyright notice and this permission notice appear in
# all copies and derived works. Fees for distribution or use of this
# software or derived works may only be charged with express written
# permission of the copyright holder.
# This software is provided ``as is'' without express or implied warranty.
# Permission to use, copy, modify, distribute,and license this
# software and its documentation for any purpose is hereby granted,
# provided that existing copyright notices are retained in all
# copies and that this notice is included verbatim in any
# distributions. No written agreement, license, or royalty fee is
# required for any of the authorized uses.
# This software is provided ``AS IS'' without express or implied
# warranty.
#
# Author: Erick Gallesio [eg@kaolin.unice.fr]
# Creation date: 6-Mar-1994 15:49
# Last file update: 20-Jul-1998 19:37
# Last file update: 3-Sep-1999 19:39 (eg)
include ../config.make

View File

@ -2,22 +2,21 @@
*
* b a s e 6 4 . c -- Base64 support for STk
*
* Copyright © 1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1998-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
*
* $Id: base64.c 1.3 Wed, 18 Nov 1998 16:16:26 +0100 eg $
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* Author: Erick Gallesio [eg@unice.fr]
* Creation date: 20-Jul-1998 12:19
* Last file update: 10-Nov-1998 23:40
* Last file update: 3-Sep-1999 20:18 (eg)
*/
#include <stk.h>

View File

@ -2,25 +2,21 @@
*
* h a s h . c -- Hash Tables
*
* Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
*
* This software is a derivative work of other copyrighted softwares; the
* copyright notices of these softwares are placed in the file COPYRIGHTS
*
* $Id: hash.c 1.4 Mon, 28 Dec 1998 23:05:11 +0100 eg $
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 17-Jan-1994 17:49
* Last file update: 27-Dec-1998 20:19
* Last file update: 3-Sep-1999 20:20 (eg)
*/
#include <stk.h>
@ -99,7 +95,14 @@ unsigned long sxhash(SCM obj)
case tc_integer:
case tc_bignum: return (unsigned long) STk_integer_value_no_overflow(obj);
case tc_flonum: return (unsigned long) FLONM(obj);
case tc_symbol: return HashString(PNAME(obj));
case tc_symbol: /* For some reasons
* return (unsigned long) obj;
* which is correct, yiels worse results than the
* following code. Perhaps, we have a better
*repartion by using hashing on the chars. Weird!
*/
return HASH_WORD(0, (unsigned long) obj);
return HashString(PNAME(obj));
case tc_keyword: return HashString(KEYVAL(obj));
case tc_string: return HashString(CHARS(obj));
case tc_vector: h = 0;
@ -131,7 +134,7 @@ static SCM find_key(SCM obj, SCM alist, SCM comparison)
for(l=alist; !NULLP(l); l=CDR(l)) {
tmp = CAR(l);
if (STk_apply(comparison, LIST2(obj, CAR(tmp))) != Ntruth) return tmp;
if (Apply2(comparison, obj, CAR(tmp)) != Ntruth) return tmp;
}
return NULL;
}
@ -145,7 +148,7 @@ static SCM remove_key(SCM obj, SCM alist, SCM comparison)
register SCM l;
for(l=NIL; !NULLP(alist); alist=CDR(alist)) {
if (STk_apply(comparison, LIST2(obj, CAR(CAR(alist)))) == Ntruth)
if (Apply2(comparison, obj, CAR(CAR(alist))) == Ntruth)
l = Cons(CAR(alist), l);
}
return l;
@ -248,22 +251,22 @@ static PRIMITIVE hash_table_put(SCM ht, SCM key, SCM val)
{
Tcl_HashEntry *entry;
SCM index;
int new;
int new_entry;
if (!HASHP(ht)) Err("hash-table-put!: bad hash table", ht);
switch (HASH_TYPE(ht)) {
case hash_eq:
entry = Tcl_CreateHashEntry(HASH_H(ht), (char *) key, &new);
entry = Tcl_CreateHashEntry(HASH_H(ht), (char *) key, &new_entry);
Tcl_SetHashValue(entry, val);
break;
case hash_string:
if (!STRINGP(key)) Err("hash-table-put!: bad string", key);
entry = Tcl_CreateHashEntry(HASH_H(ht), CHARS(key), &new);
entry = Tcl_CreateHashEntry(HASH_H(ht), CHARS(key), &new_entry);
Tcl_SetHashValue(entry, val);
break;
case hash_comp:
index = Apply(HASH_SXHASH(ht), LIST1(key));
index = Apply1(HASH_SXHASH(ht), key);
if ((entry=Tcl_FindHashEntry(HASH_H(ht), (char *) index)) != NULL) {
SCM old = (SCM) Tcl_GetHashValue(entry); /* waz here */
SCM tmp = find_key(key, old, HASH_COMP(ht));
@ -277,7 +280,7 @@ static PRIMITIVE hash_table_put(SCM ht, SCM key, SCM val)
}
else { /* new bucket */
SCM tmp = LIST1(Cons(key, val)); /* place it in tmp to avoid GC problems */
entry = Tcl_CreateHashEntry(HASH_H(ht), (char *) index, &new);
entry = Tcl_CreateHashEntry(HASH_H(ht), (char *) index, &new_entry);
Tcl_SetHashValue(entry, tmp);
}
break;
@ -305,7 +308,7 @@ static PRIMITIVE hash_table_get(SCM ht, SCM key, SCM default_value)
return (SCM) Tcl_GetHashValue(entry);
break;
case hash_comp:
index = Apply(HASH_SXHASH(ht), LIST1(key));
index = Apply1(HASH_SXHASH(ht), key);
if (entry=Tcl_FindHashEntry(HASH_H(ht), (char *) index)) {
SCM tmp, val = (SCM) Tcl_GetHashValue(entry);
@ -340,7 +343,7 @@ static PRIMITIVE hash_table_remove(SCM ht, SCM key)
Tcl_DeleteHashEntry(entry);
break;
case hash_comp:
index = Apply(HASH_SXHASH(ht), LIST1(key));
index = Apply1(HASH_SXHASH(ht), key);
if (entry=Tcl_FindHashEntry(HASH_H(ht), (char *) index)) {
SCM tmp, val = (SCM) Tcl_GetHashValue(entry);
@ -371,14 +374,14 @@ static PRIMITIVE hash_table_for_each(SCM ht, SCM proc)
switch (HASH_TYPE(ht)) {
case hash_eq:
Apply(proc, LIST2((SCM) Tcl_GetHashKey(HASH_H(ht), entry),
(SCM) Tcl_GetHashValue(entry)));
Apply2(proc, (SCM) Tcl_GetHashKey(HASH_H(ht), entry),
(SCM) Tcl_GetHashValue(entry));
break;
case hash_string:
{
char *s = Tcl_GetHashKey(HASH_H(ht), entry);
Apply(proc, LIST2(STk_makestring(s), (SCM) Tcl_GetHashValue(entry)));
Apply2(proc, STk_makestring(s), (SCM) Tcl_GetHashValue(entry));
}
break;
case hash_comp:
@ -386,7 +389,7 @@ static PRIMITIVE hash_table_for_each(SCM ht, SCM proc)
SCM val;
for (val=(SCM) Tcl_GetHashValue(entry); !NULLP(val); val = CDR(val))
Apply(proc, LIST2(CAR(CAR(val)), CDR(CAR(val))));
Apply2(proc, CAR(CAR(val)), CDR(CAR(val)));
}
}
}
@ -408,16 +411,16 @@ static PRIMITIVE hash_table_map(SCM ht, SCM proc)
switch (HASH_TYPE(ht)) {
case hash_eq:
result = Cons(Apply(proc, LIST2((SCM)Tcl_GetHashKey(HASH_H(ht), entry),
(SCM) Tcl_GetHashValue(entry))),
result = Cons(Apply2(proc, (SCM)Tcl_GetHashKey(HASH_H(ht), entry),
(SCM) Tcl_GetHashValue(entry)),
result);
break;
case hash_string:
{
char *s = Tcl_GetHashKey(HASH_H(ht), entry);
result = Cons(Apply(proc, LIST2(STk_makestring(s),
(SCM) Tcl_GetHashValue(entry))),
result = Cons(Apply2(proc, STk_makestring(s),
(SCM) Tcl_GetHashValue(entry)),
result);
}
break;
@ -426,7 +429,7 @@ static PRIMITIVE hash_table_map(SCM ht, SCM proc)
SCM val;
for (val=(SCM) Tcl_GetHashValue(entry); !NULLP(val); val = CDR(val))
result = Cons(Apply(proc, LIST2(CAR(CAR(val)), CDR(CAR(val)))),
result = Cons(Apply2(proc, CAR(CAR(val)), CDR(CAR(val))),
result);
}
}

View File

@ -2,22 +2,21 @@
*
* h t m l . c -- Html support for STk
*
* Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
*
* $Id: html.c 1.4 Mon, 28 Dec 1998 23:05:11 +0100 eg $
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 1-Sep-1995 23:10
* Last file update: 27-Dec-1998 20:20
* Last file update: 3-Sep-1999 20:20 (eg)
*/
#include <ctype.h>

View File

@ -3,24 +3,22 @@
* l o c a l e . c -- Locale management
*
*
* Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
*
* This software is a derivative work of other copyrighted softwares; the
* copyright notices of these softwares are placed in the file COPYRIGHTS
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
*
* Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 19-Sep-1998 12:01
* Last file update: 19-Sep-1998 15:02
* Last file update: 3-Sep-1999 20:21 (eg)
*
*
*/

View File

@ -319,7 +319,7 @@ ImgXpmConfigureMaster(masterPtr, argc, argv, flags)
} else {
Tcl_AppendResult(masterPtr->interp,
#ifdef STk_CODE
"must specify :data or :file", NULL);
"must specify :data or :file", NULL);
#else
"must specify one of -data, -file or -id", NULL);
#endif

View File

@ -2,25 +2,22 @@
*
* p o s i x . c -- Provide some POSIX.1 functions
*
* Copyright © 1993-1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
* Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, and/or distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
* that both the above copyright notice and this permission notice appear in
* all copies and derived works. Fees for distribution or use of this
* software or derived works may only be charged with express written
* permission of the copyright holder.
* This software is provided ``as is'' without express or implied warranty.
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* This software is a derivative work of other copyrighted softwares; the
* copyright notices of these softwares are placed in the file COPYRIGHTS
*
* $Id: posix.c 1.3 Wed, 18 Nov 1998 16:16:26 +0100 eg $
*
* Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 14-Mar-1995 20:14
* Last file update: 10-Nov-1998 23:35
* Last file update: 3-Sep-1999 20:21 (eg)
*
* This file contains also contains code additions from Shiro Kawai
* <shiro@sqush.squareusa.com>

View File

@ -1,17 +1,67 @@
/*
* p r o c e s s . c -- Access to processes from STk
*
* Copyright © 1994-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
*
*
* Permission to use, copy, modify, distribute,and license this
* software and its documentation for any purpose is hereby granted,
* provided that existing copyright notices are retained in all
* copies and that this notice is included verbatim in any
* distributions. No written agreement, license, or royalty fee is
* required for any of the authorized uses.
* This software is provided ``AS IS'' without express or implied
* warranty.
*
* Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: ??-???-1994 ??:??
* Last file update: 3-Sep-1999 20:22 (eg)
*
*
* The implementation for Win32 is a contribution of people from Grammatech
* (Paul Anderson <paul@grammatech.com> and Sarah Calvo <sarah@grammatech.com>
*
* The main function run-process has been duplicated because the #ifdef were
* too "intricated".
*
*/
/******************************************************************************
*
* Process extended type definition
*
******************************************************************************/
#include "stk.h"
#include <fcntl.h>
#include <errno.h>
#include <sys/param.h>
#include <sys/wait.h>
#include <sys/stat.h>
#include <unistd.h>
#include <signal.h>
#if defined(_WIN32) && !defined(__CYGWIN__)
# define PURE_WIN32
#endif
#ifdef PURE_WIN32
# include <windows.h>
# include <process.h>
# include <stdlib.h>
# include <stdio.h>
# include <time.h>
# include <io.h>
# include <fcntl.h>
# include <sys/stat.h>
# include "stk.h"
# define close _close
# define stat _stat
# define pipe _pipe
# define WEXITSTATUS(n) n
#else /* ! PURE_WIN32 */
# include "stk.h"
# include <fcntl.h>
# include <errno.h>
# include <sys/param.h>
# include <sys/wait.h>
# include <sys/stat.h>
# include <unistd.h>
# include <signal.h>
#endif
static int tc_process; /* Process signature */
@ -27,6 +77,8 @@ struct process_info {
SCM stream[3]; /* Redirections for stdin stdout and stderr */
int exited; /* Process is terminated */
int exit_status; /* Exit status of the processus */
int waited_on; /* non zero if the process is being
waited on by a waitpid(..,..,0) */
};
#define PROCESS(x) ((struct process_info *)((x)->storage_as.extension.data))
@ -43,24 +95,24 @@ static char *stdStreams[3] = {
"error",
};
static char key_inp[] = ":input";
static char key_out[] = ":output";
static char key_err[] = ":error";
static char key_wit[] = ":wait";
static char key_hst[] = ":host";
static char key_inp[] = ":input";
static char key_out[] = ":output";
static char key_err[] = ":error";
static char key_wit[] = ":wait";
static char key_hst[] = ":host";
static char key_hide[] = ":hide";
#if defined(SIGCHLD) && !defined(HPUX)
# define USE_SIGCHLD 1 /* What's the problem with HP? */
#endif
#ifdef USE_SIGCHLD
#define PURGE_PROCESS_TABLE() /* Nothing to do */
# define PURGE_PROCESS_TABLE() /* Nothing to do */
#else
#define PURGE_PROCESS_TABLE() process_terminate_handler(0) /* Simulate a SIGCHLD */
# define PURGE_PROCESS_TABLE() process_terminate_handler(0)/* Simulate a SIGCHLD */
#endif
/******************************************************************************/
static void init_proc_table(void)
@ -82,11 +134,26 @@ static int find_process(SCM prc)
static int internal_process_alivep(SCM process)
{
int info, res;
if (PROCESS(process)->exited)
return FALSE;
else if (PROCESS(process)->waited_on)
return TRUE;
else {
#ifdef PURE_WIN32
int info;
GetExitCodeProcess((HANDLE)PROCPID(process), &info);
if (info == STILL_ACTIVE)
return TRUE;
else {
/* process has terminated and we must save this information */
PROCESS(process)->exited = TRUE;
PROCESS(process)->exit_status = info;
return FALSE;
}
#else
int info, res;
/* Use waitpid to gain the info. */
res = waitpid(PROCPID(process), &info, WNOHANG);
if (res == 0)
@ -104,6 +171,7 @@ static int internal_process_alivep(SCM process)
/* if so, then status has already been updated */
return FALSE;
}
#endif
}
}
@ -166,13 +234,25 @@ static SCM make_process(void)
LPROCESS(z) = (struct process_info *) must_malloc(sizeof(struct process_info));
PROCESS(z)->index = i;
PROCESS(z)->stream[0] = PROCESS(z)->stream[1] = PROCESS(z)->stream[2] = Ntruth;
PROCESS(z)->exit_status = PROCESS(z)->exited = 0;
PROCESS(z)->waited_on = PROCESS(z)->exit_status = PROCESS(z)->exited = 0;
/* Enter this process in the process table */
proc_arr[i] = z;
return z;
}
#ifdef PURE_WIN32
static void cannot_run(HANDLE pipes[3][2], char **argv, char *msg, SCM obj)
{
int i;
for (i=0; i<3; i++) {
if (pipes[i][0]) CloseHandle(pipes[i][0]);
if (pipes[i][1]) CloseHandle(pipes[i][1]);
}
free(argv);
STk_procedure_error("run-process", msg, obj);
}
#else
static void cannot_run(int pipes[3][2], char **argv, char *msg, SCM obj)
{
int i;
@ -184,17 +264,385 @@ static void cannot_run(int pipes[3][2], char **argv, char *msg, SCM obj)
free(argv);
STk_procedure_error("run-process", msg, obj);
}
#endif
#ifdef PURE_WIN32
/*===========================================================================*\
*
* Implementation of run-process for Win32
*
\*==========================================================================*/
char *Win32Err(char *msg)
{
static char errMsg[1024];
LPVOID lpMsgBuf;
FormatMessage(FORMAT_MESSAGE_ALLOCATE_BUFFER |
FORMAT_MESSAGE_FROM_SYSTEM |
FORMAT_MESSAGE_IGNORE_INSERTS,
NULL,
GetLastError(),
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
(LPTSTR) &lpMsgBuf,
0,
NULL);
sprintf(errMsg, "%s: %s", msg, lpMsgBuf);
LocalFree( lpMsgBuf );
return &errMsg[0];
}
void ShowError(HANDLE pipes[3][2], char **argv, SCM obj, char *msg)
{
char *errMsg;
errMsg = Win32Err(msg);
cannot_run(pipes, argv, errMsg, NIL);
}
static BOOL SameFile(LPTSTR f1, LPTSTR f2)
{
HANDLE h1;
HANDLE h2;
BY_HANDLE_FILE_INFORMATION b1;
BY_HANDLE_FILE_INFORMATION b2;
h1 = CreateFile(f1, 0, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
if (h1 == INVALID_HANDLE_VALUE)
return FALSE;
h2 = CreateFile(f2, 0, 0, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
if (h2 == INVALID_HANDLE_VALUE)
return FALSE;
if (!GetFileInformationByHandle(h1, &b1))
return FALSE;
if (!GetFileInformationByHandle(h2, &b2))
return FALSE;
return b1.dwVolumeSerialNumber == b2.dwVolumeSerialNumber &&
b1.nFileIndexHigh == b2.nFileIndexHigh &&
b1.nFileIndexHigh == b2.nFileIndexHigh;
}
/*
* Here it is
*
*/
static PRIMITIVE run_process(SCM l, int len)
{
SCM proc, tmp, redirection[3];
int pid, i, argc, waiting, pipes[3][2];
int pid, i, argc, waiting, hidden;
struct process_info *info;
char host[100], msg[256], **argv, **argv_start;
/* Initializations */
argc = 0; waiting = FALSE;
HANDLE pipes[3][2];
DWORD handleKeys[] = { STD_INPUT_HANDLE, STD_OUTPUT_HANDLE, STD_ERROR_HANDLE };
SECURITY_ATTRIBUTES saAttr;
STARTUPINFO startupInfo;
PROCESS_INFORMATION processInfo;
char *sCmdLine, **aPtr;
int cmdLineLen;
BOOL bResult;
saAttr.nLength = sizeof(SECURITY_ATTRIBUTES);
saAttr.bInheritHandle = TRUE;
saAttr.lpSecurityDescriptor = NULL;
ZeroMemory(&startupInfo, sizeof(STARTUPINFO));
startupInfo.dwFlags = STARTF_USESTDHANDLES;
startupInfo.lpReserved2 = NULL;
startupInfo.wShowWindow = SW_HIDE;
argc = 0; waiting = FALSE; hidden = FALSE;
argv_start = (char**)must_malloc((len+3)*sizeof(char *)); /* 3= NULL+rsh+host */
argv = argv_start + 2;
for (i = 0; i < 3; i++) {
redirection[i] = NIL;
pipes[i][0] = pipes[i][1] = NULL;
}
/* Checking arguments and creating UNIX-style arguments list */
for ( ; NNULLP(l); l = CDR(l)) {
tmp = CAR(l);
if (KEYWORDP(tmp)) {
/* Manage :input, :output, :error and :no-wait keywords */
int i = -1;
if (NCONSP(CDR(l)))
cannot_run(pipes, argv_start,"no argument after keyword", tmp);
l = CDR(l); /* Go to next item */
if (STk_eqv(tmp, STk_makekey(key_hst)) == Truth) {
/* :host keyword processing */
if (NSTRINGP(CAR(l)))
cannot_run(pipes, argv_start, "string expected. It was", CAR(l));
strcpy(host, CHARS(CAR(l))); /* to avoid GC problems */
/* Shift argv to point the start of allocated zone. This avoid a copy
* of arguments already processed.
*/
argv = argv_start;
argc += 2;
argv[0] = "rsh";
argv[1] = host;
}
else {
if (STk_eqv(tmp, STk_makekey(key_wit)) == Truth) {
/* :wait option processing */
if (NBOOLEANP(CAR(l)))
cannot_run(pipes, argv_start, "boolean expected. It was", CAR(l));
waiting = (CAR(l) == Truth);
}
else if (STk_eqv(tmp, STk_makekey(key_hide)) == Truth) {
/* :hide option processing */
if (NBOOLEANP(CAR(l)))
cannot_run(pipes, argv_start, "boolean expected. It was", CAR(l));
hidden = (CAR(l) == Truth);
}
else {
/* :input, :output, :error option processing */
if (STk_eqv(tmp, STk_makekey(key_inp)) == Truth) i = 0; else
if (STk_eqv(tmp, STk_makekey(key_out)) == Truth) i = 1; else
if (STk_eqv(tmp, STk_makekey(key_err)) == Truth) i = 2;
if (i < 0) cannot_run(pipes, argv_start, "bad keyword", tmp);
redirection[i] = CAR(l);
if (STRINGP(redirection[i])) {
/* Redirection in a file */
int j;
/*
* First try to look if this redirecttion has not already done
* This can arise by doing
* :output "out" :error "out" which is correct
* :output "out" :input "out" which is obviously incorrect
*/
for (j = 0; j < 3; j++) {
if (j != i && STRINGP(redirection[j])) {
if (SameFile(CHARS(redirection[i]), CHARS(redirection[j]))) {
if (i == 0 || j == 0) {
sprintf(msg, "read/write on the same file: %s",
CHARS(redirection[i]));
cannot_run(pipes, argv_start, msg, NIL);
}
break;
}
}
}
/*
* Two cases are possible here:
* - We have stdout and stderr redirected on the same file (j != 3)
* - We have not found current file in list of redirections (j == 3)
*/
if (j == 3) {
pipes[i][0] = CreateFile (CHARS(redirection[i]),
i==0 ? GENERIC_READ : GENERIC_WRITE,
FILE_SHARE_READ,
&saAttr,
i==0 ? OPEN_EXISTING : TRUNCATE_EXISTING,
0L, NULL);
if (pipes[i][0] == INVALID_HANDLE_VALUE) {
if (GetLastError() == ERROR_FILE_NOT_FOUND &&
i > 0 &&
(pipes[i][0] = CreateFile(CHARS(redirection[i]),
GENERIC_WRITE, FILE_SHARE_READ,
&saAttr, CREATE_ALWAYS, 0L, NULL))
!= INVALID_HANDLE_VALUE)
/* nothing */;
else
ShowError(pipes, argv_start, NIL, "CreateFile");
}
}
if(pipes[i][0] < 0) {
sprintf(msg, "can't redirect standard %s to file %s",
stdStreams[i], CHARS(redirection[i]));
cannot_run(pipes, argv_start, msg, NIL);
}
}
else
if (KEYWORDP(redirection[i])) {
/* Redirection in a pipe */
BOOL bSuccess;
HANDLE hProcess;
HANDLE hRead;
HANDLE hWrite;
bSuccess = CreatePipe(&hRead,
&hWrite,
&saAttr,
0);
if (!bSuccess) {
ShowError(pipes, argv_start, NIL, "CreatePipe");
}
hProcess = GetCurrentProcess();
/* This duplicate is necessary in order to prevent the child process
inheriting the other end of the pipe. For example, for the stdin
pipe, I want the child to inherit the read end, but NOT the
write end. */
bSuccess = DuplicateHandle(hProcess,
i==0 ? hWrite : hRead,
hProcess,
&pipes[i][i==0 ? 1 : 0],
0,
FALSE,
DUPLICATE_SAME_ACCESS);
if (!bSuccess) {
ShowError(pipes, argv_start, NIL,
"DuplicateHandle for Pipe (read)");
}
pipes[i][i==0 ? 0 : 1] = i==0 ? hRead : hWrite;
CloseHandle(i==0 ? hWrite : hRead);
}
}
}
}
else {
/* Normal arg. Put it in argv */
if (NSTRINGP(tmp))
cannot_run(pipes, argv_start, "bad string", tmp);
argv[argc++] = CHARS(tmp);
}
}
argv[argc] = NULL;
if (argc == 0) cannot_run(pipes, argv_start,"no command given", NIL);
/* Build a process object */
proc = make_process();
info = PROCESS(proc);
if (pipes[0][0])
startupInfo.hStdInput = pipes[0][0];
else
startupInfo.hStdInput = GetStdHandle(STD_INPUT_HANDLE);
if (pipes[1][KEYWORDP(redirection[1]) ? 1 : 0])
startupInfo.hStdOutput = pipes[1][KEYWORDP(redirection[1]) ? 1 : 0];
else
startupInfo.hStdOutput = GetStdHandle(STD_OUTPUT_HANDLE);
if (pipes[2][KEYWORDP(redirection[2]) ? 1 : 0])
startupInfo.hStdError = pipes[2][KEYWORDP(redirection[2]) ? 1 : 0];
else
startupInfo.hStdError = GetStdHandle(STD_ERROR_HANDLE);
if (hidden)
startupInfo.dwFlags |= STARTF_USESHOWWINDOW;
cmdLineLen = strlen(*argv) + 1;
sCmdLine = must_malloc(cmdLineLen);
strcpy(sCmdLine, *argv);
for (aPtr = argv+1 ; *aPtr != NULL ; aPtr++) {
char *t;
cmdLineLen += strlen(*aPtr) + 2;
t = must_malloc(cmdLineLen);
sprintf(t, "%s %s", sCmdLine, *aPtr);
free(sCmdLine);
sCmdLine = t;
}
bResult = CreateProcess
(NULL,
sCmdLine, /* the command line */
NULL, /* pointer to process security attributes */
NULL, /* pointer to thread security attributes */
TRUE, /* Inherit */
0L, /* creation flags */
NULL, /* pointer to new environment */
NULL, /* pointer to current directory name */
&startupInfo,
&processInfo);
if (!bResult) {/* zero means failure */
ShowError(pipes, argv_start, proc, "CreateProcess");
}
free(sCmdLine);
info->pid = pid = (int)processInfo.hProcess;
for(i = 0; i < 3; i++) {
if (STRINGP(redirection[i])) {
/* Redirection in a file */
bResult = CloseHandle(pipes[i][0]);
if (!bResult)
Err(Win32Err("CloseHandle(pipes][i][0])"), NIL);
}
else
if (KEYWORDP(redirection[i])) {
/* Redirection in a pipe */
bResult = CloseHandle(pipes[i][i == 0 ? 0 : 1]);
if (!bResult)
Err(Win32Err("CloseHandle(pipes][i][0])"), NIL);
/* Make a new file descriptor to access the pipe */
{
char *s;
FILE *f;
HANDLE h;
int flags;
int fd;
h = i == 0 ? pipes[i][1] : pipes[i][0];
flags = i==0 ? _O_APPEND : _O_RDONLY;
/* see (Q99173) with the title 'Types of File I/O Under Win32' */
fd = _open_osfhandle((long) h, flags);
f = fdopen(fd, i==0 ? "w" : "r");
if (f == NULL)
cannot_run(pipes, argv_start, "run-process: cannot fdopen", proc);
sprintf(msg, "pipe-%s-%d", stdStreams[i], pid);
s = (char *) must_malloc(strlen(msg)+1);
strcpy(s, msg);
info->stream[i] = STk_Cfile2port(s,
f,
(i==0) ? tc_oport : tc_iport,
0);
}
}
}
if (waiting) {
if (WaitForSingleObject(processInfo.hProcess, INFINITE) == WAIT_FAILED) {
char *errMsg;
errMsg = Win32Err("WaitForSingleObject");
Err(errMsg, NIL);
}
else {
GetExitCodeProcess(processInfo.hProcess, &(info->exit_status));
info->exited = TRUE;
}
}
free(argv_start);
return proc;
}
#else
/*===========================================================================*\
*
* Implementation of run-process for Unix
*
\*==========================================================================*/
static PRIMITIVE run_process(SCM l, int len)
{
SCM proc, tmp, redirection[3];
int pid, i, argc, waiting, hidden;
struct process_info *info;
char host[100], msg[256], **argv, **argv_start;
/* Initializations */
int pipes[3][2];
argc = 0; waiting = FALSE; hidden = FALSE;
argv_start = (char**)must_malloc((len+3)*sizeof(char *)); /* 3= NULL+rsh+host */
argv = argv_start + 2;
@ -236,6 +684,13 @@ static PRIMITIVE run_process(SCM l, int len)
waiting = (CAR(l) == Truth);
}
else if (STk_eqv(tmp, STk_makekey(key_hide)) == Truth) {
/* :hide option processing */
if (NBOOLEANP(CAR(l)))
cannot_run(pipes, argv_start, "boolean expected. It was", CAR(l));
hidden = (CAR(l) == Truth);
}
else {
/* :input, :output, :error option processing */
if (STk_eqv(tmp, STk_makekey(key_inp)) == Truth) i = 0; else
@ -385,13 +840,19 @@ static PRIMITIVE run_process(SCM l, int len)
}
}
if (waiting) {
info->waited_on = 1;
waitpid(pid, &(info->exit_status), 0);
info->waited_on = 0;
info->exited = TRUE;
}
}
free(argv_start);
return proc;
}
#endif /* PURE_WIN32 */
static PRIMITIVE processp(SCM process)
@ -448,23 +909,36 @@ static PRIMITIVE process_error(SCM process)
static PRIMITIVE process_wait(SCM process)
{
struct process_info *proc;
PURGE_PROCESS_TABLE();
if(NPROCESSP(process)) Err("process-wait: bad process", process);
if (PROCESS(process)->exited) return Ntruth;
proc = PROCESS(process);
if (proc->exited) return Ntruth;
else {
int info, res;
int res, info;
SCM ret_val;
proc->waited_on = 1;
#ifdef PURE_WIN32
WaitForSingleObject((HANDLE)PROCPID(process), INFINITE);
GetExitCodeProcess((HANDLE)PROCPID(process), &proc->exit_status);
ret_val = Truth;
#else
res = waitpid(PROCPID(process), &info, 0);
if (res == PROCPID(process)) {
PROCESS(process)->exit_status = info;
PROCESS(process)->exited = TRUE;
return Truth;
proc->exit_status = info;
ret_val = Truth;
}
else
return Ntruth;
ret_val = Ntruth;
#endif
proc->waited_on = 0;
proc->exited = TRUE;
return ret_val;
}
}
@ -477,9 +951,29 @@ static PRIMITIVE process_xstatus(SCM process)
if (NPROCESSP(process)) Err("process-exit-status: bad process", process);
if (PROCESS(process)->exited)
n = WEXITSTATUS(PROCESS(process)->exit_status);
if (PROCESS(process)->exited) {
#ifdef PURE_WIN32
n = PROCESS(process)->exit_status;
#else
if (WIFSIGNALED(PROCESS(process)->exit_status))
n = WCOREDUMP(PROCESS(process)->exit_status);
else
n = WEXITSTATUS(PROCESS(process)->exit_status);
#endif
}
else {
#ifdef PURE_WIN32
GetExitCodeProcess((HANDLE)PROCPID(process), &res);
info = res;
if (res == STILL_ACTIVE) /* Process is still running */
return Ntruth;
else {
/* Process is now terminated */
PROCESS(process)->exited = TRUE;
PROCESS(process)->exit_status = info;
n = WEXITSTATUS(info);
}
#else
res = waitpid(PROCPID(process), &info, WNOHANG);
if (res == 0) {
/* Process is still running */
@ -493,14 +987,16 @@ static PRIMITIVE process_xstatus(SCM process)
}
else
return Ntruth;
#endif
}
return STk_makeinteger((long) n);
}
#ifndef PURE_WIN32
static PRIMITIVE process_send_signal(SCM process, SCM signal)
{
ENTER_PRIMITIVE("process-send-signal");
PURGE_PROCESS_TABLE();
if (NPROCESSP(process)) Serror("bad process", process);
@ -509,13 +1005,21 @@ static PRIMITIVE process_send_signal(SCM process, SCM signal)
kill(PROCPID(process), STk_integer_value(signal));
return UNDEFINED;
}
#endif
static PRIMITIVE process_kill(SCM process)
{
#ifdef PURE_WIN32
TerminateProcess((HANDLE)PROCPID(process), 0);
return UNDEFINED;
#else
if (NPROCESSP(process)) Err("process-kill: bad process", process);
return process_send_signal(process, STk_makeinteger(SIGTERM));
#endif
}
#ifdef SIGSTOP
static PRIMITIVE process_stop(SCM process)
{
@ -580,7 +1084,6 @@ static STk_extended_scheme_type process_type = {
/******************************************************************************/
PRIMITIVE STk_init_process(void)
{
tc_process = STk_add_new_type(&process_type);
@ -613,23 +1116,26 @@ PRIMITIVE STk_init_process(void)
# endif
#endif
STk_add_new_primitive("run-process", tc_lsubr, run_process);
STk_add_new_primitive("process?", tc_subr_1, processp);
STk_add_new_primitive("process-alive?", tc_subr_1, process_alivep);
STk_add_new_primitive("process-pid", tc_subr_1, process_pid);
STk_add_new_primitive("process-list", tc_subr_0, process_list);
STk_add_new_primitive("process-input", tc_subr_1, process_input);
STk_add_new_primitive("process-output", tc_subr_1, process_output);
STk_add_new_primitive("run-process", tc_lsubr, run_process);
STk_add_new_primitive("process?", tc_subr_1, processp);
STk_add_new_primitive("process-alive?", tc_subr_1, process_alivep);
STk_add_new_primitive("process-pid", tc_subr_1, process_pid);
STk_add_new_primitive("process-list", tc_subr_0, process_list);
STk_add_new_primitive("process-input", tc_subr_1, process_input);
STk_add_new_primitive("process-output", tc_subr_1, process_output);
STk_add_new_primitive("process-error", tc_subr_1, process_error);
STk_add_new_primitive("process-wait", tc_subr_1, process_wait);
STk_add_new_primitive("process-exit-status", tc_subr_1, process_xstatus);
STk_add_new_primitive("process-wait", tc_subr_1, process_wait);
STk_add_new_primitive("process-exit-status", tc_subr_1, process_xstatus);
STk_add_new_primitive("process-kill", tc_subr_1, process_kill);
#ifndef PURE_WIN32
STk_add_new_primitive("process-send-signal", tc_subr_2, process_send_signal);
STk_add_new_primitive("process-kill", tc_subr_1, process_kill);
#endif
#ifdef SIGSTOP
STk_add_new_primitive("process-stop", tc_subr_1, process_stop);
STk_add_new_primitive("process-stop", tc_subr_1, process_stop);
#endif
#ifdef SIGCONT
STk_add_new_primitive("process-continue", tc_subr_1, process_continue);
STk_add_new_primitive("process-continue", tc_subr_1, process_continue);
#endif
return UNDEFINED;
}

View File

@ -9,31 +9,47 @@
*
* Win32 support by Caleb Deupree <cdeupree@erinet.com>
*
* Last file update: 20-Dec-1998 10:34
* Modified on: 27-Apr-1999 12:54 (Steve Pruitt <steve@pruitt.net>)
* Last file update: 3-Sep-1999 19:46 (eg)
*
* For Win32 support the following changes were made:
*
* 1) re-arraged includes to remove define errors
*
* 2) added define for CLOSESOCKET
*
* 3) Removed calls tcl_DeleteFileHandler and tclDeleteFileHandler
*
* 4) added new portable primitives: initialize-client-socket,
* accept-connection, close-connection, socket-handle,
* socket-recv, socket-send and socket-peek
*/
#ifdef WIN32
# include <fcntl.h>
# include <tclWinPort.h>
# define BAD_SOCKET(s) ((s) == INVALID_SOCKET)
# ifndef _O_WRONLY
# define _O_WRONLY O_WRONLY
# endif
# ifndef _O_RDONLY
# define _O_RDONLY O_RDONLY
# endif
# define CLOSESOCKET closesocket
# include <fcntl.h>
# include "stk.h"
# include "stk.h"
# define BAD_SOCKET(s) ((s) == INVALID_SOCKET)
# ifndef _O_WRONLY
# define _O_WRONLY O_WRONLY
# endif
# ifndef _O_RDONLY
# define _O_RDONLY O_RDONLY
# endif
#else
# define CLOSESOCKET close
# include <sys/types.h>
# include <sys/socket.h>
# include <netinet/in.h>
# include <arpa/inet.h>
# include <netdb.h>
# include <memory.h>
# include "stk.h"
# define BAD_SOCKET(s) ((s) < 0)
#endif
#include "stk.h"
#include <errno.h>
struct socket_type {
@ -78,7 +94,7 @@ static void set_socket_io_ports(int s, SCM sock, char *who)
int t, port;
size_t len;
char *hostname, *fname;
FILE *fs, *ft;
FILE *fs= NULL, *ft = NULL; /* initialization for GCC! */
char buffer[200];
#ifdef WIN32
@ -129,8 +145,23 @@ static void set_socket_io_ports(int s, SCM sock, char *who)
* m a k e - c l i e n t - s o c k e t
*
******************************************************************************/
#ifdef WIN32
/* initialize_client_socket is identical to make_client_socket */
/* except that it does not call "set_socket_io_ports" */
static PRIMITIVE initialize_client_socket(SCM hostname, SCM port);
static PRIMITIVE make_client_socket(SCM hostname, SCM port)
{
SCM sock;
sock = initialize_client_socket(hostname, port);
set_socket_io_ports(SOCKET(sock)->fd, sock, "make-client-socket");
return sock;
}
static PRIMITIVE initialize_client_socket(SCM hostname, SCM port)
#else
static PRIMITIVE make_client_socket(SCM hostname, SCM port)
#endif
{
char str[] = "make-client-socket";
struct hostent *hp;
@ -160,7 +191,7 @@ static PRIMITIVE make_client_socket(SCM hostname, SCM port)
/* Try to connect */
if (connect(s, (struct sockaddr *) &server, sizeof(server)) < 0) {
close(s);
CLOSESOCKET(s);
system_error(str);
}
@ -176,8 +207,9 @@ static PRIMITIVE make_client_socket(SCM hostname, SCM port)
SOCKET(z)->input = Ntruth;
SOCKET(z)->output = Ntruth;
SOCKET(z)->ready_event = Ntruth;
#ifndef WIN32
set_socket_io_ports(s, z, str);
#endif
return z;
}
@ -208,20 +240,20 @@ static PRIMITIVE make_server_socket(SCM port)
sin.sin_addr.s_addr = INADDR_ANY;
if (bind(s, (struct sockaddr *) &sin, sizeof(sin)) < 0) {
close(s);
CLOSESOCKET(s);
system_error(msg);
}
/* Query the socket name (permits to get the true socket number if 0 was given */
len = sizeof(sin);
if (getsockname(s, (struct sockaddr *) &sin, (int *) &len) < 0) {
close(s);
CLOSESOCKET(s);
system_error(msg);
}
/* Indicate that we are ready to listen */
if (listen(s, 5) < 0) {
close(s);
CLOSESOCKET(s);
system_error(msg);
}
@ -245,8 +277,24 @@ static PRIMITIVE make_server_socket(SCM port)
* s o c k e t - a c c e p t - c o n n e c t i o n
*
******************************************************************************/
static PRIMITIVE socket_accept_connection(SCM sock)
#ifdef WIN32
/* accept_connection is identical to socket_accept_connection */
/* except that it does not call "set_socket_io_ports" and */
/* it also returns the accepted socket as a SCM integer */
static PRIMITIVE accept_connection(SCM sock);
static PRIMITIVE socket_accept_connection(SCM sock)
{
int new_s;
new_s = INTEGER(accept_connection(sock));
set_socket_io_ports(new_s , sock, "socket-accept-connection");
return UNDEFINED;
}
static PRIMITIVE accept_connection(SCM sock)
#else
static PRIMITIVE socket_accept_connection(SCM sock)
#endif
{
char *s;
char str[]= "socket-accept-connection";
@ -268,8 +316,12 @@ static PRIMITIVE socket_accept_connection(SCM sock)
SOCKET(sock)->hostip = STk_makestring(s);
SOCKET(sock)->hostname = STk_makestring(host? (char*) (host->h_name): s);
#ifdef WIN32
return STk_makeinteger(new_s);
#else
set_socket_io_ports(new_s, sock, str);
return UNDEFINED;
#endif
}
/******************************************************************************
@ -277,9 +329,19 @@ static PRIMITIVE socket_accept_connection(SCM sock)
* w h e n - s o c k e t - r e a d y
*
******************************************************************************/
#ifdef WIN32
static PRIMITIVE when_socket_ready(SCM s, SCM closure)
{
/* Removal of tcl_DeleteFileHandler and tclDeleteFileHandler */
/* in Tcl/Tk 8.0 make when_socket_ready impossible on Win32. */
/* Will be available again in Tcl/Tk version 8.1 FIXME */
Err("when-socket-ready: cannot be used with Win32", NIL);
return UNDEFINED;
}
#else
static void apply_socket_closure(SCM closure)
{
Apply(closure, NIL);
Apply0(closure);
}
static PRIMITIVE when_socket_ready(SCM s, SCM closure)
@ -310,6 +372,7 @@ static PRIMITIVE when_socket_ready(SCM s, SCM closure)
}
return UNDEFINED;
}
#endif
static PRIMITIVE buggy_handler(SCM s, SCM closure)
{
@ -333,12 +396,15 @@ static PRIMITIVE socket_shutdown(SCM sock, SCM close_socket)
if (close_socket == Truth && SOCKET(sock)->fd > 0) {
int fd = SOCKET(sock)->fd;
#ifndef WIN32
if (!STk_snow_is_running)
/* We cannot use #ifdef USE_TK here to have the same socket.so
* for both snow and stk. So we have to test if we are running
* snow dynamically
*/
Tcl_DeleteFileHandler(fd);
#endif
/* close(fd); */
shutdown(fd, 2);
SOCKET(sock)->fd = -1;
@ -500,6 +566,69 @@ static STk_extended_scheme_type socket_type = {
NULL /* compare function */
};
#ifdef WIN32
/*******************************************************************************
*
* These primitives allow WIN32 apps to work when the
* socket io-ports are not available. By adding Primitives
* to winsock functions "send" and "recv", sockets can be
* operated on directly.
*
******************************************************************************/
static PRIMITIVE close_connection(SCM connection)
{
if (NINTEGERP(connection))
Err("close_connection: bad connection", connection);
CLOSESOCKET(INTEGER(connection));
return UNDEFINED;
}
/******************************************************************************/
static PRIMITIVE socket_handle(SCM sock)
{
if (NSOCKETP(sock)) Err("socket-handle: bad socket", sock);
return STk_makeinteger(SOCKET(sock)->fd);
}
/******************************************************************************/
static PRIMITIVE socket_peek(SCM fd, SCM num_chars) {
int i, len;
SCM chars;
char *s;
len = INTEGER(num_chars);
chars = STk_makestrg(len+1, NULL);
s = chars->storage_as.string.data;
i = recv(INTEGER(fd), s, len, MSG_PEEK);
return chars;
}
/******************************************************************************/
static PRIMITIVE socket_recv(SCM fd, SCM buffer) {
int len, result;
char *s;
s = buffer->storage_as.string.data;
len = buffer->storage_as.string.dim - 1;
result = recv(INTEGER(fd), s, len, 0);
if (result <= 0) return STk_eof_object;
return STk_makeinteger(result);
}
/******************************************************************************/
static PRIMITIVE socket_send(SCM fd, SCM buffer, SCM num_chars) {
int len, result;
char *s;
len = INTEGER(num_chars);
s = buffer->storage_as.string.data;
result = send(INTEGER(fd), s, len, 0);
return STk_makeinteger(result);
}
#endif
/******************************************************************************/
PRIMITIVE STk_init_socket(void)
@ -520,6 +649,16 @@ PRIMITIVE STk_init_socket(void)
Err("Synchronous socket option setting failed",
STk_makeinteger(WSAGetLastError()));
}
/* new primitives for send and recv without using stdio */
STk_add_new_primitive("accept-connection", tc_subr_1, accept_connection);
STk_add_new_primitive("close-connection", tc_subr_1, close_connection);
STk_add_new_primitive("socket-handle", tc_subr_1, socket_handle);
STk_add_new_primitive("socket-peek", tc_subr_2, socket_peek);
STk_add_new_primitive("socket-recv", tc_subr_2, socket_recv);
STk_add_new_primitive("socket-send", tc_subr_3, socket_send);
STk_add_new_primitive("initialize-client-socket", tc_subr_2,
initialize_client_socket);
#endif
tc_socket = STk_add_new_type(&socket_type);

View File

@ -4,21 +4,20 @@
;;;;
;;;; stk-genmake -- Generate a Makefile for STk extensions
;;;;
;;;; Copyright © 1998 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; Copyright © 1998-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; $Id: stk-genmake.in 1.1 Sat, 06 Jun 1998 14:19:03 +0200 eg $
;;;; Permission to use, copy, modify, distribute,and license this
;;;; software and its documentation for any purpose is hereby granted,
;;;; provided that existing copyright notices are retained in all
;;;; copies and that this notice is included verbatim in any
;;;; distributions. No written agreement, license, or royalty fee is
;;;; required for any of the authorized uses.
;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty.
;;;;
;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 1-Jun-1998 18:44
;;;; Last file update: 2-Jun-1998 17:51
;;;; Last file update: 3-Sep-1999 19:42 (eg)
(define version "0.1")

View File

@ -3,12 +3,12 @@
<H2><IMG ALIGN=BOTTOM SRC=Img/RefBookGreen.gif>
The <I>STk</I> green pages</H2><HR>
<PRE>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=change-image.n.html>change-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=choose-color.n.html>choose-color</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=find-image.n.html>find-image</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=focus-next.n.html>focus-next</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=free-image.n.html>free-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=listener.n.html>listener</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-dialog.n.html>make-dialog</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-image.n.html>make-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=message-box.n.html>message-box</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=option-menu.n.html>option-menu</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=palette.n.html>palette</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=popup.n.html>popup</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-prompt.n.html>repl-display-prompt</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-result.n.html>repl-display-result</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=report-error.n.html>report-error</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=change-image.n.html>change-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=choose-color.n.html>choose-color</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=ed.n.html>ed</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=find-image.n.html>find-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=focus-next.n.html>focus-next</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=free-image.n.html>free-image</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=listener.n.html>listener</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-console.n.html>make-console</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-dialog.n.html>make-dialog</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-image.n.html>make-image</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=message-box.n.html>message-box</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=option-menu.n.html>option-menu</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=palette.n.html>palette</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=popup.n.html>popup</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-prompt.n.html>repl-display-prompt</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-result.n.html>repl-display-result</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=report-error.n.html>report-error</A>
</PRE>
<HR><A HREF=./STk-hlp.html><IMG ALIGN=BOTTOM SRC=./Img/ManPageWhite.gif> Back to the <B>STk</B> main page</A>
</BODY></HTML>

View File

@ -43,23 +43,24 @@ Hereafter is the complete list of STk help pages currently available:
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=bindtags.n.html>bindtags</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=bitmap.n.html>bitmap</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=button.n.html>button</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=canvas.n.html>canvas</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=change-image.n.html>change-image</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=checkbutton.n.html>checkbutton</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=choose-color.n.html>choose-color</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=clipboard.n.html>clipboard</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=destroy.n.html>destroy</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=entry.n.html>entry</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=event.n.html>event</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=find-image.n.html>find-image</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=focus.n.html>focus</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=focus-next.n.html>focus-next</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=frame.n.html>frame</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=free-image.n.html>free-image</A> <IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=ftp.n.html>ftp</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=grab.n.html>grab</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=grid.n.html>grid</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=image.n.html>image</A> <IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=jpeg.n.html>jpeg</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=label.n.html>label</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=listbox.n.html>listbox</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=listener.n.html>listener</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=lower.n.html>lower</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-dialog.n.html>make-dialog</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-image.n.html>make-image</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=menu.n.html>menu</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=menubutton.n.html>menubutton</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=message.n.html>message</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=message-box.n.html>message-box</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=option.n.html>option</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=option-menu.n.html>option-menu</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=options.n.html>options</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=pack.n.html>pack</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=palette.n.html>palette</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=photo.n.html>photo</A> <IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=pixmap.n.html>pixmap</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=place.n.html>place</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=popup.n.html>popup</A> <IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=posix.n.html>posix</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=radiobutton.n.html>radiobutton</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=raise.n.html>raise</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-prompt.n.html>repl-display-prompt</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-result.n.html>repl-display-result</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=report-error.n.html>report-error</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=scale.n.html>scale</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=scrollbar.n.html>scrollbar</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=selection.n.html>selection</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=send.n.html>send</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=text.n.html>text</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tk.n.html>tk</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tkvars.n.html>tkvars</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tkwait.n.html>tkwait</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=toplevel.n.html>toplevel</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=update.n.html>update</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=winfo.n.html>winfo</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=wm.n.html>wm</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=ed.n.html>ed</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=entry.n.html>entry</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=event.n.html>event</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=find-image.n.html>find-image</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=focus.n.html>focus</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=focus-next.n.html>focus-next</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=frame.n.html>frame</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=free-image.n.html>free-image</A> <IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=ftp.n.html>ftp</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=grab.n.html>grab</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=grid.n.html>grid</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=image.n.html>image</A>
<IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=jpeg.n.html>jpeg</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=label.n.html>label</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=listbox.n.html>listbox</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=listener.n.html>listener</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=lower.n.html>lower</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-console.n.html>make-console</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-dialog.n.html>make-dialog</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=make-image.n.html>make-image</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=menu.n.html>menu</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=menubutton.n.html>menubutton</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=message.n.html>message</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=message-box.n.html>message-box</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=option.n.html>option</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=option-menu.n.html>option-menu</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=options.n.html>options</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=pack.n.html>pack</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=palette.n.html>palette</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=photo.n.html>photo</A>
<IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=pixmap.n.html>pixmap</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=place.n.html>place</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=popup.n.html>popup</A>
<IMG ALIGN=BOTTOM SRC=Img/YellowBall.gif><A HREF=posix.n.html>posix</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=radiobutton.n.html>radiobutton</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=raise.n.html>raise</A>
<IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-prompt.n.html>repl-display-prompt</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=repl-display-result.n.html>repl-display-result</A> <IMG ALIGN=BOTTOM SRC=Img/GreenBall.gif><A HREF=report-error.n.html>report-error</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=scale.n.html>scale</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=scrollbar.n.html>scrollbar</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=selection.n.html>selection</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=send.n.html>send</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=text.n.html>text</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tk.n.html>tk</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tkvars.n.html>tkvars</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=tkwait.n.html>tkwait</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=toplevel.n.html>toplevel</A>
<IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=update.n.html>update</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=winfo.n.html>winfo</A> <IMG ALIGN=BOTTOM SRC=Img/BlueBall.gif><A HREF=wm.n.html>wm</A>
</PRE>
</UL>
</UL>

28
Help/ed.n.html Normal file
View File

@ -0,0 +1,28 @@
<HTML><HEAD><TITLE>Tk Built-In Commands - ed manual page</TITLE></HEAD>
<BR>
<BODY bgcolor = #c3ffc3>
<H2><IMG ALIGN=BOTTOM SRC="./Img/ManPageGreen.gif"> ed</H2>
<I>Launch an editor</I><P><IMG ALIGN=TOP SRC="./Img/line-red.gif">
<H3><A NAME="M2">SYNOPSIS</A></H3>
(<B>ed</B>)<BR>
(<B>ed</B><I> filename</I>)<BR>
<BR>
<H3><A NAME="M3">DESCRIPTION</A></H3>
The <B>ed</B> procedure creates a new Scheme editor in a toplevel
window. If a filename is provided, its content is displayed in the
editor window.
<P>
<H3><A NAME="M4">DEFAULT BINDINGS</A></H3>
The defaults bindings are identical to the <B><A HREF="./text.n.html">text</A></B>
bindings. Furthermore, if a the interpreter uses a console to interact
with the user (by default on Windows, or by using the <B>-console</B>
option of <B><A HREF="./stk.1.html">stk</A></B> on Unix), the Enter key of the numerical keyboard
or the sequence Control-Return sends the previous complete sexpr to
the interpreter.
<H3><A NAME="M5">SEE ALSO</A></H3>
<B><A HREF="./text.n.html">text</A></B>
<P><IMG ALIGN=TOP SRC="./Img/line-red.gif"><P>
<A HREF=./STk-hlp.html><IMG ALIGN=BOTTOM SRC="./Img/RefBookGreen.gif"> Back to the <B>STk</B> main page</A>
</BODY></HTML>

32
Help/make-console.n.html Normal file
View File

@ -0,0 +1,32 @@
<HTML><HEAD><TITLE>Tk Built-In Commands - console manual page</TITLE></HEAD>
<BR>
<BODY bgcolor = #c3ffc3>
<H2><IMG ALIGN=BOTTOM SRC="./Img/ManPageGreen.gif"> make-console</H2>
<I>Create a console</I><P><IMG ALIGN=TOP SRC="./Img/line-red.gif">
<H3><A NAME="M2">SYNOPSIS</A></H3>
(<B>make-console</B>)<BR>
(<B>make-console</B><I> </I><B>:module</B> <I>module</I>)<BR>
<BR>
<H3><A NAME="M3">DESCRIPTION</A></H3>
The <B>make-console</B> procedure creates a new console in a new
toplevel window. By default the interaction loop is placed in the
current module (and changes if the current module is changed). If the
console is created in a given module, thanks to the <B>:module</B>
option, it is tied to this module. This second form of console
creation is particularly useful in debugging phases to set or consult
variables which are not exported in a module.
<P>
<H3><A NAME="M4">INITIALIZATION</A></H3>
Use <B>(require &quot;console&quot;)</B> to load the console package.
<P>
<H3><A NAME="M5">DEFAULT BINDINGS</A></H3>
The defaults bindings are identical to the <B><A HREF="./text.n.html">text</A></B> bindings except the
up and down arrow of on the prompt line which allow to scan the command history.
<H3><A NAME="M6">SEE ALSO</A></H3>
<B><A HREF="./text.n.html">text</A></B>
<P><IMG ALIGN=TOP SRC="./Img/line-red.gif"><P>
<A HREF=./STk-hlp.html><IMG ALIGN=BOTTOM SRC="./Img/RefBookGreen.gif"> Back to the <B>STk</B> main page</A>
</BODY></HTML>

View File

@ -63,19 +63,22 @@ also the amount of cells used when extending the heap. Default value is 20000.
<P>
<DT><A NAME="M15">{ B-interactive R}</A><DD>
Tell the interpreter that it is used interactively (even if it doesn't
think so).
think so).
<P>
<DT><A NAME="M16">{ B-help R}</A><DD>
Print the version of the system and abort execution.
<P>
<DT><A NAME="M17">{ B-help R}</A><DD>
Print a summary of the command-line options and exit.
<P>
<DT><A NAME="M17">{ B-|- R}</A><DD>
<DT><A NAME="M18">{ B-|- R}</A><DD>
Pass all remaining arguments through to the script's <B>argv</B>
variable without interpreting them.
This provides a mechanism for passing arguments such as <B>-name</B>
to a script instead of having <B>wish</B> interpret them.
<P>
</DL>
<H3><A NAME="M18">DESCRIPTION</A></H3>
<H3><A NAME="M19">DESCRIPTION</A></H3>
<B>Stk</B> is a Scheme R4RS interpreter which provide a simple access to the
X11 Tk toolkit. If the <B>-no-tk</B> option is provided to the interpreter,
the Tk library is not initialized and no main window is created. If
@ -111,27 +114,27 @@ mode. In this mode, standard output and standard error are unbuffered.
Use this option when you launch <B>stk</B> from <B>emacs</B>.
<H3><A NAME="M19">VARIABLES</A></H3>
<H3><A NAME="M20">VARIABLES</A></H3>
Following Scheme variables are set when <B>Stk</B> starts:
<P>
<DL>
<DT><A NAME="M20"><B>*argc*</B></A><DD>
<DT><A NAME="M21"><B>*argc*</B></A><DD>
Contains a count of the number of <I>arg</I> arguments (0 if none),
not including the options described above.
<P>
<DT><A NAME="M21"><B>*argv*</B></A><DD>
<DT><A NAME="M22"><B>*argv*</B></A><DD>
Contains a Scheme list whose elements are the <I>arg</I> arguments (not
including the options described above), in order, or an empty list
if there are no <I>arg</I> arguments.
<P>
<DT><A NAME="M22"><B>*program-name*</B> Contains <I>fileName</I> if it was provided (in a</A><DD>
<DT><A NAME="M23"><B>*program-name*</B> Contains <I>fileName</I> if it was provided (in a</A><DD>
<B>-file</B> option or as first argument of the command line).
Otherwise, contains the name by which the interpreter was invoked.
<P>
</DL>
<H3><A NAME="M23">SCRIPT FILES</A></H3>
<H3><A NAME="M24">SCRIPT FILES</A></H3>
If you create a STk script in a file whose first line is
<PRE><B>#!/usr/local/bin/stk -f</B></PRE>
then you can invoke the script file directly from your shell if
@ -142,25 +145,25 @@ then you'll have to modify the above line to match.
Note that <B>-f</B> which was necessary with pre-4.0 versions of <B>STk</B>
is no more necessary and can be omitted.
<H3><A NAME="M24">ENVIRONMENT VARIABLES</A></H3>
<H3><A NAME="M25">ENVIRONMENT VARIABLES</A></H3>
<B>stk</B> uses the following shell variables:
<P>
<DL>
<DT><A NAME="M25">{ ISTK_LIBRARY R}</A><DD>
<DT><A NAME="M26">{ ISTK_LIBRARY R}</A><DD>
This variable indicates where the library files are located. This variable
allows to overload the default value of the Scheme variable <I>*stk-library*</I>
which is automatically calculated by the interpreter.(i.e. <I>stk</I> or <I>snow</I>).
<P>
<DT><A NAME="M26">{ ISTK_LOAD_PATH R}</A><DD>
<DT><A NAME="M27">{ ISTK_LOAD_PATH R}</A><DD>
This variable serves to initialize the <I>*load-path*</I> Scheme variable. This
variable is a list of paths to try when in a load command.
<P>
<DT><A NAME="M27">{ ISTK_HELP_PATH R}</A><DD>
<DT><A NAME="M28">{ ISTK_HELP_PATH R}</A><DD>
This variable serves to initialize the <I>*help-path*</I> Scheme variable. It
must contain a list of documentation directories. This variable is used by the help
procedure.
<P>
<DT><A NAME="M28">{ ISTK_IMAGE_PATH R}</A><DD>
<DT><A NAME="M29">{ ISTK_IMAGE_PATH R}</A><DD>
This variable serves to initialize the <I>*image-path*</I> Scheme variable. It
must contain a list of images directories. This variable is used by the make-image
procedure.
@ -168,10 +171,10 @@ procedure.
<P>
</DL>
<H3><A NAME="M29">FILES</A></H3>
<H3><A NAME="M30">FILES</A></H3>
<DL>
<DT><A NAME="M30">{ I./init.stk R}</A><DD>
<DT><A NAME="M31">{ I$STK_LIBRARY/STk/init.stk R}</A><DD>
<DT><A NAME="M31">{ I./init.stk R}</A><DD>
<DT><A NAME="M32">{ I$STK_LIBRARY/STk/init.stk R}</A><DD>
When <B>stk</B> starts running, it tries to load the file <I>init.stk</I>
in the current directory. If this file is not present, it tries to load
this file in the <B>STk_LIBRARY</B> directory (the value of <B>STk_LIBRARY</B>
@ -179,14 +182,14 @@ is automatically computed to be in a sibling directory of the interpreter
executable.
<P>
<DT><A NAME="M32">{ I~/.stkrc R}</A><DD>
<DT><A NAME="M33">{ I~/.stkrc R}</A><DD>
Standard <I>init.stk</I> file tries to load the file <I>~/.stkrc</I>. This file
can be used to store functions definitions or variables settings that you want
to be executed at each interpreter invocation.
<P>
</DL>
<H3><A NAME="M33">SEE ALSO</A></H3>
<H3><A NAME="M34">SEE ALSO</A></H3>
<B>wish(1)</B>
<P><IMG ALIGN=TOP SRC="./Img/line-red.gif"><P>
<A HREF=./STk-hlp.html><IMG ALIGN=BOTTOM SRC="./Img/RefBookWhite.gif"> Back to the <B>STk</B> main page</A>

View File

@ -915,7 +915,7 @@ If the specified range contains embedded windows, no information
about them is included in the returned string.
<P>
<DT><A NAME="M114">{( widget-name} { B'image} { Ioption} { R? Iarg} arg {... R?)}</A><DD>
<DT><A NAME="M114">(<I>widget-name </I><B>'image </B><I>option </I>?<I>arg arg ...</I>?)</A><DD>
This command is used to manipulate embedded images.
The behavior of the command depends on the <I>option</I> argument
that follows the <B>tag</B> argument.
@ -923,13 +923,13 @@ The following forms of the command are currently supported:
<P>
<P>
<DL>
<DT><A NAME="M115">{( widget-name} { B'image} {'cget R} { Iindex} {option R)}</A><DD>
<DT><A NAME="M115">(<I>widget-name </I><B>'image 'cget</B> <I>index option</I>)</A><DD>
Returns the value of a configuration option for an embedded image.
<I>Index</I> identifies the embedded image, and <I>option</I>
specifies a particular configuration option, which must be one of
the ones listed in the section EMBEDDED IMAGES.
<P>
<DT><A NAME="M116">{( widget-name} { B'image} 'configure { Iindex R} {? Ioption} value {... R?)}</A><DD>
<DT><A NAME="M116">(<I>widget-name </I><B>'image 'configure </B><I>index</I> ?<I>option value ...</I>?)</A><DD>
Query or modify the configuration options for an embedded image.
If no <I>option</I> is specified, returns a list describing all of
the available options for the embedded image at <I>index</I>
@ -944,7 +944,7 @@ this case the command returns an empty string.
See EMBEDDED IMAGES for information on the options that
are supported.
<P>
<DT><A NAME="M117">{( widget-name} { B'image} 'create { Iindex R} {? Ioption} value {... R?)}</A><DD>
<DT><A NAME="M117">(<I>Widget-name </I><B>'image 'create </B><I>index</I> ?<I>option value ...</I>?)</A><DD>
This command creates a new image annotation, which will appear
in the text at the position given by <I>index</I>.
Any number of <I>option-value</I> pairs may be specified to
@ -954,7 +954,7 @@ this image.
See EMBEDDED IMAGES for information on the options that
are supported, and a description of the identifier returned.
<P>
<DT><A NAME="M118">{( widget-name} { B'image} {'names R)}</A><DD>
<DT><A NAME="M118">(<I>Widget-name </I><B>'image 'names</B>)</A><DD>
Returns a list whose elements are the names of all image instances currently
embedded in <I>window</I>.
<P>

15
INSTALL
View File

@ -1,6 +1,6 @@
+-----------------------------+
| STk 3.99 Installation notes |
+-----------------------------+
+----------------------------+
| STk 4.0 Installation notes |
+----------------------------+
** This is the Unix INSTALL file. For Windows platform, please look at the
@ -178,8 +178,15 @@ To install stk in the definitive place, type
$ make install
Alternatively, you can use the command
$ make install-no-strip
to install the executable without stripping them.
Intalling STk and Tk libraries (useless if you don't plan to write some C code)
is done with.
is done with.
$ make install.lib

View File

@ -1,24 +1,24 @@
+-----------------------------+
| STk 3.99 Installation notes |
+-----------------------------+
+----------------------------+
| STk 4.0 Installation notes |
+----------------------------+
** This is the Windous INSTALL file. For Unix platform, please look at the
** This is the Windows INSTALL file. For Unix platform, please look at the
** INSTALL file
INSTALLATION NOTES
------------------
STk 3.99.4 has been compiled on Win32 using the VC 5.0 compiler. File
STk 4.0 has been compiled on Win32 using the VC 5.0 compiler. Files
necessary for compiling it are in the Win32 directory.
Since, I know nearly nothing on this environment, please, tell me how to make
the distribution more convenient (I know it is not ;^).
One the package is compiled, you have to install it (you cannot test
it without installing it). This can be done by using the install.bat
script in the main directory. Give to this script the directory wher
it without installing it). This can be done by using the INSTALL.BAT
script in the main directory. Give to this script the directory where
you want to install STk. For instance:
C:> install C:\STk
@ -27,7 +27,7 @@ will install all the necessary files in the C:\STk directory.
STk doesn't use the registry mechanism, so de-installing it just
consist in deleting the installation directory.
consists in deleting the installation directory.
@ -45,12 +45,8 @@ particular, I know absolutely nothing about DLL creation, compiler
environment or common customs in this environment. Any help on these
topic (or any topic btw :-) is welcome.
BTW, Some people sent me some stuff about DLL for 3.1.1. I was not able to
integrate it for 3.99 releases. I can provide this stuff if needed...
Erick Gallesio
Tue Feb 21 1999

Binary file not shown.

Before

Width:  |  Height:  |  Size: 105 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 204 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 204 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 204 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 259 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 233 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 78 B

BIN
Lib/Images/hourglass.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 211 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.4 KiB

After

Width:  |  Height:  |  Size: 256 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 215 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 265 B

BIN
Lib/Images/tb_back.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 321 B

BIN
Lib/Images/tb_console.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 343 B

BIN
Lib/Images/tb_copy.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 321 B

BIN
Lib/Images/tb_customize.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 343 B

BIN
Lib/Images/tb_cut.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 343 B

Some files were not shown because too many files have changed in this diff Show More