get-focus

From: Clifford Beshers <beshers_at_cs.columbia.edu>
Date: Thu, 15 Feb 1996 14:09:37 -0500

In my recent HP installation, the function (get-focus) doesn't seem to
get defined. I can find no reference to it in the code.

If I make an error, STk tries to pop up it's error dialog, but it
can't because get-focus isn't defined.

Where is it defined? Is the definition generated? Can someone give
me a clue?

I think I have a problem with the linking and/or loading, but it is
very hard to track down when I can't find the function definitions.

Thanks,

Cliff

****************************************************************


Here's is what I see:

> stk
Welcome to the STk interpreter version 3.0b2 [HP-UX-9.X-9000s700]
Copyright (C) 1993,1994,1995 Erick Gallesio - I3S - CNRS / ESSI <eg_at_unice.fr>
STk> (require "Tk-classes")
"Tk-classes"
STk> (require "dialog")
"dialog"
STk> (define c (make <Canvas))

*** Error:
unbound variable: <canvas

*** Error:
unbound variable: get-focus
WARNING: report-error is buggy!!

*** Error:
    unbound variable: get-focus
Current eval stack:
__________________
  0 (get-focus)
  1 (set! stk::dialog-old-focus (get-focus))
  2 (let ((w (get-keyword :window arguments (quote .dialog))) (title (get-keyword :title arguments "Dialog")) (text (get-keyword :text arguments "")) (bitmap (get-keyword :bitmap arguments "")) (default (get-keyword :default arguments -1)) (grabbing (get-keyword :grab arguments #f)) (buttons (get-keyword :buttons arguments (quote ())))) (catch (destroy w)) (%syntax-define w.top (& w ".top")) (%syntax-define w.bot (& w ".bot")) (%syntax-define w.msg (& w ".msg")) (%syntax-define w.bmp (& w ".bmp")) (toplevel w :class "Dialog") (wm (quote title) w title) (wm (quote iconname) w "Dialog") (pack (frame w.top :relief "raised" :bd 1) (frame w.bot :relief "raised" :bd 1) :fill "both") (pack (message w.msg :aspect 1000 :text text :font "-Adobe-Times-Medium-R-Normal-*-180-*") :in w.top :side "right" :expand #t :fill "both" :padx "5m" :pady "5m") (if (not (equal? bitmap "")) (pack (label w.bmp :bitmap bitmap :fg "red") :in w.top :side "left" :padx "5m" :pady "5m")) (letrec ((|G2| (l!
 am!
bda (i but) (if (null? but) (begin (quote ())) (begin (let ((name (& w ".button" i))) (button name :text (caar but) :command (quasiquote (begin (focus stk::dialog-old-focus) (set! stk::button-pressed (unquote i)) (destroy (string->widget (unquote (& w)))) (apply (unquote (cadar but)) (quote ()))))) (if (equal? i default) (let ((default (& w ".default"))) (frame default :relief "ridge" :bd 3) (raise name default) (pack default :in w.bot :side "left" :expand #t :padx 20 :pady 8) (pack name :in default :padx 5 :pady 5 :ipadx 2 :ipady 2) (bind w "<Return>" ((string->widget name) (quote cget) :command))) (pack name :in w.bot :side "left" :expand 1 :padx 20 :pady 8 :ipadx 2 :ipady 2))) (|G2| (+ i 1) (cdr but))))))) (|G2| 0 buttons)) (stk:center-window w) (set! stk::dialog-old-focus (get-focus)) (focus w) (if grabbing (tkwait (quote variable) (quote stk::button-pressed))) (update) stk::button-pressed)
  3 (get-focus)
  4 (set! stk::dialog-old-focus (get-focus))
  5 (let ((w (get-keyword :window arguments (quote .dialog))) (title (get-keyword :title arguments "Dialog")) (text (get-keyword :text arguments "")) (bitmap (get-keyword :bitmap arguments "")) (default (get-keyword :default arguments -1)) (grabbing (get-keyword :grab arguments #f)) (buttons (get-keyword :buttons arguments (quote ())))) (catch (destroy w)) (%syntax-define w.top (& w ".top")) (%syntax-define w.bot (& w ".bot")) (%syntax-define w.msg (& w ".msg")) (%syntax-define w.bmp (& w ".bmp")) (toplevel w :class "Dialog") (wm (quote title) w title) (wm (quote iconname) w "Dialog") (pack (frame w.top :relief "raised" :bd 1) (frame w.bot :relief "raised" :bd 1) :fill "both") (pack (message w.msg :aspect 1000 :text text :font "-Adobe-Times-Medium-R-Normal-*-180-*") :in w.top :side "right" :expand #t :fill "both" :padx "5m" :pady "5m") (if (not (equal? bitmap "")) (pack (label w.bmp :bitmap bitmap :fg "red") :in w.top :side "left" :padx "5m" :pady "5m")) (letrec ((|G2| (l!
 am!
bda (i but) (if (null? but) (begin (quote ())) (begin (let ((name (& w ".button" i))) (button name :text (caar but) :command (quasiquote (begin (focus stk::dialog-old-focus) (set! stk::button-pressed (unquote i)) (destroy (string->widget (unquote (& w)))) (apply (unquote (cadar but)) (quote ()))))) (if (equal? i default) (let ((default (& w ".default"))) (frame default :relief "ridge" :bd 3) (raise name default) (pack default :in w.bot :side "left" :expand #t :padx 20 :pady 8) (pack name :in default :padx 5 :pady 5 :ipadx 2 :ipady 2) (bind w "<Return>" ((string->widget name) (quote cget) :command))) (pack name :in w.bot :side "left" :expand 1 :padx 20 :pady 8 :ipadx 2 :ipady 2))) (|G2| (+ i 1) (cdr but))))))) (|G2| 0 buttons)) (stk:center-window w) (set! stk::dialog-old-focus (get-focus)) (focus w) (if grabbing (tkwait (quote variable) (quote stk::button-pressed))) (update) stk::button-pressed)
...
Received on Thu Feb 15 1996 - 20:14:07 CET

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST