home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 3: Developer Tools / Linux Cubed Series 3 - Developer Tools.iso / devel / lang / lisp / stk-3.002 / stk-3 / STk-3.1 / Demos / Widget / Wdialog1.stklos < prev    next >
Encoding:
Text File  |  1995-09-16  |  803 b   |  19 lines

  1. ;;;;
  2. ;;;; STk adaptation of the Tk widget demo.
  3. ;;;;
  4. ;;;;  This demonstration script creates a dialog box with a local grab.
  5. ;;;;
  6.  
  7.  
  8. (define (demo-dialog1)
  9.   (STk:make-dialog :title "Dialog with local grab" 
  10.            :text  "This is a modal dialog box. It uses Tk's \"grab\" command to create a \"local grab\" on the dialog box. The grab prevents any pointer-related events from getting to any other windows in the application until you have answered the dialog by invoking one of the buttons below. However, you can still interact with other applications."
  11.            :bitmap "info"
  12.            :default 0
  13.            :grab    #t
  14.            :buttons 
  15.               `(("OK"       ,(lambda () (display "You pressed OK\n")))
  16.             ("Cancel"   ,(lambda () (display "You pressed Cancel\n")))
  17.             ("See Code" ,(lambda () (show-code "dialog1"))))))
  18.  
  19.