stk/Demos/filebox.stklos

36 lines
1.3 KiB
Plaintext
Raw Normal View History

1998-04-10 06:59:06 -04:00
#!/bin/sh
:;exec /usr/local/bin/stk -f "$0" "$@"
;;;;
1996-09-27 06:29:02 -04:00
;;;; f i l e b o x . s t k l o s -- A demo of the <FileBox> class
;;;;
1999-02-02 06:13:40 -05:00
;;;; Copyright <20> 1993-1999 Erick Gallesio - I3S-CNRS/ESSI <eg@unice.fr>
1996-09-27 06:29:02 -04:00
;;;;
;;;; Permission to use, copy, and/or distribute this software and its
;;;; documentation for any purpose and without fee is hereby granted, provided
;;;; that both the above copyright notice and this permission notice appear in
;;;; all copies and derived works. Fees for distribution or use of this
;;;; software or derived works may only be charged with express written
;;;; permission of the copyright holder.
;;;; This software is provided ``as is'' without express or implied warranty.
;;;;
;;;; This software is a derivative work of other copyrighted softwares; the
;;;; copyright notices of these softwares are placed in the file COPYRIGHTS
;;;;
1999-02-02 06:13:40 -05:00
;;;; $Id: filebox.stklos 1.3 Tue, 02 Feb 1999 15:29:27 +0100 eg $
1998-04-10 06:59:06 -04:00
;;;;
1996-09-27 06:29:02 -04:00
;;;; Author: Erick Gallesio [eg@kaolin.unice.fr]
;;;; Creation date: 12-Jun-1994 11:24
1999-02-02 06:13:40 -05:00
;;;; Last file update: 2-Feb-1999 13:56
1996-09-27 06:29:02 -04:00
(require "Tk-classes")
1998-04-10 06:59:06 -04:00
;; Just create a filebox and return the selected value
1999-02-02 06:13:40 -05:00
(let ((result (Tk:get-open-file)))
1996-09-27 06:29:02 -04:00
(apply format #t (if result
(list "You have selected the file ~S\n" result)
(list "CANCEL. No file selected\n")))
1998-04-10 06:59:06 -04:00
(exit 0))
1996-09-27 06:29:02 -04:00