Commit of 4.0.1 version

This commit is contained in:
Erick Gallesio 1999-09-27 13:20:21 +02:00
parent a6b9113d17
commit 9eaf788564
71 changed files with 10330 additions and 9779 deletions

13
CHANGES
View File

@ -1,6 +1,17 @@
09/27/99 Release 4.0.1
----------------------
Mains changes/modifications since 4.0.0 are:
* Small bug fixes
* Integration of SRFI-9 (records)
* Accepts mailto: links in the browser
09/03/99 Release 4.0.0 09/03/99 Release 4.0.0
---------------------- ----------------------
Mains changes/modifications since 4.0 are: Mains changes/modifications since 3.99.4 are:
* Lot of Win32 fixes * Lot of Win32 fixes

View File

@ -1,3 +1,70 @@
1999-09-27 Erick Gallesio <eg@unice.fr>
* Release 4.0.1
* Doc/Reference/*.tex : Numerous documentation correction provided
by Ben L. Di Vito <bld@air57.larc.nasa.gov>
* Lib/srfi-9.stk: New file which implements (guess what?) SRFI-9
aka records.
* STklos/stklos.stk : Bug correction in find-class
1999-09-16 Erick Gallesio <eg@unice.fr>
* Doc/Reference/Reference2.tex : Added documentation on the
primitive export-al-symbols which was missing.
* Lib/www-mailto:
* Lib/www.stk: New hook "www:hook-mailto" to handle "mailto:"
requests. Furthermore, unknown protocol are properly handled now.
* Lib/www-browser.stklos: Added a mail composer !!! It is used
by the HTML browser when a "mailto:" is encountered.
1999-09-15 Erick Gallesio <eg@unice.fr>
* STklos/Tk/Composite/Hierarchy.stklos (maybe-update-hierarchy):
new function which retain that a update of the hierarchy is
requested. If there is already a request pending nothing is
done. This solves the problem (and enhance redisplay btw)
signalled by Harvey Stein <hjstein@bfr.co.il>
* Lib/www-url.stk : Applied a patch provided by Harvey Stein to
correctly parse URL which use proxies.
* Src/unix.c (STk_setenv): Use of STk_must_malloc instead of
malloc.
1999-09-14 Erick Gallesio <eg@unice.fr>
* Lib/init.stk (dotimes): Corrected incorrect behavior for
negative bounds. Bug signalled by "Ben L. Di Vito"
<bld@air57.larc.nasa.gov>. BTW, if no result is given by the user
in the dotimes, the result is now undetermined.
* Extensions/process.c (run_process): Added the option :fork to
run-process. This allows to simulate the "exec" command of Unix
shells. Not implemented on Win32
* Src/: Minor problems for Alpha compilation (thanks to Jeremie
Petit <Jeremie.Petit@Digital.com>)
1999-09-13 Erick Gallesio <eg@unice.fr>
* Demos/README.html: Modified the applet for allowing the
execution of the examples when STk is installed (bug signalled
by Harvey Stein <hjstein@bfr.co.il>
1999-09-12 Erick Gallesio <eg@unice.fr>
* Demos/server.stk : Bug correction: two xterm were launched and a
GC caused the death of all the demo.
* Doc/Makefile: Added the installation of manual in
$(prefix)/stk-$(version). Manual is also added in RPMS as
requested by Harvey Stein <hjstein@bfr.co.il>
1999-09-05 Erick Gallesio <eg@unice.fr> 1999-09-05 Erick Gallesio <eg@unice.fr>
* Release 4.0.0 * Release 4.0.0

2
Contrib/STk-wtour/lib/wtour.stk Normal file → Executable file
View File

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
:;exec /usr/local/bin/stk -f :;exec /usr/local/bin/stk -f "$0" "$@"
;; ;;
;; STk/Scheme widget tour, Version 0.2 ;; STk/Scheme widget tour, Version 0.2
;; ;;

View File

@ -12,7 +12,7 @@
# This software is provided ``AS IS'' without express or implied # This software is provided ``AS IS'' without express or implied
# warranty. # warranty.
# #
# Last file update: 3-Sep-1999 19:20 (eg) # Last file update: 13-Sep-1999 18:11 (eg)
# #
include ../config.make include ../config.make
@ -41,6 +41,13 @@ install:
cp Html-Demos/Images/*.gif $(DEMODIR)/Html-Demos/Images cp Html-Demos/Images/*.gif $(DEMODIR)/Html-Demos/Images
chmod 0644 $(DEMODIR)/Html-Demos/Images/* chmod 0644 $(DEMODIR)/Html-Demos/Images/*
(cd $(DEMODIR)/Html-Demos; ln -s ../amib.stklos ../stklos-widgets .) (cd $(DEMODIR)/Html-Demos; ln -s ../amib.stklos ../stklos-widgets .)
-if [ ! -d $(DEMODIR)lib ] ; then mkdir -p $(DEMODIR)/lib; fi
$(CP) ../Contrib/STk-wtour/lib/*.xbm $(DEMODIR)/lib
chmod 0644 $(DEMODIR)/lib/*
-if [ ! -d $(DEMODIR)/lessons ] ; then mkdir -p $(DEMODIR)/lessons; fi
$(CP) ../Contrib/STk-wtour/lessons/*.stk $(DEMODIR)/lessons
$(CP) ../Contrib/STk-wtour/lessons/index $(DEMODIR)/lessons
chmod 0644 $(DEMODIR)/lessons/*
install.libs: install.libs:

View File

@ -1,7 +1,7 @@
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html> <html>
<head> <head>
<title>Demo directory README (Version 4.0 - August 1999)</title> <title>Demo directory README (Version 4.0)</title>
</head> </head>
<body bgcolor="#FFFFFF"> <body bgcolor="#FFFFFF">
@ -15,10 +15,14 @@
> >
<script language="STk"> <script language="STk">
(lambda (parent url) (lambda (parent url)
(eval '(define (Run x) (eval '(begin
(system (string-append "../Src/test-stk " x "&amp;"))) (define *interp*
(global-environment)))) (if (file-exists? "../Src/test-stk") "../Src/test-stk" "stk"))
(define (run x) (system (string-append *interp* " " x " &amp;"))))
(global-environment)))
</script> </script>
@ -62,10 +66,18 @@
</ul> </ul>
<h4>Running demonstration programs in the STk web browser</h4> <h4>Running demonstration programs in the STk web browser</h4>
<ul> <ul>
<ul>
<b>Note: </b> In this document the notation
<font color=red>RUN</font> means that you must type either
<i>../Src/test-stk</i> if you have not completed the
installation of <B>STk</b>, either type <i>stk</i>
(provided that the install location is in your path)
</ul>
<p>
<b>STk</b> provides a simple Web browser which can be used to launch <b>STk</b> provides a simple Web browser which can be used to launch
the demo of this directory. If you are not running it now, you can the demo of this directory. If you are not running it now, you can
type the following command: type the following command:
<pre> ../Src/test-stk -f S-scape README.html</pre> <pre> <font color=red>RUN</font> -f S-scape README.html</pre>
at the shell prompt. at the shell prompt.
</ul> </ul>
@ -80,14 +92,14 @@
that you can click on. that you can click on.
<BR> <BR>
<u>Run with </u>: <u>Run with </u>:
<a expr=(run "hello.stk")> ../Src/test-stk -f hello.stk </a> <a expr=(run "hello.stk")> <font color=red>RUN</font> -f hello.stk </a>
<p><li> <p><li>
<B><A name=browse>browse.stk</a></B> <B><A name=browse>browse.stk</a></B>
<BR> <BR>
A simple Unix file browser. The code of this demo is less than a page. A simple Unix file browser. The code of this demo is less than a page.
<BR> <BR>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "browse.stk")>.../Src/test-stk -f browse.stk </A> <A expr=(run "browse.stk")>.<font color=red>RUN</font> -f browse.stk </A>
</UL> </UL>
<h4>1.2 Basics of STk programming</h4> <h4>1.2 Basics of STk programming</h4>
@ -102,7 +114,7 @@
<BR> <BR>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "wtour.stk ../Contrib/STk-wtour")> <A expr=(run "wtour.stk ../Contrib/STk-wtour")>
../Src/test-stk -f ./wtour.stk ../Contrib/STk-wtour <font color=red>RUN</font> -f ./wtour.stk ../Contrib/STk-wtour
</A> </A>
<BR><u>Comment</u>: This code is a contribution of <B>Suresh Srinivas</B> <BR><u>Comment</u>: This code is a contribution of <B>Suresh Srinivas</B>
<tt>&lt;ssriniva@cs.indiana.edu&gt;</tt> <tt>&lt;ssriniva@cs.indiana.edu&gt;</tt>
@ -119,7 +131,7 @@
the socket is closed the socket is closed
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "-no -f server.stk")> ../Src/test-stk -no -f server.stk </A> <A expr=(run "-no -f server.stk")> <font color=red>RUN</font> -no -f server.stk </A>
<p><li> <p><li>
<b>mc-server.stk</b> <b>mc-server.stk</b>
<br> <br>
@ -129,8 +141,8 @@
when you want to exit the demo. when you want to exit the demo.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(system "xterm -e ../Src/test-stk -load mc-server.stk &")> <A expr=(system (string-append "xterm -e " *interp* " -load mc-server.stk &"))>
../Src/test-stk -load mc-server.stk </A> <font color=red>RUN</font> -load mc-server.stk </A>
</ul> </ul>
@ -142,14 +154,14 @@
A Logo turtle package + some demo functions. A Logo turtle package + some demo functions.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "turtle.stk")> ../Src/test-stk -f turtle.stk </A> <A expr=(run "turtle.stk")> <font color=red>RUN</font> -f turtle.stk </A>
<p><li> <p><li>
<b>hanoi.stk</b> <b>hanoi.stk</b>
<br> <br>
Hanoi towers animation. Hanoi towers animation.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "hanoi.stk")> ../Src/test-stk -f hanoi.stk </A> <A expr=(run "hanoi.stk")> <font color=red>RUN</font> -f hanoi.stk </A>
<p><li> <p><li>
<b>queens.stk</b> <b>queens.stk</b>
<br> <br>
@ -158,7 +170,7 @@
puzzle starting with a given board configuration. puzzle starting with a given board configuration.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "queens.stk")> ../Src/test-stk -f queens.stk </A> <A expr=(run "queens.stk")> <font color=red>RUN</font> -f queens.stk </A>
<br> <br>
<u>Comment</u>: This code is a contribution of <b>Grant <u>Comment</u>: This code is a contribution of <b>Grant
Edwards</b> <tt>&lt;grante@rosemount.com)&gt;</tt> Edwards</b> <tt>&lt;grante@rosemount.com)&gt;</tt>
@ -171,7 +183,7 @@
faster. Have fun. faster. Have fun.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "stetris.stk")> ../Src/test-stk -f stetris.stk </A> <A expr=(run "stetris.stk")> <font color=red>RUN</font> -f stetris.stk </A>
<br> <br>
<u>Comment</u>: <u>Comment</u>:
This code is a contribution of <B>Harvey J. Stein</B> This code is a contribution of <B>Harvey J. Stein</B>
@ -184,7 +196,7 @@
board of four planes with four rows and four columns each. board of four planes with four rows and four columns each.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "ttt.stk")> ../Src/test-stk -f ttt.stk </A> <A expr=(run "ttt.stk")> <font color=red>RUN</font> -f ttt.stk </A>
<br> <br>
<u>Comment</u>: <u>Comment</u>:
This code is a contribution of <b>Edin "Dino" Hodzic</b> This code is a contribution of <b>Edin "Dino" Hodzic</b>
@ -200,7 +212,7 @@
This is a simple demo showing a repl loop in a console. This is a simple demo showing a repl loop in a console.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "console-demo.stk")> ../Src/test-stk -f console.stk </A> <A expr=(run "console-demo.stk")> <font color=red>RUN</font> -f console.stk </A>
<br> <br>
<u>Comment</u>: This demo is useful for Unix users only, since under <u>Comment</u>: This demo is useful for Unix users only, since under
Win32 <B>STk</B> is started with such a console. Win32 <B>STk</B> is started with such a console.
@ -211,7 +223,7 @@
This is a simple color palette written in STk. This is a simple color palette written in STk.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "colormap.stk")> ../Src/test-stk -f colormap.stk </A> <A expr=(run "colormap.stk")> <font color=red>RUN</font> -f colormap.stk </A>
<br> <br>
<u>Comment</u>: Note that this program is no more really useful since <u>Comment</u>: Note that this program is no more really useful since
<B>STk</B> offers now the function <tt>Tk:choose-color</tt> <B>STk</B> offers now the function <tt>Tk:choose-color</tt>
@ -223,7 +235,7 @@
This is a simple program which uses the STk font chooser. This is a simple program which uses the STk font chooser.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "stkfontsel.stk")> ../Src/test-stk -f stkfontsel.stk </A> <A expr=(run "stkfontsel.stk")> <font color=red>RUN</font> -f stkfontsel.stk </A>
<p><li> <p><li>
<b>small-ed.stk</b> <b>small-ed.stk</b>
@ -231,7 +243,7 @@
A small editor to create enhanced text A small editor to create enhanced text
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "small-ed.stk")> ../Src/test-stk -f small-ed.stk </A> <A expr=(run "small-ed.stk")> <font color=red>RUN</font> -f small-ed.stk </A>
<br> <br>
<u>Comment</u>: <u>Comment</u>:
This editor use a <I>ad-hoc</I> format for saving file and was This editor use a <I>ad-hoc</I> format for saving file and was
@ -246,9 +258,10 @@
variables (named a,b and c) Changing the value of one of variables (named a,b and c) Changing the value of one of
these vars (with a <tt><b>set!</b></tt> for instance) will these vars (with a <tt><b>set!</b></tt> for instance) will
redisplay its new value immediately. redisplay its new value immediately.
<br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "-load showvars.stk")> <A expr=(system (string-append "xterm -e " *interp* " -l showvars.stk &"))>
../Src/test-stk -load showvars.stk </A> <font color=red>RUN</font> -load showvars.stk </A>
<br> <br>
<p><li> <p><li>
@ -257,7 +270,7 @@
A simple demo of the inspector on Tk widgets A simple demo of the inspector on Tk widgets
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "inspector.stk")> ../Src/test-stk -f inspector.stk </A> <A expr=(run "inspector.stk")> <font color=red>RUN</font> -f inspector.stk </A>
<br> <br>
<u>Comment</u>: <u>Comment</u>:
<STRONG> Does not work with this version of <I>STk</I> <STRONG> Does not work with this version of <I>STk</I>
@ -270,7 +283,7 @@
A simple terminal emulator (a kind of xterm, but in a text widget). A simple terminal emulator (a kind of xterm, but in a text widget).
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "term.stk")> ../Src/test-stk -f term.stk </A> <A expr=(run "term.stk")> <font color=red>RUN</font> -f term.stk </A>
<br> <br>
<u>Comment</u>: Users of <b>Glibc2 (aka libc6, or RedHat 5.0 <u>Comment</u>: Users of <b>Glibc2 (aka libc6, or RedHat 5.0
users)</b>: This program has problems with new release of the users)</b>: This program has problems with new release of the
@ -314,7 +327,7 @@
demonstration in <b>STklos</b> demonstration in <b>STklos</b>
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "hello.stklos")> ../Src/test-stk -f hello.stklos </A> <A expr=(run "hello.stklos")> <font color=red>RUN</font> -f hello.stklos </A>
<p><li> <p><li>
<b>browse.stklos</b> <b>browse.stklos</b>
@ -323,7 +336,7 @@
demonstration in <b>STklos</b> demonstration in <b>STklos</b>
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "browse.stklos")> ../Src/test-stk -f browse.stklos </A> <A expr=(run "browse.stklos")> <font color=red>RUN</font> -f browse.stklos </A>
@ -332,7 +345,7 @@
A simple demo written in STklos. A simple demo written in STklos.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "stklos-demo.stklos")>../Src/test-stk -f stklos-demo.stklos</a> <A expr=(run "stklos-demo.stklos")><font color=red>RUN</font> -f stklos-demo.stklos</a>
<br> <br>
<u>Comment</u>: What is interesting in this demo is not what <u>Comment</u>: What is interesting in this demo is not what
it does, nothing specially fancy, but how it is easy to it does, nothing specially fancy, but how it is easy to
@ -344,7 +357,7 @@
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "stklos-demo2.stklos")> <A expr=(run "stklos-demo2.stklos")>
../Src/test-stk -f stklos-demo2.stklos</a> <font color=red>RUN</font> -f stklos-demo2.stklos</a>
<br> <br>
<u>Comment</u>: Here again, what is interesting in this demo is not what <u>Comment</u>: Here again, what is interesting in this demo is not what
it does, nothing specially fancy, but how it is easy to it does, nothing specially fancy, but how it is easy to
@ -355,7 +368,7 @@
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "classbrowse.stklos")> <A expr=(run "classbrowse.stklos")>
../Src/test-stk -f classbrowse.stklos</a> <font color=red>RUN</font> -f classbrowse.stklos</a>
<br> <br>
</ul> </ul>
@ -374,7 +387,7 @@
modified version by clicking the button <tt>"Rerun demo"</tt> modified version by clicking the button <tt>"Rerun demo"</tt>
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "widget.stk")> ../Src/test-stk -f widget.stk </A> <A expr=(run "widget.stk")> <font color=red>RUN</font> -f widget.stk </A>
<br> <br>
<u>Comment</u>: This demo illustrate only the simple widgets <u>Comment</u>: This demo illustrate only the simple widgets
(the ones of the Tk library). For a <i>composite widgets</i> (the ones of the Tk library). For a <i>composite widgets</i>
@ -389,7 +402,7 @@
itself a composition of various composite widget classes. itself a composition of various composite widget classes.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "filebox.stklos")> ../Src/test-stk -f filebox.stklos </A> <A expr=(run "filebox.stklos")> <font color=red>RUN</font> -f filebox.stklos </A>
<p><li> <p><li>
<b>stklos-widgets.stklos</b> <b>stklos-widgets.stklos</b>
@ -399,7 +412,7 @@
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "stklos-widgets.stklos")> <A expr=(run "stklos-widgets.stklos")>
../Src/test-stk -f stklos-widgets.stklos </A> <font color=red>RUN</font> -f stklos-widgets.stklos </A>
<br> <br>
<u>Comment</u>: This code is a contribution of <b>Drew Whitehouse</b> <u>Comment</u>: This code is a contribution of <b>Drew Whitehouse</b>
<TT>&lt;Drew.Whitehouse@anu.edu.au&gt</TT>. <TT>&lt;Drew.Whitehouse@anu.edu.au&gt</TT>.
@ -414,7 +427,7 @@
This is a simplistic calculator. This is a simplistic calculator.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "calc.stklos")>../Src/test-stk -f calc.stklos </A> <A expr=(run "calc.stklos")><font color=red>RUN</font> -f calc.stklos </A>
<p><li> <p><li>
<b>tkcolor.stklos</b> <b>tkcolor.stklos</b>
@ -428,7 +441,7 @@
background color. background color.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "tkcolor.stklos")>../Src/test-stk -f tkcolor.stklos </A> <A expr=(run "tkcolor.stklos")><font color=red>RUN</font> -f tkcolor.stklos </A>
<p><li> <p><li>
<b>amib.stklos</b> <b>amib.stklos</b>
@ -436,7 +449,7 @@
<B>A</B> <B>M</B>ini <B>I</B>nterface <B>B</B>uilder. <B>A</B> <B>M</B>ini <B>I</B>nterface <B>B</B>uilder.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "amib.stklos")> ../Src/test-stk -f amib.stklos </A> <A expr=(run "amib.stklos")> <font color=red>RUN</font> -f amib.stklos </A>
<br> <br>
<u>Comment</u>: The current version of AMIB allow you to: <u>Comment</u>: The current version of AMIB allow you to:
<ul> <ul>
@ -455,7 +468,7 @@
The STk web browser. You are probably using it while seeing these lines. The STk web browser. You are probably using it while seeing these lines.
<br> <br>
<u>Run with</u>: <u>Run with</u>:
<A expr=(run "S-scape.stklos")> ../Src/test-stk -f S-scape.stklos </A> <A expr=(run "S-scape.stklos")> <font color=red>RUN</font> -f S-scape.stklos </A>
</ul> </ul>
@ -463,7 +476,7 @@
<address><a href="mailto:eg@unice.fr">Erick Gallesio</a></address> <address><a href="mailto:eg@unice.fr">Erick Gallesio</a></address>
<!-- Created: Sun Mar 1 15:56:45 CET 1998 --> <!-- Created: Sun Mar 1 15:56:45 CET 1998 -->
<!-- hhmts start --> <!-- hhmts start -->
Last modified: Sat Sep 4 15:02:13 CEST 1999 Last modified: Mon Sep 13 19:59:47 CEST 1999
<!-- hhmts end --> <!-- hhmts end -->
</body> </body>
</html> </html>

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

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

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

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

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

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

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

4
Demos/console-demo.stk Normal file → Executable file
View File

@ -1,3 +1,5 @@
#!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$*"
;;;; console-demo.stk -- A simple demo for the console ;;;; console-demo.stk -- A simple demo for the console
;;;; ;;;;
;;;; Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr> ;;;; Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
@ -13,7 +15,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 22-Aug-1999 21:05 ;;;; Creation date: 22-Aug-1999 21:05
;;;; Last file update: 3-Sep-1999 18:56 (eg) ;;;; Last file update: 12-Sep-1999 23:29 (eg)

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

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

@ -1,4 +1,5 @@
#!/usr/local/bin/stk -f #!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;; ;;;;
;;;; Hanoi - Towers of Hanoi diversion ;;;; Hanoi - Towers of Hanoi diversion
;;;; ;;;;
@ -13,7 +14,7 @@
;;;; This software is provided ``AS IS'' without express or implied ;;;; This software is provided ``AS IS'' without express or implied
;;;; warranty. ;;;; warranty.
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Last file update: 3-Sep-1999 19:22 (eg) ;;;; Last file update: 13-Sep-1999 18:00 (eg)
;;;; This program is a rewriting in STk of a program found on the net. Original ;;;; 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) ;;;; author is Damon A Permezel (probably fubar!dap@natinst.com)

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

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

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

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

@ -1,4 +1,5 @@
#!/usr/local/bin/stk -load #!/bin/sh
:;exec /usr/local/bin/stk -load "$0" "$@"
;;;; ;;;;
;;;; m c - s e r v e r . s t k -- A simple server which accept ;;;; m c - s e r v e r . s t k -- A simple server which accept
;;;; multiple client connections ;;;; multiple client connections
@ -16,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr] ;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 23-Jul-1996 09:00 ;;;; Creation date: 23-Jul-1996 09:00
;;;; Last file update: 3-Sep-1999 18:58 (eg) ;;;; Last file update: 13-Sep-1999 18:01 (eg)
(require "posix") (require "posix")
(require "socket") (require "socket")

View File

@ -1,6 +1,7 @@
#!/usr/local/bin/stk -f #!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
; -* Lisp -*- ; -* Scheme -*-
; Yet another "my first STk program" type thing. This one is the "8 ; Yet another "my first STk program" type thing. This one is the "8
; queens" puzzle. You try to figure out how to place 8 queens on a ; queens" puzzle. You try to figure out how to place 8 queens on a

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

@ -1,4 +1,7 @@
#!/usr/local/bin/stk -f #!/bin/sh
:; exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;;
;;;; s e r v e r . s t k -- A simple sever ;;;; s e r v e r . s t k -- A simple sever
;;;; ;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr> ;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
@ -14,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr] ;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 4-Feb-1995 18:17 ;;;; Creation date: 4-Feb-1995 18:17
;;;; Last file update: 4-Sep-1999 15:32 (eg) ;;;; Last file update: 12-Sep-1999 23:36 (eg)
(define s (make-server-socket)) (define s (make-server-socket))
(define p (run-process ; define a var to avoid GC problems (define p (run-process ; define a var to avoid GC problems
@ -24,8 +27,6 @@
(dynamic-wind (dynamic-wind
;; Init: Launch an xterm with telnet running on the s listening port and connect ;; Init: Launch an xterm with telnet running on the s listening port and connect
(lambda () (lambda ()
(run-process "xterm" "-e" "telnet" "localhost"
(number->string (socket-port-number s)))
(socket-accept-connection s) (socket-accept-connection s)
(format (socket-output s) "\nWelcome on the socket REPL.\n\n> ") (format (socket-output s) "\nWelcome on the socket REPL.\n\n> ")
(flush (socket-output s))) (flush (socket-output s)))

View File

@ -18,7 +18,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 9-Aug-1993 22:06 ;;;; Creation date: 9-Aug-1993 22:06
;;;; Last file update: 3-Sep-1999 19:23 (eg) ;;;; Last file update: 13-Sep-1999 20:01 (eg)
(define (show-vars w . args) (define (show-vars w . args)
(catch (destroy w)) (catch (destroy w))
@ -51,5 +51,6 @@
(define b '(1 2 (a b d) x 1)) (define b '(1 2 (a b d) x 1))
(define c "A string") (define c "A string")
(show-vars '.test 'a 'b 'c) (show-vars '.test 'a 'b 'c)
(format #t "Try to modify value of displayed variables with set!\n") (format #t
"\n***\n*** Try to modify value of displayed variables with set!\n***\n\n")

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

@ -1,4 +1,6 @@
#!/usr/local/bin/stk -f #!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;; s m a l l - e d . s t k -- A small editor to create enhanced ;;;; s m a l l - e d . s t k -- A small editor to create enhanced
;;;; text (used for Help page construction) ;;;; text (used for Help page construction)
;;;; ;;;;
@ -15,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr] ;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 6-Dec-1993 17:25 ;;;; Creation date: 6-Dec-1993 17:25
;;;; Last file update: 3-Sep-1999 18:58 (eg) ;;;; Last file update: 13-Sep-1999 18:02 (eg)
(require "editor") (require "editor")

6
Demos/stkfontsel.stk Normal file → Executable file
View File

@ -1,3 +1,7 @@
#!/bin/sh
:; exec /usr/local/bin/stk -f "$0" "$@"
;;;;
;;;;
;;;; s t k f o n t s e l . s t k l o s -- A demo of the font chooser ;;;; 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> ;;;; Copyright © 1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
@ -13,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 25-Apr-1999 19:35 ;;;; Creation date: 25-Apr-1999 19:35
;;;; Last file update: 3-Sep-1999 18:59 (eg) ;;;; Last file update: 12-Sep-1999 23:37 (eg)
(require "font-chooser") (require "font-chooser")

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

@ -1,4 +1,5 @@
#!/usr/local/bin/stk -f #!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;; ;;;;
;;;; s t k l o s - d e m o . s t k -- A demo which use some STklos classes ;;;; s t k l o s - d e m o . s t k -- A demo which use some STklos classes
;;;; ;;;;
@ -15,7 +16,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 24-Aug-1993 19:55 ;;;; Creation date: 24-Aug-1993 19:55
;;;; Last file update: 3-Sep-1999 19:00 (eg) ;;;; Last file update: 13-Sep-1999 18:03 (eg)
(require "Tk-classes") (require "Tk-classes")

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

@ -1,4 +1,6 @@
#!/usr/local/bin/stk -f #!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;; ;;;;
;;;; s t k l o s - d e m o 2 . s t k -- A demo which use some STklos classes ;;;; s t k l o s - d e m o 2 . s t k -- A demo which use some STklos classes
;;;; ;;;;
@ -15,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 24-Aug-1993 19:55 ;;;; Creation date: 24-Aug-1993 19:55
;;;; Last file update: 3-Sep-1999 19:00 (eg) ;;;; Last file update: 13-Sep-1999 18:03 (eg)
(require "Tk-classes") (require "Tk-classes")

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

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

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

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

View File

@ -1,6 +1,7 @@
# #
# Makefile for Doc/Extension # Makefile for Doc/Extension
# #
include ../../config.make
SRC = Extending.tex SRC = Extending.tex
@ -9,6 +10,10 @@ all: dvi ps
dvi: Extending.dvi dvi: Extending.dvi
ps: Extending.ps ps: Extending.ps
install: ps
$(CP) Extending.ps $(DOC_DIR)
Extending.dvi: $(SRC) Extending.dvi: $(SRC)
echo -n > Extending.ind echo -n > Extending.ind
latex Extending; makeindex Extending; bibtex Extending; latex Extending; makeindex Extending; bibtex Extending;

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -14,17 +14,17 @@
# #
# Author: Erick Gallesio [eg@unice.fr] # Author: Erick Gallesio [eg@unice.fr]
# Creation date: 21-Oct-1994 11:25 # Creation date: 21-Oct-1994 11:25
# Last file update: 3-Sep-1999 21:22 (eg) # Last file update: 12-Sep-1999 20:31 (eg)
include ../config.make include ../config.make
MAN1_DIR=$(mandir)/man1 MAN1_DIR=$(mandir)/man1
MANN_DIR=$(mandir)/mann MANN_DIR=$(mandir)/mann
DOC_DIR=$(prefix)/doc/stk-$(VERSION)
DIRS=Extension Reference STklos+Tk Manual Isotas96 DIRS=Extension Reference STklos+Tk Manual Isotas96
install: install.man install: install.man install.ps
all: dvi ps all: dvi ps
@ -41,6 +41,11 @@ ps:
install.man: install.man:
(cd Manual; make install.man) (cd Manual; make install.man)
install.ps:
-if [ ! -d $(DOC_DIR) ] ; then mkdir -p $(DOC_DIR); fi
(cd Extension; make install DOC_DIR=$(DOC_DIR))
(cd Reference; make install DOC_DIR=$(DOC_DIR))
clean: clean:
for i in $(DIRS) ;do \ for i in $(DIRS) ;do \
(cd $$i; $(MAKE) clean); \ (cd $$i; $(MAKE) clean); \

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:?? % Creation date: ??-Nov-1993 ??:??
% Last file update: 21-Jan-1996 18:29 % Last file update: 27-Sep-1999 14:40 (eg)
% %
When {\stk} detects that a \var{tk-command} must be called, parameters are When {\stk} detects that a \var{tk-command} must be called, parameters are
@ -109,7 +109,7 @@ arrows for example), the scrollbar is updated by calling it's
associated closure. Tk library passes position informations to associated closure. Tk library passes position informations to
scrolling closures. This informations are the parameters of the scrolling closures. This informations are the parameters of the
closure. Hereafter is an example implementing a text widget with a closure. Hereafter is an example implementing a text widget with a
scrollbar (see the help pages for details): scrollbar (see the help pages for details and \ref{help}):
\begin{scheme} \begin{scheme}
(text '.txt :yscrollcommand (lambda l (apply .scroll 'set l))) (text '.txt :yscrollcommand (lambda l (apply .scroll 'set l)))
(scrollbar '.scroll :command (lambda l (apply .txt 'yview l))) (scrollbar '.scroll :command (lambda l (apply .txt 'yview l)))

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:?? % Creation date: ??-Nov-1993 ??:??
% Last file update: 20-Apr-1998 11:54 % Last file update: 27-Sep-1999 14:42 (eg)
% %
\newcommand{\schglob}[1]{*#1*} \newcommand{\schglob}[1]{*#1*}
@ -87,9 +87,9 @@ The following symbols are defined only when Tk is loaded:
\item {\tt\schglob{help-path}}\schindex{help, \item {\tt\schglob{help-path}}\schindex{help,
getting}\schindex{\schglob{help-path}} must contain a list of getting}\schindex{\schglob{help-path}} must contain a list of
strings. Each string is taken as a directory path name in which strings. Each string is taken as a directory path name in which
documentation files are searched. This variable can be set documentation files are searched by the command \var{help}\ref{help}.
automatically from the {\tt STK\_HELP\_PATH} shell variable. See This variable can be set automatically from the {\tt STK\_HELP\_PATH}
{\tt stk(1)} for more details. shell variable. See {\tt stk(1)} for more details.
\item {\tt\schglob{image-path}}\schindex{\schglob{image-path}} must contain \item {\tt\schglob{image-path}}\schindex{\schglob{image-path}} must contain
a list of strings. Each string is taken as a directory path name in which a list of strings. Each string is taken as a directory path name in which

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: 22-May-1994 22:13 % Creation date: 22-May-1994 22:13
% Last file update: 5-Jun-1999 14:48 % Last file update: 18-Sep-1999 15:21 (eg)
% %
\section{Introduction} \section{Introduction}
@ -113,7 +113,7 @@ For instance,
\begin{scheme} \begin{scheme}
(class-slots A) \lev (a) (class-slots A) \lev (a)
(class-slots E) \lev (a e c) (class-slots E) \lev (a e c)
(class-slots F) \lev (d a b c f) (class-slots F) \lev (b e c d a f)
\end{scheme} \end{scheme}
\begin{note} \begin{note}
@ -311,10 +311,10 @@ For instance, the following expression
permits to set the angle of the {\tt c} complex number. This expression permits to set the angle of the {\tt c} complex number. This expression
conducts, in fact, to the evaluation of the following expression conducts, in fact, to the evaluation of the following expression
\begin{scheme} \begin{scheme}
((lambda o m) ((lambda (o a)
(let ((m (slot-ref o 'm))) (let ((m (slot-ref o 'm)))
(slot-set! o 'r (* m (cos a))) (slot-set! o 'r (* m (cos a)))
(slot-set! o 'i (* m (sin a)))) (slot-set! o 'i (* m (sin a)))))
c 3) c 3)
\end{scheme} \end{scheme}
A more complete example is given below: A more complete example is given below:
@ -494,7 +494,7 @@ each parameter can use a specializer. In this case, the parameter list is scanne
from left to right to determine the applicability of a method. Suppose we declare from left to right to determine the applicability of a method. Suppose we declare
now now
\begin{scheme} \begin{scheme}
(define-method M ((a <integer>) (b <number>)) 'integer-number) (define-method M ((a <integer>) (b <integer>)) 'integer-integer)
(define-method M ((a <integer>) (b <real>)) 'integer-real) (define-method M ((a <integer>) (b <real>)) 'integer-real)
(define-method M (a (b <number>)) 'top-number) (define-method M (a (b <number>)) 'top-number)
\end{scheme} \end{scheme}

View File

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

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: 21-Dec-1994 12:05 % Creation date: 21-Dec-1994 12:05
% Last file update: 27-Jun-1998 10:12 % Last file update: 22-Sep-1999 11:50 (eg)
% %
\section{Introduction} \section{Introduction}
@ -230,12 +230,23 @@ document is available at
{\tt file://swiss-ftp.ai.mit.edu/pub/scm/HTML/r4rs\_toc.html} {\tt file://swiss-ftp.ai.mit.edu/pub/scm/HTML/r4rs\_toc.html}
\end{quote} \end{quote}
\subsection{The Scheme Repository} \subsection{Web sites}
The main site where you can find (many) informations about Scheme is The most up to date general site on Scheme is located at
located in the University of Indiana. The Scheme repository\index{Scheme www.schemers.org\index{Schemers.org}. This site contains informations
Repository} is maintained by David Eby. The repository currently consists and links about
of the following areas: \begin{itemize}
\item textbooks on Scheme, tutorials and standards
\item various implementations of the language as well as environments for Scheme
\item SRFI (Scheme Request For Implementation)
\item events related to Scheme programming
\item and much more ...
\end{itemize}
Another important site is the Scheme repository\index{Scheme
Repository}. Hopelessly, this site is no more maintained, but its
content is rich enough to spend some time on it. The repository
consists of the following areas:
\begin{itemize} \begin{itemize}
\item Lots of scheme code meant for benchmarking, library/support, research, education, and fun. \item Lots of scheme code meant for benchmarking, library/support, research, education, and fun.
\item On-line documents: Machine readable standards documents, standards proposals, various Scheme-related tech reports, conference papers, mail archives, etc. \item On-line documents: Machine readable standards documents, standards proposals, various Scheme-related tech reports, conference papers, mail archives, etc.
@ -245,7 +256,6 @@ of the following areas:
\item Utilities (e.g., Schemeweb, SLaTeX). \item Utilities (e.g., Schemeweb, SLaTeX).
\item Extraneous stuff, extensions, etc. \item Extraneous stuff, extensions, etc.
\end{itemize} \end{itemize}
You can access the Scheme repository with You can access the Scheme repository with
{\tt {\tt
\begin{itemize} \begin{itemize}
@ -253,7 +263,6 @@ You can access the Scheme repository with
\item http://www.cs.indiana.edu/scheme-repository/SRhome.html \item http://www.cs.indiana.edu/scheme-repository/SRhome.html
\end{itemize} \end{itemize}
} }
The Scheme Repository is mirrored in Europe: The Scheme Repository is mirrored in Europe:
{\tt {\tt
\begin{itemize} \begin{itemize}
@ -262,6 +271,7 @@ The Scheme Repository is mirrored in Europe:
\item ftp.informatik.uni-muenchen.de:/pub/comp/programming/languages/scheme/scheme-repository \item ftp.informatik.uni-muenchen.de:/pub/comp/programming/languages/scheme/scheme-repository
\end{itemize} \end{itemize}
} }
\subsection{Usenet newsgroup and other addresses} \subsection{Usenet newsgroup and other addresses}
There is a usenet newsgroup about the Scheme Programming language: {\tt There is a usenet newsgroup about the Scheme Programming language: {\tt
@ -277,3 +287,8 @@ at MIT
\item {\tt http://www.ai.mit.edu/projects/su/su.html} is the Scheme Underground \item {\tt http://www.ai.mit.edu/projects/su/su.html} is the Scheme Underground
web page web page
\end{itemize} \end{itemize}
%%% Local Variables:
%%% mode: latex
%%% TeX-master: "manual"
%%% End:

View File

@ -1,5 +1,7 @@
# Makefile for Manual building # Makefile for Manual building
include ../../config.make
TEX= manual.tex commands.tex Reference1.tex Reference2.tex \ TEX= manual.tex commands.tex Reference1.tex Reference2.tex \
Appendix-A.tex Appendix-B.tex Appendix-C.tex Appendix-D.tex Appendix-A.tex Appendix-B.tex Appendix-C.tex Appendix-D.tex
@ -8,6 +10,9 @@ all: dvi ps
dvi: manual.dvi dvi: manual.dvi
ps: manual.ps ps: manual.ps
install: ps
$(CP) manual.ps $(DOC_DIR)
manual.dvi: bibli $(TEX) manual.dvi: bibli $(TEX)
echo -n > index.tex echo -n > index.tex
latex manual.tex latex manual.tex

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:?? % Creation date: ??-Nov-1993 ??:??
% Last file update: 31-Aug-1999 13:04 (eg) % Last file update: 18-Sep-1999 15:08 (eg)
% %
\section*{Introduction} \section*{Introduction}
@ -104,7 +104,7 @@ This kind of comment extends to the end of the line (as described in \rrrr).
{\tt \sharpsign{\em n}\sharpsign} syntax (see below). The scope of {\tt \sharpsign{\em n}\sharpsign} syntax (see below). The scope of
the label is the expression being read by the outermost \ide{read}. the label is the expression being read by the outermost \ide{read}.
\item[\tt\sharpsign{\em n}=] is used to reference a some object \item[\tt\sharpsign{\em n}\sharpsign] is used to reference a some object
labeled by a {\tt \sharpsign{\em n}=} syntax; that is, labeled by a {\tt \sharpsign{\em n}=} syntax; that is,
{\tt \sharpsign{\em n}\sharpsign} represents a pointer to the object {\tt \sharpsign{\em n}\sharpsign} represents a pointer to the object
labeled exactly by {\tt \sharpsign{\em n}=}. For instance, the object labeled exactly by {\tt \sharpsign{\em n}=}. For instance, the object
@ -437,7 +437,7 @@ have been deleted. The predicate used to test the presence of \var{obj} in
Returns the last pair of \var{list}\footnote{\ide{Last-pair} was a standard Returns the last pair of \var{list}\footnote{\ide{Last-pair} was a standard
procedure in {\rthree}.}. procedure in {\rthree}.}.
\begin{scheme} \begin{scheme}
(last-pair '(1 2 3)) \lev 3 (last-pair '(1 2 3)) \lev (3)
(last-pair '(1 2 . 3)) \lev (2 . 3) (last-pair '(1 2 . 3)) \lev (2 . 3)
\end{scheme} \end{scheme}
\end{entry} \end{entry}
@ -1050,12 +1050,12 @@ the port is given by the user).
specifying the command to execute prefixed with the string {\tt specifying the command to execute prefixed with the string {\tt
"|~"}. Specification of a pipe port can occur everywhere a file "|~"}. Specification of a pipe port can occur everywhere a file
name is needed. name is needed.
\item Virtual ports creation needs that the basic I/O functions are \item Virtual ports are created by supplying basic I/O functions at
at the port creation time. This functions will be used to simulate port creation time. These functions will be used to simulate low
low level accesses a ``virtual device''. This kind of port is level accesses to a ``virtual device''. This kind of port is
particularly convenient for reading or writing in a graphical window particularly convenient for reading or writing in a graphical
as if it was a file. Once virtual port is created, it can be accessed window as if it was a file. Once a virtual port is created, it can
as a normal port with the standard Scheme primitives. be accessed as a normal port with the standard Scheme primitives.
\end{itemize} \end{itemize}
@ -1281,18 +1281,18 @@ output string \var{port}.
\saut \saut
Returns a virtual port using the \var{getc} procedure to read a 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 character from the port, \var{readyp} to know if there is any data to
the port, \var{eofp} to know if the end of file is reached on the port read from the port, \var{eofp} to know if the end of file is reached
and finally \var{close} to close the port. All theses procedure takes on the port and finally \var{close} to close the port. All theses
one parameter which is the port from which the input is done. procedure takes one parameter which is the port from which the input
\var{Open-input-virtual} accepts also the special value \schfalse{} for is done. \var{Open-input-virtual} accepts also the special value
the I/O procedures with the following conventions: \schfalse{} for the I/O procedures with the following conventions:
\begin{itemize} \begin{itemize}
\item if \var{getc} or \var{eofp} is \schfalse{} any attempt to read \item if \var{getc} or \var{eofp} is \schfalse{} any attempt to read
the virtual port will an eof object; the virtual port will return an eof object;
\item if \var{readyp} is \schfalse{}, the file will always be ready \item if \var{readyp} is \schfalse{}, the file will always be ready
for reading; for reading;
\item if \var{clos} is \schfalse{}, no action is done when the port is \item if \var{close} is \schfalse{}, no action is done when the port is
closed. closed.
\end{itemize} \end{itemize}
@ -1424,7 +1424,7 @@ returned by \ide{write*} is undefined.
(l2 '(3 4)) (l2 '(3 4))
(l3 '(5 6))) (l3 '(5 6)))
(append! l1 l2 l3) (append! l1 l2 l3)
(list l1 l2 l3)) \ev \textit{writes} \verb+((1 2 . #0=(3 4 . #1=(5 6))) #0# #1#)+ (write* (list l1 l2 l3))) \ev \textit{writes} \verb+((1 2 . #0=(3 4 . #1=(5 6))) #0# #1#)+
\end{scheme} \end{scheme}
\end{entry} \end{entry}
@ -1604,20 +1604,6 @@ Closes \var{port}. If \var{port} denotes a string port, further
reading or writing on this port is disallowed. reading or writing on this port is disallowed.
\end{entry} \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}{% \begin{entry}{%
\proto{port-closed?}{ port}{procedure}} \proto{port-closed?}{ port}{procedure}}
\saut \saut

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: ??-Nov-1993 ??:?? % Creation date: ??-Nov-1993 ??:??
% Last file update: 16-Aug-1999 20:21 % Last file update: 27-Sep-1999 15:24 (eg)
% %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@ -155,6 +155,37 @@ Returns the widget name of \var{widget} as a symbol.
\end{scheme} \end{scheme}
\end{entry} \end{entry}
\begin{entry}{%
\proto{tk-get}{ widget opt}{procedure}}
\saut
Returns the value of the widget option \var{opt} of \var{widget}.
\begin{scheme}
(begin
(label '.lab :text "Hello" :bd 3)
(cons (tk-get .lab :bd) (tk-get .lab :text)))
\lev (3 . "Hello")
\end{scheme}
See the online documentation for all the options provided by the Tk widgets.
(see \ref{help}).
\end{entry}
\begin{entry}{%
\proto{tk-set!}{ widget opt value}{procedure}}
\saut
Sets the value of the widget option \var{opt} of \var{widget} to the
given \var{value}.
\begin{scheme}
(begin
(label '.lab :text "Hello")
(tk-set! .lab :text "Hello, world!")
(tk-get .lab :text))
\lev "Hello, world!"
\end{scheme}
See the online documentation for all the options provided by the Tk widgets.
(see \ref{help}).
\end{entry}
\begin{entry}{ \begin{entry}{
\proto{set-widget-data!}{ widget expr}{procedure}} \proto{set-widget-data!}{ widget expr}{procedure}}
\saut \saut
@ -273,6 +304,16 @@ in all the \texttt{export} clauses.
The result of \var{export} is undefined. The result of \var{export} is undefined.
\end{entry} \end{entry}
\begin{entry}{%
\proto{export-all-symbols}{ } {procedure}}
\saut
Exports all the symbols defined in the current module.
The result of \var{export-all-symbols} is undefined.
\end{entry}
\begin{entry}{% \begin{entry}{%
\proto{import}{ \hyperi{module} \hyperii{module}\ldots} {syntax}} \proto{import}{ \hyperi{module} \hyperii{module}\ldots} {syntax}}
@ -1613,6 +1654,13 @@ option uses the external command {\tt rsh}. The shell variable {\tt
PATH} must be correctly set for accessing it without specifying its PATH} must be correctly set for accessing it without specifying its
abolute path. abolute path.
\item {\tt :fork} must be followed by a boolean value. This value
specifies if a \emph{fork} system call must be done before running
the process. If the process is run without \emph{fork} the Scheme
program is lost. This feature mimics the ``exec'' primitive of the
Unix shells. By default, the process a fork is executed before
running the process (i.e. {\tt :fork} is \schtrue). This options
works on Unix implementations only.
\end{itemize} \end{itemize}
The following example launches a process which execute the The following example launches a process which execute the
Unix command {\tt ls} with the arguments {\tt -l} and {\tt Unix command {\tt ls} with the arguments {\tt -l} and {\tt

View File

@ -3,7 +3,7 @@
% %
% Author: Erick Gallesio [eg@unice.fr] % Author: Erick Gallesio [eg@unice.fr]
% Creation date: 16-Dec-1997 14:00 % Creation date: 16-Dec-1997 14:00
% Last file update: 17-May-1999 00:07 % Last file update: 27-Sep-1999 15:30 (eg)
% %
@ -770,6 +770,28 @@ of \var{symbol}. Symbols are searched for in the current environment.
\end{scheme} \end{scheme}
\end{entry} \end{entry}
\begin{entry}{%
\proto{apropos}{ symbol}{ procedure}}
\saut
\ide{Apropos} returns a list of symbol whose print name contains the characters
of \var{symbol}. Symbols are searched for in the current environment.
\begin{scheme}
(apropos 'cadd) \lev (caddar caddr cadddr)
\end{scheme}
\end{entry}
\begin{entry}{%
\proto{help}{}{ procedure}}
\saut
\label{help}\schindex{help, getting}
\ide{help} pops a graphical help window giving acces to the online
documentation.
\begin{note}
Tk must be initialized to use \ide{inspect}.
\end{note}
\end{entry}
\begin{entry}{% \begin{entry}{%
\proto{inspect}{ obj}{ procedure}} \proto{inspect}{ obj}{ procedure}}
\saut % \saut %
@ -787,7 +809,7 @@ Tk must be initialized to use \ide{inspect}.
\begin{figure} \begin{figure}
\centerline{\psfig{figure={Inspector.ps}}} \centerline{\psfig{figure={Inspector.ps}}}
\caption{A view of the Inspector} \caption{A View of the Inspector}
\end{figure} \end{figure}
\end{entry} \end{entry}

Binary file not shown.

File diff suppressed because it is too large Load Diff

View File

@ -16,7 +16,7 @@
* *
* Author: Erick Gallesio [eg@kaolin.unice.fr] * Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 17-Jan-1994 17:49 * Creation date: 17-Jan-1994 17:49
* Last file update: 3-Sep-1999 20:20 (eg) * Last file update: 14-Sep-1999 14:15 (eg)
*/ */
#include <stk.h> #include <stk.h>
@ -95,14 +95,17 @@ unsigned long sxhash(SCM obj)
case tc_integer: case tc_integer:
case tc_bignum: return (unsigned long) STk_integer_value_no_overflow(obj); case tc_bignum: return (unsigned long) STk_integer_value_no_overflow(obj);
case tc_flonum: return (unsigned long) FLONM(obj); case tc_flonum: return (unsigned long) FLONM(obj);
case tc_symbol: /* For some reasons case tc_symbol: if (CELLINFO(obj) & CELL_INFO_UNINTERNED)
* return (unsigned long) obj; /* Interned symbol. Work on the interned one
* which is correct, yiels worse results than the * to have the same hash value
* following code. Perhaps, we have a better */
*repartion by using hashing on the chars. Weird! obj = Intern(PNAME(obj));
/* For some reasons, returning just obj as an unsigned
* long, which is correct, yields worse results than
* the following code.
*/ */
return HASH_WORD(0, (unsigned long) obj); return HASH_WORD(0, (unsigned long) obj);
return HashString(PNAME(obj));
case tc_keyword: return HashString(KEYVAL(obj)); case tc_keyword: return HashString(KEYVAL(obj));
case tc_string: return HashString(CHARS(obj)); case tc_string: return HashString(CHARS(obj));
case tc_vector: h = 0; case tc_vector: h = 0;
@ -116,8 +119,7 @@ unsigned long sxhash(SCM obj)
* object as a key. Note that returning the type * object as a key. Note that returning the type
* works even if we have not COMPACT_SMALL_CST (as far as * works even if we have not COMPACT_SMALL_CST (as far as
* I know, nobody undefine it). In this case SMALL_CSTP * I know, nobody undefine it). In this case SMALL_CSTP
* always return FALSE. * always return FALSE. */
*/
return (SMALL_CSTP(obj)) ? (unsigned long) obj: return (SMALL_CSTP(obj)) ? (unsigned long) obj:
(unsigned long) TYPE(obj); (unsigned long) TYPE(obj);
} }

View File

@ -932,6 +932,9 @@ static void ImgXpmGetPixmapFromData(interp, masterPtr, instancePtr)
instancePtr->tkwin, Tk_GetUid("black")); instancePtr->tkwin, Tk_GetUid("black"));
} }
} }
#if defined(STk_CODE) && defined(WIN32)
else colors[i].colorPtr = NULL;
#endif
} else { } else {
colors[i].colorPtr = Tk_GetColor(interp, colors[i].colorPtr = Tk_GetColor(interp,
instancePtr->tkwin, Tk_GetUid("black")); instancePtr->tkwin, Tk_GetUid("black"));

View File

@ -15,7 +15,7 @@
* *
* Author: Erick Gallesio [eg@kaolin.unice.fr] * Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: ??-???-1994 ??:?? * Creation date: ??-???-1994 ??:??
* Last file update: 3-Sep-1999 20:22 (eg) * Last file update: 14-Sep-1999 15:24 (eg)
* *
* *
* The implementation for Win32 is a contribution of people from Grammatech * The implementation for Win32 is a contribution of people from Grammatech
@ -101,6 +101,10 @@ static char key_err[] = ":error";
static char key_wit[] = ":wait"; static char key_wit[] = ":wait";
static char key_hst[] = ":host"; static char key_hst[] = ":host";
static char key_hide[] = ":hide"; static char key_hide[] = ":hide";
#ifndef WIN32
static char key_fork[] = ":fork";
#endif
#if defined(SIGCHLD) && !defined(HPUX) #if defined(SIGCHLD) && !defined(HPUX)
# define USE_SIGCHLD 1 /* What's the problem with HP? */ # define USE_SIGCHLD 1 /* What's the problem with HP? */
@ -635,14 +639,14 @@ static PRIMITIVE run_process(SCM l, int len)
static PRIMITIVE run_process(SCM l, int len) static PRIMITIVE run_process(SCM l, int len)
{ {
SCM proc, tmp, redirection[3]; SCM proc, tmp, redirection[3];
int pid, i, argc, waiting, hidden; int pid, i, argc, waiting, hidden, do_fork;
struct process_info *info; struct process_info *info;
char host[100], msg[256], **argv, **argv_start; char host[100], msg[256], **argv, **argv_start;
/* Initializations */ /* Initializations */
int pipes[3][2]; int pipes[3][2];
argc = 0; waiting = FALSE; hidden = FALSE; argc = 0; waiting = FALSE; hidden = FALSE; do_fork = TRUE;
argv_start = (char**)must_malloc((len+3)*sizeof(char *)); /* 3= NULL+rsh+host */ argv_start = (char**)must_malloc((len+3)*sizeof(char *)); /* 3= NULL+rsh+host */
argv = argv_start + 2; argv = argv_start + 2;
@ -691,6 +695,13 @@ static PRIMITIVE run_process(SCM l, int len)
hidden = (CAR(l) == Truth); hidden = (CAR(l) == Truth);
} }
else if (STk_eqv(tmp, STk_makekey(key_fork)) == Truth) {
/* :fork option processing */
if (NBOOLEANP(CAR(l)))
cannot_run(pipes, argv_start, "boolean expected. It was", CAR(l));
do_fork = (CAR(l) == Truth);
}
else { else {
/* :input, :output, :error option processing */ /* :input, :output, :error option processing */
if (STk_eqv(tmp, STk_makekey(key_inp)) == Truth) i = 0; else if (STk_eqv(tmp, STk_makekey(key_inp)) == Truth) i = 0; else
@ -777,9 +788,10 @@ static PRIMITIVE run_process(SCM l, int len)
/* Build a process object */ /* Build a process object */
proc = make_process(); proc = make_process();
info = PROCESS(proc); info = PROCESS(proc);
pid = do_fork? fork(): 0;
/* Fork another process */ /* Fork another process */
switch (pid = fork()) { switch (pid) {
case -1: cannot_run(pipes,argv,"can't create child process", NIL); case -1: cannot_run(pipes,argv,"can't create child process", NIL);
case 0: /* Child */ case 0: /* Child */
for(i = 0; i < 3; i++) { for(i = 0; i < 3; i++) {

View File

@ -14,7 +14,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr] ;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: ??-Sep-1993 ??:?? ;;;; Creation date: ??-Sep-1993 ??:??
;;;; Last file update: 3-Sep-1999 19:52 (eg) ;;;; Last file update: 14-Sep-1999 21:50 (eg)
;;;; ;;;;
;;;============================================================================== ;;;==============================================================================
@ -217,13 +217,14 @@
(let ((var #f) (count #f) (result #f)) (let ((var #f) (count #f) (result #f))
(case (length binding) (case (length binding)
(2 (set! var (car binding)) (2 (set! var (car binding))
(set! count (cadr binding))) (set! count (cadr binding))
(set! result (make-undefined)))
(3 (set! var (car binding)) (3 (set! var (car binding))
(set! count (cadr binding)) (set! count (cadr binding))
(set! result (caddr binding))) (set! result (caddr binding)))
(else (error "dotimes: bad binding construct: ~S" binding))) (else (error "dotimes: bad binding construct: ~S" binding)))
`(do ((,var 0 (+ ,var 1))) `(do ((,var 0 (+ ,var 1)))
((= ,var ,count) ,result) ((>= ,var ,count) ,result)
,@body)) ,@body))
;; binding is ill-formed ;; binding is ill-formed
(error "dotimes: binding is not a list: ~S" binding))) (error "dotimes: binding is not a list: ~S" binding)))

View File

@ -16,13 +16,13 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 30-Aug-1999 16:26 (eg) ;;;; Creation date: 30-Aug-1999 16:26 (eg)
;;;; Last file update: 3-Sep-1999 19:54 (eg) ;;;; Last file update: 27-Sep-1999 14:12 (eg)
(require "defsyntax") (require "defsyntax")
(define-syntax cond-expand (define-syntax cond-expand
(syntax-rules ( and or not else srfi-0 srfi-2 srfi-6 srfi-8 ) (syntax-rules ( and or not else srfi-0 srfi-2 srfi-6 srfi-8 srfi-9)
((cond-expand) (error "Unfulfilled cond-expand")) ((cond-expand) (error "Unfulfilled cond-expand"))
((cond-expand (else body ...)) ((cond-expand (else body ...))
(begin body ...)) (begin body ...))
@ -62,6 +62,10 @@
((cond-expand (srfi-8 body ...) more-clauses ...) ((cond-expand (srfi-8 body ...) more-clauses ...)
(begin body ...)) (begin body ...))
;; SRFI 9 -- RECORDS
((cond-expand (srfi-9 body ...) more-clauses ...)
(begin body ...))
((cond-expand (feature-id body ...) more-clauses ...) ((cond-expand (feature-id body ...) more-clauses ...)
(cond-expand more-clauses ...)))) (cond-expand more-clauses ...))))

96
Lib/srfi-9.stk Normal file
View File

@ -0,0 +1,96 @@
;;;;
;;;; srfi-9.stk -- SRFI-9 (Records)
;;;;
;;;; 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: 27-Sep-1999 13:06 (eg)
;;;; Last file update: 27-Sep-1999 14:21 (eg)
;;;;
(require "stklos")
(select-module Scheme)
(import STklos)
;;;
;;; Class <record>
;;;
;;; This class is only used for printing records as #[record ...]
;;;
(define-class <record> () ())
(define-method write-object ((x <record>) port)
(format #t "#[record ~A ~A]" (class-name (class-of x)) (address-of x)))
;;;
;;; Implementation of DEFINE-RECORD-TYPE
;;;
(define-macro (define-record-type type-name constructor predicate . fields)
(define (%make-record-fields fields)
(map (lambda (x)
(case (length x)
((2) (list (car x) :getter (cadr x)))
((3) (list (car x) :getter (cadr x) :setter (caddr x)))
(else (error "define-record-type: bad field specification ~S" x))))
fields))
(define (%make-record-constructor constructor class)
(if (not (every symbol? constructor))
(error "define-record-type: bad constructor ~S" constructor))
(let ((name (car constructor))
(fields (cdr constructor)))
`(lambda ,fields
(let ((res (make ,class)))
,@(map (lambda (x) `(slot-set! res ',x ,x)) fields)
res))))
;;;
;;; Body of define-record-type starts here
;;;
(let ((symb(gensym "x")))
`(begin
;; Define a class for the new record
(define-class ,type-name (<record>)
,(%make-record-fields fields))
;; Define the accessor function
(define ,(car constructor)
,(%make-record-constructor constructor type-name))
;; Define the predicate as a pair of methods
(define-method ,predicate ((,symb ,type-name)) #t)
(define-method ,predicate (,symb) #f))))
(provide "srfi-9")
#|
Example of usage
(define-record-type my-pair
(kons x y)
my-pair?
(x kar set-kar!)
(y kdr))
(list
(my-pair? (kons 1 2)) ; => #t
(my-pair? (cons 1 2)) ; => #f
(kar (kons 1 2)) ; => 1
(kdr (kons 1 2)) ; => 2
(let ((k (kons 1 2)))
(set-kar! k 3)
(kar k))) ; => 3
|#

View File

@ -20,7 +20,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 17-May-1993 12:35 ;;;; Creation date: 17-May-1993 12:35
;;;; Last file update: 3-Sep-1999 19:55 (eg) ;;;; Last file update: 16-Sep-1999 16:48 (eg)
;;;; ;;;;
(unless (equal? *tk-version* "8.0") (unless (equal? *tk-version* "8.0")
@ -385,7 +385,7 @@
;; Global help functions which are defined when Tk is loaded ;; Global help functions which are defined when Tk is loaded
(autoload "help" help STk:show-help-file) (autoload "help" help STk:show-help-file)
(autoload "www-browser" WWW:browser) (autoload "www-browser" WWW:browser WWW:mailto)
(autoload "class-browser" class-browser)) (autoload "class-browser" class-browser))
;;;; ;;;;

View File

@ -1,5 +1,6 @@
;;;; ;;;;
;;;; w w w - b r o w s e r . s t k l o s -- A simple WEB browser ;;;; w w w - b r o w s e r . s t k l o s -- A simple WEB browser
;;;; -- (and a very simple mail composer)
;;;; ;;;;
;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr> ;;;; Copyright © 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
;;;; ;;;;
@ -14,7 +15,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 21-Oct-1996 14:02 ;;;; Creation date: 21-Oct-1996 14:02
;;;; Last file update: 3-Sep-1999 19:56 (eg) ;;;; Last file update: 16-Sep-1999 17:37 (eg)
;;;; ;;;;
(require "Tk-classes") (require "Tk-classes")
@ -22,6 +23,10 @@
(import WWW) (import WWW)
;;;;
;;;; W W W : b r o w s e r
;;;;
(define WWW:browser (define WWW:browser
(let ((browser #f) ;; Id of browser (#f if no browser exists) (let ((browser #f) ;; Id of browser (#f if no browser exists)
(lentry #f)) ;; The labeled entry of the interface (lentry #f)) ;; The labeled entry of the interface
@ -156,9 +161,51 @@
(www:view-url (Id browser) url)) (www:view-url (Id browser) url))
browser)))) browser))))
(define (www:mailto . to)
(let* ((top (make <Toplevel> :title "STk Mail Composer"))
(to (make <Labeled-entry> :parent top :title "To:"
:title-width 7 :title-anchor 'e
:value (if (null? to) "" (car to))))
(cc (make <Labeled-entry> :parent top :title "Cc:"
:title-width 7 :title-anchor 'e))
(subject (make <Labeled-entry> :parent top :title "Subject:"
:title-width 7 :title-anchor 'e))
(txt (make <Scroll-text> :parent top))
(f (make <Frame> :parent top :border-width 2 :relief 'ridge))
(send (make <Button> :text "Send" :parent f :border-width 1))
(cancel (make <Button> :text "Cancel" :parent f :border-width 1)))
(pack to cc subject :expand #f :fill 'x :padx 5)
(pack txt :expand #t :fill 'both :padx 5 :pady 3)
(pack send cancel :side 'left)
(pack f :expand #f :fill 'x)
;; Set the background of text to white
(set! (background (text-of txt)) "white")
;; Set action of Send and Cancel button
(set! (command Cancel)
(lambda()
(if (eq? 'yes (Tk:message-box :title "Cancel Message"
:icon 'question :type 'yesno
:message "Close and discard message?"))
(destroy top))))
(set! (command send)
(lambda ()
(unless (string=? (value to) "")
(let ((cmd (string-append "| /bin/mail "
"-s '" (value subject) "' "
"-c '" (value cc) "' "
(value to))))
(with-output-to-file cmd (lambda () (display (value txt))))
(Tk:message-box :title "Message Information"
:message "Message sent" :icon 'info)
(destroy top)))))))
;;; ;;;
;;; Misc. ;;; Misc.
;;; ;;;
(define STk:web-browser WWW:browser) ; for backward compatibility with 3.x versions (define STk:web-browser WWW:browser) ; for backward compatibility with 3.x versions
(set! www:hook-mailto www:mailto)
(provide "www-browser") (provide "www-browser")

View File

@ -19,7 +19,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 1-Sep-1995 09:52 ;;;; Creation date: 1-Sep-1995 09:52
;;;; Last file update: 3-Sep-1999 19:57 (eg) ;;;; Last file update: 16-Sep-1999 17:17 (eg)
;;;; ;;;;
(require "regexp") (require "regexp")
@ -534,15 +534,21 @@
(define (html:href txt url href tag) (define (html:href txt url href tag)
(txt 'tag 'configure tag :foreground color-old-link) (txt 'tag 'configure tag :foreground color-old-link)
(if (and (eq? (url:service url) 'mailto) www:hook-mailto)
;; This is a "mailto:" and we know how tohandle it
(www:hook-mailto (url:filename url))
;; Othewise this is a document that we need to view
(begin
(unless (char=? (string-ref href 0) #\#) (unless (char=? (string-ref href 0) #\#)
;; It's a hack: when the href is "#xxxx", the reference is in the current ;; It's a hack: when the href is "#xxxx", the reference is in the current
;; page (and we don't need to load it). We can't use the encoded url here ;; page (and we don't need to load it). We can't use the encoded url here
;; since the pathnam is et to / by the url package. ;; since the pathname is set to / by the url package.
(www:view-URL txt url)) (www:view-URL txt url))
(let ((anchor (url:anchor url))) (let ((anchor (url:anchor url)))
(when anchor (when anchor
(let ((index (txt 'index (string-append "tag#" anchor ".first")))) (let ((index (txt 'index (string-append "tag#" anchor ".first"))))
(txt 'see index))))) (txt 'see index)))))))
;;;; ;;;;
;;;; HTML:EVAL a BIG BIG BIG security hole ;;;; HTML:EVAL a BIG BIG BIG security hole

View File

@ -6,7 +6,7 @@
;;; heading remains. ;;; heading remains.
;;; slightly modified by Erick Gallesio (changes are noted with [eg]) ;;; slightly modified by Erick Gallesio (changes are noted with [eg])
;;; (Last file update: 15-Aug-1999 20:08) ;;; (Last file update: 16-Sep-1999 15:24 (eg)
;;; Usage: ;;; Usage:
@ -128,7 +128,12 @@
;;; protocol, the host name, and the file name. ;;; protocol, the host name, and the file name.
(define (parse-url url . parent) (define (parse-url url . parent)
(proxitize (apply relativize (basic-parse-url url) parent))) (proxitize (apply relativize (basic-parse-url url)
(cond
((null? parent) '())
((through-proxy? (car parent))
(list (basic-parse-url (apply unparse-url parent))))
(else parent)))))
(define (basic-parse-url url) (define (basic-parse-url url)
(let* ((base (split url-regexp url)) (let* ((base (split url-regexp url))

View File

@ -17,7 +17,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 4-Oct-1996 16:14 ;;;; Creation date: 4-Oct-1996 16:14
;;;; Last file update: 3-Sep-1999 19:57 (eg) ;;;; Last file update: 16-Sep-1999 17:21 (eg)
;; ;;
;; This module needs a library of protocol getters & file viewers to be ;; This module needs a library of protocol getters & file viewers to be
@ -59,6 +59,8 @@
;; (www:hook-start-loading) called when a new page is loaded ;; (www:hook-start-loading) called when a new page is loaded
;; (www:hook-stop-loading) called when a new page has been loaded ;; (www:hook-stop-loading) called when a new page has been loaded
;; (www:hook-formatting) called often when formatting (pulse) ;; (www:hook-formatting) called often when formatting (pulse)
;; (www:hook-mailto . to) tested when a mailto: is encountered
;;
;; These hooks are set by default to #f (no action) ;; These hooks are set by default to #f (no action)
;; ;;
;; The exported variable ;; The exported variable
@ -77,7 +79,7 @@
(export WWW:view-url WWW:insert-url WWW:add-protocol WWW:add-viewer (export WWW:view-url WWW:insert-url WWW:add-protocol WWW:add-viewer
WWW:stop-loading WWW:stop-loading
www:hook-title www:hook-location www:hook-start-loading www:hook-title www:hook-location www:hook-start-loading
www:hook-stop-loading www:hook-formatting)) www:hook-stop-loading www:hook-formatting www:hook-mailto))
(select-module WWW) (select-module WWW)
@ -93,6 +95,7 @@
(define (www:hook-stop-loading) #f) ;; called when a new page has been loaded (define (www:hook-stop-loading) #f) ;; called when a new page has been loaded
(define (www:hook-formatting) #f) ;; called often when formatting (pulse) (define (www:hook-formatting) #f) ;; called often when formatting (pulse)
(define www:hook-mailto #f) ;; tested when a mailto: is encountered
;============================================================================= ;=============================================================================
; ;
@ -155,7 +158,7 @@
(www:hook-start-loading) (www:hook-start-loading)
(let ((res (apply www:insert-url txt url parent))) (let ((res (apply www:insert-url txt url parent)))
(www:hook-location (url:pretty-url url parent)) (www:hook-location (apply url:pretty-url url parent))
(tk-set! txt :state "disabled") ; make text read-only (tk-set! txt :state "disabled") ; make text read-only
(www:hook-stop-loading) (www:hook-stop-loading)
(set! *loading-document* #f) (set! *loading-document* #f)
@ -177,8 +180,9 @@
(apply url:parse-url url parent)))) (apply url:parse-url url parent))))
(let ((p (url->port parsed-url))) ; Return <port, full-url, close-port> (let ((p (url->port parsed-url))) ; Return <port, full-url, close-port>
(when p (if p
(vector (car p) parsed-url (cdr p)))))) (vector (car p) parsed-url (cdr p))
(vector #f parsed-url #f)))))
(define (WWW:insert-url txt url . parent) (define (WWW:insert-url txt url . parent)
@ -199,7 +203,8 @@
'txt) 'txt)
#f)))) #f))))
(unless viewer ; again (unless viewer ; again
(error "Don't know how to view the URL ~S" (url:pretty-url url parent)))) (error "Don't know how to handle the URL ~S" (apply url:pretty-url
url parent))))
;; Viewer is known now. Here we go ;; Viewer is known now. Here we go
(let ((res (viewer txt port parsed-url))) (let ((res (viewer txt port parsed-url)))

2
README
View File

@ -50,7 +50,7 @@ distribution main directory for more informations.
* New option -console to run STk in a windowed environment * New option -console to run STk in a windowed environment
(with indentation and fontification). (with indentation and fontification).
* define-syntax * define-syntax
* SRFI-{0,2,6,8} * SRFI-{0,2,6,8,9}
* New License Policy (request for commercial apps no more needed). * New License Policy (request for commercial apps no more needed).
* ... * ...

145
STk.prj
View File

@ -1,11 +1,11 @@
;; -*- prcs -*- ;; -*- prcs -*-
(Created-By-Prcs-Version 1 2 14) (Created-By-Prcs-Version 1 2 14)
(Project-Description "The STk Scheme Interpreter") (Project-Description "The STk Scheme Interpreter")
(Project-Version STk 4.0.0 6) (Project-Version STk 4.0.1 3)
(Parent-Version STk 4.0.0 5) (Parent-Version STk 4.0.1 2)
(Version-Log "") (Version-Log "")
(New-Version-Log "") (New-Version-Log "")
(Checkin-Time "Sun, 05 Sep 1999 13:30:34 +0200") (Checkin-Time "Mon, 27 Sep 1999 15:46:35 +0200")
(Checkin-Login eg) (Checkin-Login eg)
(Populate-Ignore ("\\.o$" (Populate-Ignore ("\\.o$"
"\\.a$" "\\.a$"
@ -37,17 +37,17 @@
(Files (Files
;; Top Level Files ;; Top Level Files
(configure.in (STk/K/29_configure. 1.1.1.21 644)) (configure.in (STk/K/29_configure. 1.1.1.22 644))
(configure (STk/K/30_configure 1.1.1.22 755)) (configure (STk/K/30_configure 1.1.1.23 755))
(VERSION (STk/K/31_VERSION 1.8 644)) (VERSION (STk/K/31_VERSION 1.9 644))
(README (STk/K/32_README 1.8 644)) (README (STk/K/32_README 1.9 644))
(Makefile.in (STk/K/33_Makefile.i 1.3.1.19 644)) (Makefile.in (STk/K/33_Makefile.i 1.3.1.19 644))
(INSTALL (STk/K/35_INSTALL 1.9 644)) (INSTALL (STk/K/35_INSTALL 1.9 644))
(INSTALL.win32 (STk/i/b/46_INSTALL.wi 1.2 644)) (INSTALL.win32 (STk/i/b/46_INSTALL.wi 1.2 644))
(ChangeLog (STk/K/36_ChangeLog 1.20.1.62 644)) (ChangeLog (STk/K/36_ChangeLog 1.20.1.65 644))
(COPYRIGHTS (STk/K/37_COPYRIGHTS 1.2 644)) (COPYRIGHTS (STk/K/37_COPYRIGHTS 1.2 644))
(COMPILING-HINTS (STk/K/38_COMPILING- 1.1 644)) (COMPILING-HINTS (STk/K/38_COMPILING- 1.1 644))
(CHANGES (STk/K/39_CHANGES 1.11 644)) (CHANGES (STk/K/39_CHANGES 1.12 644))
(BINARY_DISTRIB (STk/K/40_BINARY_DIS 1.2 644)) (BINARY_DISTRIB (STk/K/40_BINARY_DIS 1.2 644))
(paths (STk/e/b/29_paths 1.1 644)) (paths (STk/e/b/29_paths 1.1 644))
@ -116,7 +116,7 @@
(Contrib/STk-wtour/lessons/tkwait.stk (STk/L/44_tkwait.stk 1.1 644)) (Contrib/STk-wtour/lessons/tkwait.stk (STk/L/44_tkwait.stk 1.1 644))
(Contrib/STk-wtour/lib/iu.ridge.xbm (STk/L/45_iu.ridge.x 1.1 644)) (Contrib/STk-wtour/lib/iu.ridge.xbm (STk/L/45_iu.ridge.x 1.1 644))
(Contrib/STk-wtour/lib/iu.seal.small.xbm (STk/L/46_iu.seal.sm 1.1 644)) (Contrib/STk-wtour/lib/iu.seal.small.xbm (STk/L/46_iu.seal.sm 1.1 644))
(Contrib/STk-wtour/lib/wtour.stk (STk/L/47_wtour.stk 1.1 644)) (Contrib/STk-wtour/lib/wtour.stk (STk/L/47_wtour.stk 1.3 755))
(Contrib/STk-wtour/stk-wtour (STk/L/48_stk-wtour 1.1 755)) (Contrib/STk-wtour/stk-wtour (STk/L/48_stk-wtour 1.1 755))
(Contrib/Socket/socket.c (STk/L/49_socket.c 1.1 644)) (Contrib/Socket/socket.c (STk/L/49_socket.c 1.1 644))
(Contrib/Stetris/stetris.stk (STk/L/50_stetris.st 1.3 755)) (Contrib/Stetris/stetris.stk (STk/L/50_stetris.st 1.3 755))
@ -183,8 +183,8 @@
(Demos/Html-Demos/animate.stk (STk/e/b/2_animate.st 1.2 644)) (Demos/Html-Demos/animate.stk (STk/e/b/2_animate.st 1.2 644))
(Demos/Html-Demos/main-fr.html (STk/e/b/3_main-fr.ht 1.1 644)) (Demos/Html-Demos/main-fr.html (STk/e/b/3_main-fr.ht 1.1 644))
(Demos/Html-Demos/main.html (STk/e/b/4_main.html 1.1 644)) (Demos/Html-Demos/main.html (STk/e/b/4_main.html 1.1 644))
(Demos/Makefile (STk/M/0_Makefile 1.5 644)) (Demos/Makefile (STk/M/0_Makefile 1.6 644))
(Demos/README.html (STk/M/1_README.htm 1.7 644)) (Demos/README.html (STk/M/1_README.htm 1.8 644))
(Demos/STk-normal.gif (../Lib/Images/STk-normal.gif) :symlink) (Demos/STk-normal.gif (../Lib/Images/STk-normal.gif) :symlink)
(Demos/Widget/Warrow.stklos (STk/M/2_Warrow.stk 1.1 644)) (Demos/Widget/Warrow.stklos (STk/M/2_Warrow.stk 1.1 644))
(Demos/Widget/Wbind.stklos (STk/M/3_Wbind.stkl 1.1 644)) (Demos/Widget/Wbind.stklos (STk/M/3_Wbind.stkl 1.1 644))
@ -218,34 +218,34 @@
(Demos/Widget/Wtext.stklos (STk/M/28_Wtext.stkl 1.1 644)) (Demos/Widget/Wtext.stklos (STk/M/28_Wtext.stkl 1.1 644))
(Demos/Widget/Wvscale.stklos (STk/M/29_Wvscale.st 1.1 644)) (Demos/Widget/Wvscale.stklos (STk/M/29_Wvscale.st 1.1 644))
(Demos/Widget/Wwind.stklos (STk/M/30_Wwind.stkl 1.2 644)) (Demos/Widget/Wwind.stklos (STk/M/30_Wwind.stkl 1.2 644))
(Demos/amib.stklos (STk/M/31_amib.stklo 1.6 644)) (Demos/amib.stklos (STk/M/31_amib.stklo 1.6 755))
(Demos/browse.stk (STk/M/32_browse.stk 1.5 644)) (Demos/browse.stk (STk/M/32_browse.stk 1.5 755))
(Demos/browse.stklos (STk/M/33_browse.stk 1.5 644)) (Demos/browse.stklos (STk/M/33_browse.stk 1.5 755))
(Demos/calc.stklos (STk/M/34_calc.stklo 1.3 644)) (Demos/calc.stklos (STk/M/34_calc.stklo 1.3 755))
(Demos/classbrowse.stklos (STk/e/b/41_classbrows 1.2 644)) (Demos/classbrowse.stklos (STk/e/b/41_classbrows 1.2 755))
(Demos/colormap.stk (STk/M/35_colormap.s 1.4 644)) (Demos/colormap.stk (STk/M/35_colormap.s 1.4 755))
(Demos/console-demo.stk (STk/j/b/35_console-de 1.2 644)) (Demos/console-demo.stk (STk/j/b/35_console-de 1.3 755))
(Demos/filebox.stklos (STk/M/37_filebox.st 1.4 644)) (Demos/filebox.stklos (STk/M/37_filebox.st 1.4 755))
(Demos/hanoi.stk (STk/M/38_hanoi.stk 1.4 644)) (Demos/hanoi.stk (STk/M/38_hanoi.stk 1.5 755))
(Demos/hello.stk (STk/M/39_hello.stk 1.2 644)) (Demos/hello.stk (STk/M/39_hello.stk 1.2 755))
(Demos/hello.stklos (STk/M/40_hello.stkl 1.2 644)) (Demos/hello.stklos (STk/M/40_hello.stkl 1.2 755))
(Demos/inspector.stk (STk/M/41_inspector. 1.2 644)) (Demos/inspector.stk (STk/M/41_inspector. 1.2 755))
(Demos/mc-server.stk (STk/M/42_mc-server. 1.3 644)) (Demos/mc-server.stk (STk/M/42_mc-server. 1.4 755))
(Demos/queens.stk (STk/M/43_queens.stk 1.1 755)) (Demos/queens.stk (STk/M/43_queens.stk 1.2 755))
(Demos/server.stk (STk/M/44_server.stk 1.3 644)) (Demos/server.stk (STk/M/44_server.stk 1.4 755))
(Demos/showvars.stk (STk/M/45_showvars.s 1.3 755)) (Demos/showvars.stk (STk/M/45_showvars.s 1.4 755))
(Demos/small-ed.stk (STk/M/46_small-ed.s 1.2 644)) (Demos/small-ed.stk (STk/M/46_small-ed.s 1.3 755))
(Demos/stetris.stk (../Contrib/Stetris/stetris.stk) :symlink) (Demos/stetris.stk (../Contrib/Stetris/stetris.stk) :symlink)
(Demos/stkfontsel.stk (STk/i/b/49_stkfontsel 1.2 644)) (Demos/stkfontsel.stk (STk/i/b/49_stkfontsel 1.3 755))
(Demos/stklos-demo.stklos (STk/M/47_stklos-dem 1.5 644)) (Demos/stklos-demo.stklos (STk/M/47_stklos-dem 1.6 755))
(Demos/stklos-demo2.stklos (STk/M/48_stklos-dem 1.5 644)) (Demos/stklos-demo2.stklos (STk/M/48_stklos-dem 1.6 755))
(Demos/stklos-widgets.stklos (STk/M/49_stklos-wid 1.9 755)) (Demos/stklos-widgets.stklos (STk/M/49_stklos-wid 1.9 755))
(Demos/term.stk (STk/M/50_term.stk 1.3 644)) (Demos/term.stk (STk/M/50_term.stk 1.3 755))
(Demos/tkcolor.stklos (STk/M/51_tkcolor.st 1.2 644)) (Demos/tkcolor.stklos (STk/M/51_tkcolor.st 1.2 755))
(Demos/ttt.stk (STk/N/0_ttt.stk 1.1 755)) (Demos/ttt.stk (STk/N/0_ttt.stk 1.1 755))
(Demos/turtle.stk (STk/N/1_turtle.stk 1.2 644)) (Demos/turtle.stk (STk/N/1_turtle.stk 1.2 777))
(Demos/S-scape.stklos (STk/d/b/5_S-scape.st 1.2 644)) (Demos/S-scape.stklos (STk/d/b/5_S-scape.st 1.2 755))
(Demos/widget.stk (STk/N/3_widget.stk 1.10 644)) (Demos/widget.stk (STk/N/3_widget.stk 1.10 744))
(Demos/wtour.stk (../Contrib/STk-wtour/lib/wtour.stk) :symlink) (Demos/wtour.stk (../Contrib/STk-wtour/lib/wtour.stk) :symlink)
;; Documentation Directory ;; Documentation Directory
@ -253,7 +253,7 @@
(Doc/Extension/Extending.dvi (STk/N/5_Extending. 1.8 644) :no-keywords) (Doc/Extension/Extending.dvi (STk/N/5_Extending. 1.8 644) :no-keywords)
(Doc/Extension/Extending.ps (STk/N/6_Extending. 1.8 644)) (Doc/Extension/Extending.ps (STk/N/6_Extending. 1.8 644))
(Doc/Extension/Extending.tex (STk/N/7_Extending. 1.2 644)) (Doc/Extension/Extending.tex (STk/N/7_Extending. 1.2 644))
(Doc/Extension/Makefile (STk/N/8_Makefile 1.1 644)) (Doc/Extension/Makefile (STk/N/8_Makefile 1.2 644))
(Doc/Extension/bibliography.bib (../Reference/bibliography.bib) :symlink) (Doc/Extension/bibliography.bib (../Reference/bibliography.bib) :symlink)
(Doc/Extension/eg-commands.sty (../Reference/eg-commands.sty) :symlink) (Doc/Extension/eg-commands.sty (../Reference/eg-commands.sty) :symlink)
(Doc/Extension/hash.c (../../Extensions/hash.c) :symlink) (Doc/Extension/hash.c (../../Extensions/hash.c) :symlink)
@ -270,8 +270,8 @@
(Doc/FAQ/FAQ.html (STk/N/16_FAQ.html 1.1 644)) (Doc/FAQ/FAQ.html (STk/N/16_FAQ.html 1.1 644))
(Doc/FAQ/FAQ.ps (STk/N/17_FAQ.ps 1.1 644)) (Doc/FAQ/FAQ.ps (STk/N/17_FAQ.ps 1.1 644))
(Doc/FAQ/FAQ.txt (STk/N/18_FAQ.txt 1.1 644)) (Doc/FAQ/FAQ.txt (STk/N/18_FAQ.txt 1.1 644))
(Doc/Isotas96/Isotas96.dvi (STk/N/19_Isotas96.d 1.13 644) :no-keywords) (Doc/Isotas96/Isotas96.dvi (STk/N/19_Isotas96.d 1.15 644) :no-keywords)
(Doc/Isotas96/Isotas96.ps (STk/N/20_Isotas96.p 1.13 644)) (Doc/Isotas96/Isotas96.ps (STk/N/20_Isotas96.p 1.15 644))
(Doc/Isotas96/Isotas96.tex (STk/N/21_Isotas96.t 1.1 644)) (Doc/Isotas96/Isotas96.tex (STk/N/21_Isotas96.t 1.1 644))
(Doc/Isotas96/Makefile (STk/N/22_Makefile 1.1 644)) (Doc/Isotas96/Makefile (STk/N/22_Makefile 1.1 644))
(Doc/Isotas96/bibliography.bib (../bibliography.bib) :symlink) (Doc/Isotas96/bibliography.bib (../bibliography.bib) :symlink)
@ -285,7 +285,7 @@
(Doc/LaTeX-packages/a4.sty (STk/N/30_a4.sty 1.1 644)) (Doc/LaTeX-packages/a4.sty (STk/N/30_a4.sty 1.1 644))
(Doc/LaTeX-packages/a4wide.sty (STk/N/31_a4wide.sty 1.1 644)) (Doc/LaTeX-packages/a4wide.sty (STk/N/31_a4wide.sty 1.1 644))
(Doc/LaTeX-packages/moreverb.sty (STk/N/32_moreverb.s 1.1 644)) (Doc/LaTeX-packages/moreverb.sty (STk/N/32_moreverb.s 1.1 644))
(Doc/Makefile (STk/N/33_Makefile 1.2 644)) (Doc/Makefile (STk/N/33_Makefile 1.3 644))
(Doc/Manual/Makefile (STk/N/34_Makefile 1.4 644)) (Doc/Manual/Makefile (STk/N/34_Makefile 1.4 644))
(Doc/Manual/STk-man.macros (STk/N/35_STk-man.ma 1.2 644)) (Doc/Manual/STk-man.macros (STk/N/35_STk-man.ma 1.2 644))
(Doc/Manual/after.n (STk/N/36_after.n 1.1 644)) (Doc/Manual/after.n (STk/N/36_after.n 1.1 644))
@ -357,18 +357,18 @@
(Doc/Manual/find-image.n (make-image.n) :symlink) (Doc/Manual/find-image.n (make-image.n) :symlink)
(Doc/Manual/repl-display-result.n (repl-display-prompt.n) :symlink) (Doc/Manual/repl-display-result.n (repl-display-prompt.n) :symlink)
(Doc/Manual/repl-display-prompt.n (STk/e/b/19_repl-displ 1.1 644)) (Doc/Manual/repl-display-prompt.n (STk/e/b/19_repl-displ 1.1 644))
(Doc/Reference/Appendix-A.tex (STk/O/44_Appendix-A 1.1 644)) (Doc/Reference/Appendix-A.tex (STk/O/44_Appendix-A 1.2 644))
(Doc/Reference/Appendix-B.tex (STk/O/45_Appendix-B 1.2 644)) (Doc/Reference/Appendix-B.tex (STk/O/45_Appendix-B 1.3 644))
(Doc/Reference/Appendix-C.tex (STk/O/46_Appendix-C 1.3 644)) (Doc/Reference/Appendix-C.tex (STk/O/46_Appendix-C 1.4 644))
(Doc/Reference/Appendix-D.tex (STk/O/47_Appendix-D 1.2 644)) (Doc/Reference/Appendix-D.tex (STk/O/47_Appendix-D 1.2 644))
(Doc/Reference/Appendix-E.tex (STk/O/48_Appendix-E 1.7 644)) (Doc/Reference/Appendix-E.tex (STk/O/48_Appendix-E 1.8 644))
(Doc/Reference/Appendix-F.tex (STk/e/b/5_Appendix-F 1.2 644)) (Doc/Reference/Appendix-F.tex (STk/e/b/5_Appendix-F 1.3 644))
(Doc/Reference/Detail.ps (STk/O/49_Detail.ps 1.1 644)) (Doc/Reference/Detail.ps (STk/O/49_Detail.ps 1.1 644))
(Doc/Reference/Inspector.ps (STk/O/50_Inspector. 1.1 644)) (Doc/Reference/Inspector.ps (STk/O/50_Inspector. 1.1 644))
(Doc/Reference/Makefile (STk/O/51_Makefile 1.2 644)) (Doc/Reference/Makefile (STk/O/51_Makefile 1.3 644))
(Doc/Reference/Reference1.tex (STk/P/0_Reference1 1.5 644)) (Doc/Reference/Reference1.tex (STk/P/0_Reference1 1.6 644))
(Doc/Reference/Reference2.tex (STk/P/1_Reference2 1.4 644)) (Doc/Reference/Reference2.tex (STk/P/1_Reference2 1.6 644))
(Doc/Reference/Reference3.tex (STk/P/2_Reference3 1.3 644)) (Doc/Reference/Reference3.tex (STk/P/2_Reference3 1.4 644))
(Doc/Reference/View.ps (STk/P/3_View.ps 1.1 644)) (Doc/Reference/View.ps (STk/P/3_View.ps 1.1 644))
(Doc/Reference/bibliography.bib (../bibliography.bib) :symlink) (Doc/Reference/bibliography.bib (../bibliography.bib) :symlink)
(Doc/Reference/commands.tex (STk/P/4_commands.t 1.1 644)) (Doc/Reference/commands.tex (STk/P/4_commands.t 1.1 644))
@ -376,8 +376,8 @@
(Doc/Reference/hierarchy.eps (STk/P/6_hierarchy. 1.1 644)) (Doc/Reference/hierarchy.eps (STk/P/6_hierarchy. 1.1 644))
(Doc/Reference/hierarchy.fig (STk/P/7_hierarchy. 1.1 644)) (Doc/Reference/hierarchy.fig (STk/P/7_hierarchy. 1.1 644))
(Doc/Reference/index.stk (STk/P/8_index.stk 1.1 644)) (Doc/Reference/index.stk (STk/P/8_index.stk 1.1 644))
(Doc/Reference/manual.dvi (STk/P/9_manual.dvi 1.17 644) :no-keywords) (Doc/Reference/manual.dvi (STk/P/9_manual.dvi 1.20 644) :no-keywords)
(Doc/Reference/manual.ps (STk/P/10_manual.ps 1.15 644) :no-keywords) (Doc/Reference/manual.ps (STk/P/10_manual.ps 1.18 644) :no-keywords)
(Doc/Reference/manual.tex (STk/P/11_manual.tex 1.7 644)) (Doc/Reference/manual.tex (STk/P/11_manual.tex 1.7 644))
(Doc/STklos+Tk/Basic-Fig-1.ps (STk/P/12_Basic-Fig- 1.1 644)) (Doc/STklos+Tk/Basic-Fig-1.ps (STk/P/12_Basic-Fig- 1.1 644))
(Doc/STklos+Tk/Chap1.tex (STk/P/13_Chap1.tex 1.1 644)) (Doc/STklos+Tk/Chap1.tex (STk/P/13_Chap1.tex 1.1 644))
@ -408,13 +408,13 @@
(Extensions/base64.c (STk/e/b/30_base64.c 1.4 644)) (Extensions/base64.c (STk/e/b/30_base64.c 1.4 644))
(Extensions/configure (STk/P/35_configure 1.2 755)) (Extensions/configure (STk/P/35_configure 1.2 755))
(Extensions/configure.in (STk/P/36_configure. 1.2 644)) (Extensions/configure.in (STk/P/36_configure. 1.2 644))
(Extensions/hash.c (STk/P/37_hash.c 1.7 644)) (Extensions/hash.c (STk/P/37_hash.c 1.8 644))
(Extensions/html.c (STk/P/38_html.c 1.5 644)) (Extensions/html.c (STk/P/38_html.c 1.5 644))
(Extensions/jpeg.c (STk/P/39_jpeg.c 1.1 644)) (Extensions/jpeg.c (STk/P/39_jpeg.c 1.1 644))
(Extensions/locale.c (STk/e/b/42_locale.c 1.2 644)) (Extensions/locale.c (STk/e/b/42_locale.c 1.2 644))
(Extensions/pixmap.c (STk/P/40_pixmap.c 1.2 644)) (Extensions/pixmap.c (STk/P/40_pixmap.c 1.3 644))
(Extensions/posix.c (STk/P/41_posix.c 1.4 644)) (Extensions/posix.c (STk/P/41_posix.c 1.4 644))
(Extensions/process.c (STk/P/42_process.c 1.9 644)) (Extensions/process.c (STk/P/42_process.c 1.10 644))
(Extensions/socket.c (STk/P/43_socket.c 1.10 644)) (Extensions/socket.c (STk/P/43_socket.c 1.10 644))
(Extensions/sregexp.c (STk/P/44_sregexp.c 1.2 644)) (Extensions/sregexp.c (STk/P/44_sregexp.c 1.2 644))
(Extensions/stack.c (STk/P/45_stack.c 1.1 644)) (Extensions/stack.c (STk/P/45_stack.c 1.1 644))
@ -639,7 +639,7 @@
(Lib/help.stk (STk/S/43_help.stk 1.5 644)) (Lib/help.stk (STk/S/43_help.stk 1.5 644))
(Lib/html.stk (STk/S/44_html.stk 1.1 644)) (Lib/html.stk (STk/S/44_html.stk 1.1 644))
(Lib/image.stk (STk/S/45_image.stk 1.7 644)) (Lib/image.stk (STk/S/45_image.stk 1.7 644))
(Lib/init.stk (STk/S/46_init.stk 1.33 644)) (Lib/init.stk (STk/S/46_init.stk 1.34 644))
(Lib/inspect-detail.stk (STk/S/47_inspect-de 1.1 644)) (Lib/inspect-detail.stk (STk/S/47_inspect-de 1.1 644))
(Lib/inspect-help.stk (STk/S/48_inspect-he 1.1 644)) (Lib/inspect-help.stk (STk/S/48_inspect-he 1.1 644))
(Lib/inspect-main.stk (STk/S/49_inspect-ma 1.2 644)) (Lib/inspect-main.stk (STk/S/49_inspect-ma 1.2 644))
@ -663,26 +663,27 @@
(Lib/security.stk (STk/T/14_security.s 1.2 644)) (Lib/security.stk (STk/T/14_security.s 1.2 644))
(Lib/slib.stk (STk/T/15_slib.stk 1.2 644)) (Lib/slib.stk (STk/T/15_slib.stk 1.2 644))
(Lib/socket.stk (STk/T/16_socket.stk 1.4 644)) (Lib/socket.stk (STk/T/16_socket.stk 1.4 644))
(Lib/srfi-0.stk (STk/j/b/42_srfi-0.stk 1.3 644)) (Lib/srfi-0.stk (STk/j/b/42_srfi-0.stk 1.4 644))
(Lib/srfi-2.stk (STk/j/b/43_srfi-2.stk 1.1 644)) (Lib/srfi-2.stk (STk/j/b/43_srfi-2.stk 1.1 644))
(Lib/srfi-7.stk (STk/j/b/44_srfi-7.stk 1.2 644)) (Lib/srfi-7.stk (STk/j/b/44_srfi-7.stk 1.2 644))
(Lib/srfi-9.stk (STk/j/b/46_srfi-9.stk 1.1 644))
(Lib/sterm.stk (STk/T/17_sterm.stk 1.4 644)) (Lib/sterm.stk (STk/T/17_sterm.stk 1.4 644))
(Lib/text.stk (STk/T/18_text.stk 1.8 644)) (Lib/text.stk (STk/T/18_text.stk 1.8 644))
(Lib/tk-init.stk (STk/T/19_tk-init.st 1.25 644)) (Lib/tk-init.stk (STk/T/19_tk-init.st 1.26 644))
(Lib/tk-unix.stk (STk/e/b/9_tk-unix.st 1.4 644)) (Lib/tk-unix.stk (STk/e/b/9_tk-unix.st 1.4 644))
(Lib/trace.stk (STk/T/20_trace.stk 1.5 644)) (Lib/trace.stk (STk/T/20_trace.stk 1.5 644))
(Lib/unix.stk (STk/T/21_unix.stk 1.4 644)) (Lib/unix.stk (STk/T/21_unix.stk 1.4 644))
(Lib/win32.stk (STk/j/b/27_win32.stk 1.2 644)) (Lib/win32.stk (STk/j/b/27_win32.stk 1.2 644))
(Lib/winsocket.stklos (STk/j/b/36_winsocket. 1.1 644)) (Lib/winsocket.stklos (STk/j/b/36_winsocket. 1.1 644))
(Lib/www-browser.stklos (STk/c/b/29_www-browse 1.10 644)) (Lib/www-browser.stklos (STk/c/b/29_www-browse 1.11 644))
(Lib/www-file.stk (STk/T/23_www-file.s 1.4 644)) (Lib/www-file.stk (STk/T/23_www-file.s 1.4 644))
(Lib/www-html.stk (STk/T/24_www-html.s 1.5 644)) (Lib/www-html.stk (STk/T/24_www-html.s 1.6 644))
(Lib/www-http.stk (STk/T/25_www-http.s 1.3 644)) (Lib/www-http.stk (STk/T/25_www-http.s 1.3 644))
(Lib/www-img.stk (STk/T/26_www-img.st 1.7 644)) (Lib/www-img.stk (STk/T/26_www-img.st 1.7 644))
(Lib/www-snd.stk (STk/T/27_www-snd.st 1.3 644)) (Lib/www-snd.stk (STk/T/27_www-snd.st 1.3 644))
(Lib/www-txt.stk (STk/T/28_www-txt.st 1.3 644)) (Lib/www-txt.stk (STk/T/28_www-txt.st 1.3 644))
(Lib/www-url.stk (STk/T/29_www-url.st 1.5 644)) (Lib/www-url.stk (STk/T/29_www-url.st 1.6 644))
(Lib/www.stk (STk/T/30_www.stk 1.5 644)) (Lib/www.stk (STk/T/30_www.stk 1.6 644))
;; The Multiple Precision Library (Free and Gnu) ;; The Multiple Precision Library (Free and Gnu)
(Mp/Makefile (STk/T/31_Makefile 1.2 644)) (Mp/Makefile (STk/T/31_Makefile 1.2 644))
@ -845,7 +846,7 @@
(STklos/Tk/Composite/Defbutton.stklos (STk/W/25_Defbutton. 1.4 644)) (STklos/Tk/Composite/Defbutton.stklos (STk/W/25_Defbutton. 1.4 644))
(STklos/Tk/Composite/Filebox.stklos (STk/W/26_Filebox.st 1.11 644)) (STklos/Tk/Composite/Filebox.stklos (STk/W/26_Filebox.st 1.11 644))
(STklos/Tk/Composite/Gauge.stklos (STk/c/b/25_Gauge.stkl 1.3 644)) (STklos/Tk/Composite/Gauge.stklos (STk/c/b/25_Gauge.stkl 1.3 644))
(STklos/Tk/Composite/Hierarchy.stklos (STk/e/b/35_Hierarchy. 1.7 644)) (STklos/Tk/Composite/Hierarchy.stklos (STk/e/b/35_Hierarchy. 1.8 644))
(STklos/Tk/Composite/Lentry.stklos (STk/W/28_Lentry.stk 1.7 644)) (STklos/Tk/Composite/Lentry.stklos (STk/W/28_Lentry.stk 1.7 644))
(STklos/Tk/Composite/Lframe.stklos (STk/W/29_Lframe.stk 1.5 644)) (STklos/Tk/Composite/Lframe.stklos (STk/W/29_Lframe.stk 1.5 644))
(STklos/Tk/Composite/Msgbox.stklos (STk/c/b/20_Msgbox.stk 1.7 644)) (STklos/Tk/Composite/Msgbox.stklos (STk/c/b/20_Msgbox.stk 1.7 644))
@ -882,7 +883,7 @@
(STklos/active-slot.stklos (STk/c/b/21_active-slo 1.2 644)) (STklos/active-slot.stklos (STk/c/b/21_active-slo 1.2 644))
(STklos/composite-slot.stklos (STk/c/b/22_composite- 1.2 644)) (STklos/composite-slot.stklos (STk/c/b/22_composite- 1.2 644))
(STklos/describe.stklos (STk/c/b/14_describe.s 1.4 644)) (STklos/describe.stklos (STk/c/b/14_describe.s 1.4 644))
(STklos/stklos.stk (STk/c/b/10_stklos.stk 1.30 644)) (STklos/stklos.stk (STk/c/b/10_stklos.stk 1.31 644))
(STklos/trace-gf.stklos (STk/c/b/11_trace-gf.s 1.2 644)) (STklos/trace-gf.stklos (STk/c/b/11_trace-gf.s 1.2 644))
;; Snow (Stk with NO Window) Directory ;; Snow (Stk with NO Window) Directory
@ -967,7 +968,7 @@
(Src/cont.c (STk/X/12_cont.c 1.9 644)) (Src/cont.c (STk/X/12_cont.c 1.9 644))
(Src/dummy.c (STk/X/13_dummy.c 1.5 644)) (Src/dummy.c (STk/X/13_dummy.c 1.5 644))
(Src/dump.c (STk/X/14_dump.c 1.4 644)) (Src/dump.c (STk/X/14_dump.c 1.4 644))
(Src/dynload.c (STk/X/15_dynload.c 1.17 644)) (Src/dynload.c (STk/X/15_dynload.c 1.18 644))
(Src/env.c (STk/X/16_env.c 1.10 644)) (Src/env.c (STk/X/16_env.c 1.10 644))
(Src/error.c (STk/X/17_error.c 1.15 644)) (Src/error.c (STk/X/17_error.c 1.15 644))
(Src/eval.c (STk/X/18_eval.c 1.20 644)) (Src/eval.c (STk/X/18_eval.c 1.20 644))
@ -990,7 +991,7 @@
(Src/port.c (STk/X/30_port.c 1.30 644)) (Src/port.c (STk/X/30_port.c 1.30 644))
(Src/posix.c (../Extensions/posix.c) :symlink) (Src/posix.c (../Extensions/posix.c) :symlink)
(Src/primitives.c (STk/X/31_primitives 1.27 644)) (Src/primitives.c (STk/X/31_primitives 1.27 644))
(Src/print.c (STk/X/32_print.c 1.13 644)) (Src/print.c (STk/X/32_print.c 1.14 644))
(Src/proc.c (STk/X/33_proc.c 1.6 644)) (Src/proc.c (STk/X/33_proc.c 1.6 644))
(Src/process.c (../Extensions/process.c) :symlink) (Src/process.c (../Extensions/process.c) :symlink)
(Src/promise.c (STk/X/34_promise.c 1.2 644)) (Src/promise.c (STk/X/34_promise.c 1.2 644))
@ -999,13 +1000,13 @@
(Src/signal.c (STk/X/37_signal.c 1.14 644)) (Src/signal.c (STk/X/37_signal.c 1.14 644))
(Src/slib.c (STk/X/38_slib.c 1.19 644)) (Src/slib.c (STk/X/38_slib.c 1.19 644))
(Src/socket.c (../Extensions/socket.c) :symlink) (Src/socket.c (../Extensions/socket.c) :symlink)
(Src/sport.c (STk/X/39_sport.c 1.8 644)) (Src/sport.c (STk/X/39_sport.c 1.9 644))
(Src/sport.h (STk/X/40_sport.h 1.4 644)) (Src/sport.h (STk/X/40_sport.h 1.4 644))
(Src/sregexp.c (../Extensions/sregexp.c) :symlink) (Src/sregexp.c (../Extensions/sregexp.c) :symlink)
(Src/stk.c (STk/X/41_stk.c 1.2 644)) (Src/stk.c (STk/X/41_stk.c 1.2 644))
; (Src/stk.h.in (STk/j/b/25_stk.h.in 1.1 644)) ; (Src/stk.h.in (STk/j/b/25_stk.h.in 1.1 644))
(Src/stk.h (STk/j/b/28_stk.h 1.9 644)) ; Don't delete it for Windows (Src/stk.h (STk/j/b/28_stk.h 1.9 644)) ; Don't delete it for Windows
(Src/stkvers.h (STk/j/b/29_stkvers.h 1.2 644)) ; Should not be here (for Win32) (Src/stkvers.h (STk/j/b/29_stkvers.h 1.3 644)) ; Should not be here (for Win32)
(Src/stklos.c (STk/X/43_stklos.c 1.20 644)) (Src/stklos.c (STk/X/43_stklos.c 1.20 644))
(Src/stklos.h (STk/X/44_stklos.h 1.7 644)) (Src/stklos.h (STk/X/44_stklos.h 1.7 644))
(Src/str.c (STk/X/45_str.c 1.5 644)) (Src/str.c (STk/X/45_str.c 1.5 644))
@ -1023,7 +1024,7 @@
(Src/tk-util.c (STk/Y/5_tk-util.c 1.2 644)) (Src/tk-util.c (STk/Y/5_tk-util.c 1.2 644))
(Src/toplevel.c (STk/Y/6_toplevel.c 1.20 644)) (Src/toplevel.c (STk/Y/6_toplevel.c 1.20 644))
(Src/trace.c (STk/Y/7_trace.c 1.4 644)) (Src/trace.c (STk/Y/7_trace.c 1.4 644))
(Src/unix.c (STk/Y/8_unix.c 1.12 644)) (Src/unix.c (STk/Y/8_unix.c 1.13 644))
(Src/vport.c (STk/e/b/50_vport.c 1.3 644)) (Src/vport.c (STk/e/b/50_vport.c 1.3 644))
(Src/vport.h (STk/e/b/51_vport.h 1.2 644)) (Src/vport.h (STk/e/b/51_vport.h 1.2 644))
(Src/userinit.c (STk/Y/9_userinit.c 1.8 644)) (Src/userinit.c (STk/Y/9_userinit.c 1.8 644))
@ -1134,7 +1135,7 @@
(Tk/generic/tkCanvImg.c (STk/a/b/4_tkCanvImg. 1.3 644)) (Tk/generic/tkCanvImg.c (STk/a/b/4_tkCanvImg. 1.3 644))
(Tk/generic/tkCanvLine.c (STk/a/b/5_tkCanvLine 1.2 644)) (Tk/generic/tkCanvLine.c (STk/a/b/5_tkCanvLine 1.2 644))
(Tk/generic/tkCanvPoly.c (STk/a/b/6_tkCanvPoly 1.2 644)) (Tk/generic/tkCanvPoly.c (STk/a/b/6_tkCanvPoly 1.2 644))
(Tk/generic/tkCanvPs.c (STk/a/b/7_tkCanvPs.c 1.4 644)) (Tk/generic/tkCanvPs.c (STk/a/b/7_tkCanvPs.c 1.5 644))
(Tk/generic/tkCanvText.c (STk/a/b/8_tkCanvText 1.2 644)) (Tk/generic/tkCanvText.c (STk/a/b/8_tkCanvText 1.2 644))
(Tk/generic/tkCanvUtil.c (STk/a/b/9_tkCanvUtil 1.2 644)) (Tk/generic/tkCanvUtil.c (STk/a/b/9_tkCanvUtil 1.2 644))
(Tk/generic/tkCanvWind.c (STk/a/b/10_tkCanvWind 1.2 644)) (Tk/generic/tkCanvWind.c (STk/a/b/10_tkCanvWind 1.2 644))
@ -1243,8 +1244,8 @@
;; Utilities directory ;; Utilities directory
(Utils/install-sh (STk/c/b/9_install-sh 1.1 755)) (Utils/install-sh (STk/c/b/9_install-sh 1.1 755))
(Utils/STk.spec.in (STk/e/b/20_STk.spec.i 1.17 644)) (Utils/STk.spec.in (STk/e/b/20_STk.spec.i 1.18 644))
(Utils/STk.spec (STk/e/b/21_STk.spec 1.23 644)) (Utils/STk.spec (STk/e/b/21_STk.spec 1.24 644))
;============================================================================= ;=============================================================================
; ;

View File

@ -14,7 +14,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 19-Aug-1998 14:02 ;;;; Creation date: 19-Aug-1998 14:02
;;;; Last file update: 3-Sep-1999 20:13 (eg) ;;;; Last file update: 15-Sep-1999 23:15 (eg)
(require "Tk-classes") (require "Tk-classes")
@ -81,13 +81,13 @@
(slot-set! self 'open #t) (slot-set! self 'open #t)
(if (eq? (slot-ref self 'icon) *hierarchy-node*) (if (eq? (slot-ref self 'icon) *hierarchy-node*)
(slot-set! self 'icon *hierarchy-open-node*)) (slot-set! self 'icon *hierarchy-open-node*))
(update-hierarchy (slot-ref self 'parent))) (maybe-update-hierarchy (slot-ref self 'parent)))
(define-method close-item ((self <Hierarchy-item>)) (define-method close-item ((self <Hierarchy-item>))
(slot-set! self 'open #f) (slot-set! self 'open #f)
(if (eq? (slot-ref self 'icon) *hierarchy-open-node*) (if (eq? (slot-ref self 'icon) *hierarchy-open-node*)
(slot-set! self 'icon *hierarchy-node*)) (slot-set! self 'icon *hierarchy-node*))
(update-hierarchy (slot-ref self 'parent))) (maybe-update-hierarchy (slot-ref self 'parent)))
;============================================================================= ;=============================================================================
; ;
@ -96,7 +96,8 @@
;============================================================================= ;=============================================================================
(define-class <Hierarchy-tree> (<Scroll-Canvas>) (define-class <Hierarchy-tree> (<Scroll-Canvas>)
((class :init-keyword :class :init-form "HierarchyTree") ((%redisplay :init-form #f)
(class :init-keyword :class :init-form "HierarchyTree")
(root :init-form #f) (root :init-form #f)
(items-type :init-form <Hierarchy-item> :keyword :items-type) (items-type :init-form <Hierarchy-item> :keyword :items-type)
(selection :init-form #f))) (selection :init-form #f)))
@ -107,9 +108,7 @@
(unless (member :h-scroll-side initargs) ;; no horiz scrollbar (unless (member :h-scroll-side initargs) ;; no horiz scrollbar
(set! (h-scroll-side self) #f)) (set! (h-scroll-side self) #f))
;; Create the root of the hierarchy ;; Create the root of the hierarchy
(slot-set! self 'root (add-item self #f #f #t)) ; self, ancestor, data, node (slot-set! self 'root (add-item self #f #f #t))) ;; self, ancestor, data, node
;; Refresh the widget (not completly satisfactory)
(after 'idle (lambda() (update-hierarchy self))))
;;;; ;;;;
@ -117,10 +116,13 @@
;;;; add-leave and add-node for higher level functions) ;;;; add-leave and add-node for higher level functions)
;;;; ;;;;
(define-method add-item ((self <Hierarchy-tree>) ancestor data node? icon) (define-method add-item ((self <Hierarchy-tree>) ancestor data node? icon)
(let ((ancestor (or ancestor (slot-ref self 'root))) (let* ((ancestor (or ancestor (slot-ref self 'root)))
(class (slot-ref self 'items-type))) (class (slot-ref self 'items-type))
(make class :parent self :ancestor ancestor :data data (res (make class :parent self :ancestor ancestor :data data
:node? node? :icon icon))) :node? node? :icon icon)))
(maybe-update-hierarchy self)
res))
(define-method add-item ((self <Hierarchy-tree>) ancestor data node?) (define-method add-item ((self <Hierarchy-tree>) ancestor data node?)
(add-item self ancestor data node? #f)) (add-item self ancestor data node? #f))
@ -140,7 +142,7 @@
(ancestor (slot-ref self 'ancestor)) (ancestor (slot-ref self 'ancestor))
(children (slot-ref ancestor 'children))) (children (slot-ref ancestor 'children)))
(slot-set! ancestor 'children (remove self children)) (slot-set! ancestor 'children (remove self children))
(update-hierarchy parent))) (maybe-update-hierarchy parent)))
;;;; ;;;;
;;;; Internal use methods ;;;; Internal use methods
@ -154,6 +156,22 @@
(item (slot-ref item 'label-id))) (item (slot-ref item 'label-id)))
((Id self) 'itemconfigure item :fill bg))) ((Id self) 'itemconfigure item :fill bg)))
;;
;; maybe-update-hierarchy -- retain that a hier. must be updated (if necessary)
;;
(define (maybe-update-hierarchy h)
(unless (slot-ref h '%redisplay)
;; No redisplay resquested yet. Add a request
(slot-set! h '%redisplay
(after 'idle (lambda ()
(update-hierarchy h)
(slot-set! h '%redisplay #f))))))
;; ;;
;; update-hierarchy -- display the current hierarchy ;; update-hierarchy -- display the current hierarchy
;; ;;

View File

@ -15,7 +15,7 @@
;;;; ;;;;
;;;; Author: Erick Gallesio [eg@unice.fr] ;;;; Author: Erick Gallesio [eg@unice.fr]
;;;; Creation date: 20-Feb-1994 21:09 ;;;; Creation date: 20-Feb-1994 21:09
;;;; Last file update: 3-Sep-1999 20:06 (eg) ;;;; Last file update: 27-Sep-1999 12:05 (eg)
(when (provided? "stklos") (when (provided? "stklos")
(error "STklos already initialized.")) (error "STklos already initialized."))
@ -103,7 +103,7 @@
(car default))) (car default)))
(if (is-a? name <class>) (if (is-a? name <class>)
name name
(error "find-class: bad-class" name)))) (error "find-class: bad-class ~S" name))))
;============================================================================= ;=============================================================================

View File

@ -17,7 +17,7 @@
* *
* Author: Erick Gallesio [eg@kaolin.unice.fr] * Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 23-Jan-1994 19:09 * Creation date: 23-Jan-1994 19:09
* Last file update: 3-Sep-1999 20:19 (eg) * Last file update: 14-Sep-1999 09:28 (eg)
* *
* Win32 DLL support by Steve Pruitt <steve@pruitt.net> * Win32 DLL support by Steve Pruitt <steve@pruitt.net>
* *
@ -79,15 +79,15 @@
/*----------------------------------------------------------------------------*/ /*----------------------------------------------------------------------------*/
#if (defined(WIN32) && !defined(CYGWIN32) && defined(MSC_VER)) #if (defined(WIN32) && !defined(CYGWIN32) && defined(MSC_VER))
#include <windows.h> # include <windows.h>
#include "stk.h" # include "stk.h"
#include "tclInt.h" # include "tclInt.h"
#include "tclPort.h" # include "tclPort.h"
#else #else
#include "stk.h" # include "stk.h"
#ifdef USE_DYNLOAD # ifdef USE_DYNLOAD
#include <libstack.h> # include <libstack.h>
#endif # endif
#endif #endif

View File

@ -15,7 +15,7 @@
* *
* Author: Erick Gallesio [eg@unice.fr] * Author: Erick Gallesio [eg@unice.fr]
* Creation date: ??-Oct-1993 ??:?? * Creation date: ??-Oct-1993 ??:??
* Last file update: 3-Sep-1999 20:22 (eg) * Last file update: 14-Sep-1999 09:23 (eg)
* *
*/ */
@ -68,7 +68,7 @@ static void printstring(SCM s, SCM port, int mode)
if (mode == DSP_MODE) { if (mode == DSP_MODE) {
if (strlen(p) == len) if (strlen(p) == len)
/* No null in the string. We can use a Puts, instead of the slow Putc */ /* No null in the string. We can use a Puts, instead of the slow Putc */
Puts(p, port); Puts((char *) p, port);
else else
for (len = STRSIZE(s); len; len--, p++) Putc(*p, port); for (len = STRSIZE(s); len; len--, p++) Putc(*p, port);
} else { } else {

View File

@ -16,7 +16,7 @@
* *
* Author: Erick Gallesio [eg@unice.fr] * Author: Erick Gallesio [eg@unice.fr]
* Creation date: 17-Feb-1993 12:27 * Creation date: 17-Feb-1993 12:27
* Last file update: 3-Sep-1999 20:22 (eg) * Last file update: 14-Sep-1999 09:26 (eg)
* *
* *
* This is achieved in a (surely very) dependant way. A string port is implemented * This is achieved in a (surely very) dependant way. A string port is implemented
@ -123,8 +123,8 @@ PRIMITIVE STk_get_output_string(SCM port)
if (PORT_FLAGS(port) & PORT_CLOSED) if (PORT_FLAGS(port) & PORT_CLOSED)
Err("get-output-string: string port is closed", port); Err("get-output-string: string port is closed", port);
return STk_makestrg(((struct str_iob *)PORT_FILE(port))->cnt, return STk_makestrg( ((struct str_iob *)PORT_FILE(port))->cnt,
((struct str_iob *)PORT_FILE(port))->base); (char*) ((struct str_iob *)PORT_FILE(port))->base);
} }
PRIMITIVE STk_input_string_portp(SCM port) PRIMITIVE STk_input_string_portp(SCM port)

View File

@ -1 +1 @@
#define STK_VERSION "4.0.0" #define STK_VERSION "4.0.1"

View File

@ -16,7 +16,7 @@
* *
* Author: Erick Gallesio [eg@kaolin.unice.fr] * Author: Erick Gallesio [eg@kaolin.unice.fr]
* Creation date: 29-Mar-1994 10:57 * Creation date: 29-Mar-1994 10:57
* Last file update: 3-Sep-1999 21:02 (eg) * Last file update: 15-Sep-1999 18:05 (eg)
*/ */
#ifndef WIN32 #ifndef WIN32
# include <unistd.h> # include <unistd.h>
@ -637,7 +637,8 @@ PRIMITIVE STk_setenv(SCM var, SCM value)
if (strchr(CHARS(var), '=')) Err("setenv!: variable contains a '='", var); if (strchr(CHARS(var), '=')) Err("setenv!: variable contains a '='", var);
if (NSTRINGP(value)) Err("setenv!: value is not a string", value); if (NSTRINGP(value)) Err("setenv!: value is not a string", value);
s = malloc(strlen(CHARS(var))+ strlen(CHARS(value)) + 2); /* 2 cause '=' & \0 */ s = STk_must_malloc(strlen(CHARS(var))+
strlen(CHARS(value)) + 2); /* 2 cause '=' & \0 */
sprintf(s, "%s=%s", CHARS(var), CHARS(value)); sprintf(s, "%s=%s", CHARS(var), CHARS(value));
putenv(s); putenv(s);
return UNDEFINED; return UNDEFINED;

View File

@ -650,6 +650,9 @@ TkCanvPostscriptCmd(canvasPtr, interp, argc, argv)
if (psInfo.channelName != NULL) { if (psInfo.channelName != NULL) {
int mode; int mode;
#ifdef SCM_CODE
mode = 0;
#endif
/* /*
* Check that the channel is found in this interpreter and that it * Check that the channel is found in this interpreter and that it
* is open for writing. * is open for writing.

View File

@ -1,10 +1,10 @@
%define release 1 %define release 1
Summary: Scheme Interpreter with access to the Tk toolkit Summary: Scheme Interpreter with access to the Tk toolkit
Name: STk Name: STk
Version: 4.0.0 Version: 4.0.1
Release: %{release} Release: %{release}
Copyright: distributable Copyright: distributable
Source: STk-4.0.0.tar.gz Source: STk-4.0.1.tar.gz
Group: Development/Languages Group: Development/Languages
Packager: Erick Gallesio <eg@unice.fr> Packager: Erick Gallesio <eg@unice.fr>
BuildRoot: /tmp/STk BuildRoot: /tmp/STk
@ -12,7 +12,7 @@ BuildRoot: /tmp/STk
%package devel %package devel
Summary: Header files and libraries for STk Summary: Header files and libraries for STk
Group: Development/Libraries Group: Development/Libraries
Requires: STk = 4.0.0 Requires: STk = 4.0.1
%description %description
STk is a R4RS Scheme interpreter which can access the Tk graphical STk is a R4RS Scheme interpreter which can access the Tk graphical
@ -79,24 +79,25 @@ rm -f /usr/local/lib/stk/include
%files %files
%doc README INSTALL CHANGES ChangeLog %doc README INSTALL CHANGES ChangeLog
/usr/local/lib/stk/4.0.0/Demos /usr/local/lib/stk/4.0.1/Demos
/usr/local/lib/stk/4.0.0/Help /usr/local/lib/stk/4.0.1/Help
/usr/local/lib/stk/4.0.0/Images /usr/local/lib/stk/4.0.1/Images
/usr/local/lib/stk/4.0.0/%{machine}/stk /usr/local/lib/stk/4.0.1/%{machine}/stk
/usr/local/lib/stk/4.0.0/%{machine}/snow /usr/local/lib/stk/4.0.1/%{machine}/snow
/usr/local/lib/stk/4.0.0/%{machine}/*.so /usr/local/lib/stk/4.0.1/%{machine}/*.so
/usr/local/lib/stk/4.0.0/STk /usr/local/lib/stk/4.0.1/STk
/usr/local/lib/stk/4.0.0/include /usr/local/lib/stk/4.0.1/include
/usr/local/lib/stk/4.0.0/man /usr/local/lib/stk/4.0.1/man
/usr/local/bin/stk-4.0.0 /usr/local/bin/stk-4.0.1
/usr/local/bin/snow-4.0.0 /usr/local/bin/snow-4.0.1
/usr/local/bin/stk /usr/local/bin/stk
/usr/local/bin/snow /usr/local/bin/snow
/usr/local/doc/stk-4.0.1
%files devel %files devel
/usr/local/lib/stk/4.0.0/%{machine}/Config /usr/local/lib/stk/4.0.1/%{machine}/Config
/usr/local/lib/stk/4.0.0/%{machine}/Libs /usr/local/lib/stk/4.0.1/%{machine}/Libs

View File

@ -95,6 +95,7 @@ rm -f @prefix@/lib/stk/include
@prefix@/bin/stk @prefix@/bin/stk
@prefix@/bin/snow @prefix@/bin/snow
@prefix@/doc/stk-@VERSION@
%files devel %files devel

View File

@ -1 +1 @@
VERSION=4.0.0 VERSION=4.0.1

132
configure vendored
View File

@ -1,7 +1,7 @@
#! /bin/sh #! /bin/sh
# Guess values for system-dependent variables and create Makefiles. # Guess values for system-dependent variables and create Makefiles.
# Generated automatically using autoconf version 2.13 # Generated automatically using autoconf version 2.14.1
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
# #
# This configure script is free software; the Free Software Foundation # This configure script is free software; the Free Software Foundation
@ -365,7 +365,7 @@ EOF
verbose=yes ;; verbose=yes ;;
-version | --version | --versio | --versi | --vers) -version | --version | --versio | --versi | --vers)
echo "configure generated by autoconf version 2.13" echo "configure generated by autoconf version 2.14.1"
exit 0 ;; exit 0 ;;
-with-* | --with-*) -with-* | --with-*)
@ -525,7 +525,7 @@ done
if test -r "$cache_file"; then if test -r "$cache_file"; then
echo "loading cache $cache_file" echo "loading cache $cache_file"
. $cache_file test -f "$cache_file" && . $cache_file
else else
echo "creating cache $cache_file" echo "creating cache $cache_file"
> $cache_file > $cache_file
@ -554,7 +554,7 @@ fi
VERSION=4.0.0 VERSION=4.0.1
echo "VERSION=$VERSION" > VERSION echo "VERSION=$VERSION" > VERSION
echo "/* File generated. DO NOT EDIT */" > Src/stkvers.h echo "/* File generated. DO NOT EDIT */" > Src/stkvers.h
echo "#define STK_VERSION \"$VERSION\"" > Src/stkvers.h echo "#define STK_VERSION \"$VERSION\"" > Src/stkvers.h
@ -639,7 +639,7 @@ fi
set dummy ranlib; ac_word=$2 set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:642: checking for $ac_word" >&5 echo "configure:642: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_RANLIB+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
if test -n "$RANLIB"; then if test -n "$RANLIB"; then
@ -710,7 +710,7 @@ echo "Assumming OS is $OS"
set dummy gcc; ac_word=$2 set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:713: checking for $ac_word" >&5 echo "configure:713: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
if test -n "$CC"; then if test -n "$CC"; then
@ -740,7 +740,7 @@ if test -z "$CC"; then
set dummy cc; ac_word=$2 set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:743: checking for $ac_word" >&5 echo "configure:743: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
if test -n "$CC"; then if test -n "$CC"; then
@ -786,12 +786,12 @@ fi
if test -z "$CC"; then if test -z "$CC"; then
case "`uname -s`" in case "`uname -s`" in
*win32* | *WIN32*) *win32* | *WIN32* | *CYGWIN*)
# Extract the first word of "cl", so it can be a program name with args. # Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2 set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:794: checking for $ac_word" >&5 echo "configure:794: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_CC+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
if test -n "$CC"; then if test -n "$CC"; then
@ -821,8 +821,8 @@ fi
test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
fi fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works""... $ac_c" 1>&6
echo "configure:826: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 echo "configure:826: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) works" >&5
ac_ext=c ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@ -863,14 +863,14 @@ echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
if test $ac_cv_prog_cc_works = no; then if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
echo "configure:868: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 echo "configure:868: checking whether the C compiler ($CC $CFLAGS $CPPFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
echo "configure:873: checking whether we are using GNU C" >&5 echo "configure:873: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_gcc+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.c <<EOF cat > conftest.c <<EOF
@ -898,7 +898,7 @@ ac_save_CFLAGS="$CFLAGS"
CFLAGS= CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
echo "configure:901: checking whether ${CC-cc} accepts -g" >&5 echo "configure:901: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_cc_g+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
echo 'void f(){}' > conftest.c echo 'void f(){}' > conftest.c
@ -956,7 +956,7 @@ if test -n "$CPP" && test -d "$CPP"; then
CPP= CPP=
fi fi
if test -z "$CPP"; then if test -z "$CPP"; then
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then if eval "test \"\${ac_cv_prog_CPP+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
# This must be in double quotes, not single quotes, because CPP may get # This must be in double quotes, not single quotes, because CPP may get
@ -1051,7 +1051,7 @@ else
# Both variables are already set. # Both variables are already set.
have_x=yes have_x=yes
else else
if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then if eval "test \"\${ac_cv_have_x+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
# One or both of the vars are not set, and there is no cached value. # One or both of the vars are not set, and there is no cached value.
@ -1350,7 +1350,7 @@ rm -f conftest*
echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6 echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
echo "configure:1352: checking for dnet_ntoa in -ldnet" >&5 echo "configure:1352: checking for dnet_ntoa in -ldnet" >&5
ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'` ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
@ -1391,7 +1391,7 @@ fi
echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6 echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
echo "configure:1393: checking for dnet_ntoa in -ldnet_stub" >&5 echo "configure:1393: checking for dnet_ntoa in -ldnet_stub" >&5
ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'` ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
@ -1438,7 +1438,7 @@ fi
# on Irix 5.2, according to dickey@clark.net. # on Irix 5.2, according to dickey@clark.net.
echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
echo "configure:1441: checking for gethostbyname" >&5 echo "configure:1441: checking for gethostbyname" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then if eval "test \"\${ac_cv_func_gethostbyname+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
@ -1451,6 +1451,7 @@ else
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */ builtin and then its argument prototype would still apply. */
char gethostbyname(); char gethostbyname();
char (*f)();
int main() { int main() {
@ -1460,12 +1461,12 @@ int main() {
#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
choke me choke me
#else #else
gethostbyname(); f = gethostbyname;
#endif #endif
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_gethostbyname=yes" eval "ac_cv_func_gethostbyname=yes"
else else
@ -1486,15 +1487,15 @@ fi
if test $ac_cv_func_gethostbyname = no; then if test $ac_cv_func_gethostbyname = no; then
echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
echo "configure:1490: checking for gethostbyname in -lnsl" >&5 echo "configure:1491: checking for gethostbyname in -lnsl" >&5
ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'` ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS" LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1498 "configure" #line 1499 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */ /* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
@ -1505,7 +1506,7 @@ int main() {
gethostbyname() gethostbyname()
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1510: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes" eval "ac_cv_lib_$ac_lib_var=yes"
else else
@ -1535,12 +1536,12 @@ fi
# -lsocket must be given before -lnsl if both are needed. # -lsocket must be given before -lnsl if both are needed.
# We assume that if connect needs -lnsl, so does gethostbyname. # We assume that if connect needs -lnsl, so does gethostbyname.
echo $ac_n "checking for connect""... $ac_c" 1>&6 echo $ac_n "checking for connect""... $ac_c" 1>&6
echo "configure:1539: checking for connect" >&5 echo "configure:1540: checking for connect" >&5
if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then if eval "test \"\${ac_cv_func_connect+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1544 "configure" #line 1545 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char connect(); below. */ which can conflict with char connect(); below. */
@ -1549,6 +1550,7 @@ else
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */ builtin and then its argument prototype would still apply. */
char connect(); char connect();
char (*f)();
int main() { int main() {
@ -1558,12 +1560,12 @@ int main() {
#if defined (__stub_connect) || defined (__stub___connect) #if defined (__stub_connect) || defined (__stub___connect)
choke me choke me
#else #else
connect(); f = connect;
#endif #endif
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_connect=yes" eval "ac_cv_func_connect=yes"
else else
@ -1584,15 +1586,15 @@ fi
if test $ac_cv_func_connect = no; then if test $ac_cv_func_connect = no; then
echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6 echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
echo "configure:1588: checking for connect in -lsocket" >&5 echo "configure:1590: checking for connect in -lsocket" >&5
ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'` ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lsocket $X_EXTRA_LIBS $LIBS" LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1596 "configure" #line 1598 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */ /* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
@ -1603,7 +1605,7 @@ int main() {
connect() connect()
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1607: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes" eval "ac_cv_lib_$ac_lib_var=yes"
else else
@ -1627,12 +1629,12 @@ fi
# gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX. # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
echo $ac_n "checking for remove""... $ac_c" 1>&6 echo $ac_n "checking for remove""... $ac_c" 1>&6
echo "configure:1631: checking for remove" >&5 echo "configure:1633: checking for remove" >&5
if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then if eval "test \"\${ac_cv_func_remove+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1636 "configure" #line 1638 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char remove(); below. */ which can conflict with char remove(); below. */
@ -1641,6 +1643,7 @@ else
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */ builtin and then its argument prototype would still apply. */
char remove(); char remove();
char (*f)();
int main() { int main() {
@ -1650,12 +1653,12 @@ int main() {
#if defined (__stub_remove) || defined (__stub___remove) #if defined (__stub_remove) || defined (__stub___remove)
choke me choke me
#else #else
remove(); f = remove;
#endif #endif
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1662: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_remove=yes" eval "ac_cv_func_remove=yes"
else else
@ -1676,15 +1679,15 @@ fi
if test $ac_cv_func_remove = no; then if test $ac_cv_func_remove = no; then
echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6 echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
echo "configure:1680: checking for remove in -lposix" >&5 echo "configure:1683: checking for remove in -lposix" >&5
ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'` ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lposix $LIBS" LIBS="-lposix $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1688 "configure" #line 1691 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */ /* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
@ -1695,7 +1698,7 @@ int main() {
remove() remove()
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes" eval "ac_cv_lib_$ac_lib_var=yes"
else else
@ -1719,12 +1722,12 @@ fi
# BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
echo $ac_n "checking for shmat""... $ac_c" 1>&6 echo $ac_n "checking for shmat""... $ac_c" 1>&6
echo "configure:1723: checking for shmat" >&5 echo "configure:1726: checking for shmat" >&5
if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then if eval "test \"\${ac_cv_func_shmat+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1728 "configure" #line 1731 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char shmat(); below. */ which can conflict with char shmat(); below. */
@ -1733,6 +1736,7 @@ else
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */ builtin and then its argument prototype would still apply. */
char shmat(); char shmat();
char (*f)();
int main() { int main() {
@ -1742,12 +1746,12 @@ int main() {
#if defined (__stub_shmat) || defined (__stub___shmat) #if defined (__stub_shmat) || defined (__stub___shmat)
choke me choke me
#else #else
shmat(); f = shmat;
#endif #endif
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_shmat=yes" eval "ac_cv_func_shmat=yes"
else else
@ -1768,15 +1772,15 @@ fi
if test $ac_cv_func_shmat = no; then if test $ac_cv_func_shmat = no; then
echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6 echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
echo "configure:1772: checking for shmat in -lipc" >&5 echo "configure:1776: checking for shmat in -lipc" >&5
ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'` ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lipc $LIBS" LIBS="-lipc $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1780 "configure" #line 1784 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */ /* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
@ -1787,7 +1791,7 @@ int main() {
shmat() shmat()
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes" eval "ac_cv_lib_$ac_lib_var=yes"
else else
@ -1820,15 +1824,15 @@ fi
# libraries we check for below, so use a different variable. # libraries we check for below, so use a different variable.
# --interran@uluru.Stanford.EDU, kb@cs.umb.edu. # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6 echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
echo "configure:1824: checking for IceConnectionNumber in -lICE" >&5 echo "configure:1828: checking for IceConnectionNumber in -lICE" >&5
ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'` ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then if eval "test \"\${ac_cv_lib_$ac_lib_var+set}\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lICE $X_EXTRA_LIBS $LIBS" LIBS="-lICE $X_EXTRA_LIBS $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1832 "configure" #line 1836 "configure"
#include "confdefs.h" #include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */ /* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2 /* We use char because int might match the return type of a gcc2
@ -1839,7 +1843,7 @@ int main() {
IceConnectionNumber() IceConnectionNumber()
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then if { (eval echo configure:1847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes" eval "ac_cv_lib_$ac_lib_var=yes"
else else
@ -1891,16 +1895,16 @@ XLIBSW="$XLIBSW $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
#-------------------------------------------------------------------- #--------------------------------------------------------------------
echo $ac_n "checking fd_set and sys/select""... $ac_c" 1>&6 echo $ac_n "checking fd_set and sys/select""... $ac_c" 1>&6
echo "configure:1895: checking fd_set and sys/select" >&5 echo "configure:1899: checking fd_set and sys/select" >&5
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1897 "configure" #line 1901 "configure"
#include "confdefs.h" #include "confdefs.h"
#include <sys/types.h> #include <sys/types.h>
int main() { int main() {
fd_set readMask, writeMask; fd_set readMask, writeMask;
; return 0; } ; return 0; }
EOF EOF
if { (eval echo configure:1904: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then if { (eval echo configure:1908: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest* rm -rf conftest*
tk_ok=yes tk_ok=yes
else else
@ -1912,7 +1916,7 @@ fi
rm -f conftest* rm -f conftest*
if test $tk_ok = no; then if test $tk_ok = no; then
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1916 "configure" #line 1920 "configure"
#include "confdefs.h" #include "confdefs.h"
#include <sys/select.h> #include <sys/select.h>
EOF EOF
@ -2414,7 +2418,7 @@ trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
# Protect against shell expansion while executing Makefile rules. # Protect against shell expansion while executing Makefile rules.
# Protect against Makefile macro expansion. # Protect against Makefile macro expansion.
cat > conftest.defs <<\EOF cat > conftest.defs <<\EOF
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g s%#define \([^ ][^ ]*\) *\(.*\)%-D\1=\2%g
s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
s%\[%\\&%g s%\[%\\&%g
s%\]%\\&%g s%\]%\\&%g
@ -2449,7 +2453,7 @@ do
echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
-version | --version | --versio | --versi | --vers | --ver | --ve | --v) -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
echo "$CONFIG_STATUS generated by autoconf version 2.13" echo "$CONFIG_STATUS generated by autoconf version 2.14.1"
exit 0 ;; exit 0 ;;
-help | --help | --hel | --he | --h) -help | --help | --hel | --he | --h)
echo "\$ac_cs_usage"; exit 0 ;; echo "\$ac_cs_usage"; exit 0 ;;
@ -2623,7 +2627,7 @@ exit 0
EOF EOF
chmod +x $CONFIG_STATUS chmod +x $CONFIG_STATUS
rm -fr confdefs* $ac_clean_files rm -fr confdefs* $ac_clean_files
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 test "$no_create" = yes || $SHELL $CONFIG_STATUS || exit 1

View File

@ -5,7 +5,7 @@ dnl to configure the system for the local environment.
AC_INIT(README) AC_INIT(README)
VERSION=4.0.0 VERSION=4.0.1
echo "VERSION=$VERSION" > VERSION echo "VERSION=$VERSION" > VERSION
echo "/* File generated. DO NOT EDIT */" > Src/stkvers.h echo "/* File generated. DO NOT EDIT */" > Src/stkvers.h
echo "#define STK_VERSION \"$VERSION\"" > Src/stkvers.h echo "#define STK_VERSION \"$VERSION\"" > Src/stkvers.h