[ltk-user] run-time error => Invalid initialization argument: :FONT

haruichi yabuki hyabuki at zb.ztv.ne.jp
Fri Nov 9 01:33:11 UTC 2012


Hi, ltk-users,

I am very much troubled by the following situation.
Can someone help me?

The program below gives the error message at run-time:

>  Invalid initialization argument:
>    :FONT
>  in call for class #<STANDARD-CLASS BUTTON>.
>  See also:
>    The ANSI Standard, Section 7.1.2
>    [Condition of type INITARG-ERROR]

The program is as follos:
-------------------------------------------------------------
(asdf:operate 'asdf:load-op :ltk :verbose nil)
(defpackage :ltk-user
  (:use :common-lisp :cl-user :ltk))
(in-package :ltk-user)
(with-ltk ()
  (wm-title *tk* "an example of button")
  (bind *tk* "<Alt-q>" (lambda (event) (setf *exit-mainloop* t)))
  (let ((btn (make-instance 'button
                            :master nil
                            :text "BUTTON"
                            :font "verdana 20"
                            :command (lambda ()
                                       (format t "the button is pushed.~%")
                                       (setf *exit-mainloop* t)))))
;    (configure btn :font "verdana 20")
    (pack btn)))
;; end
-----------------------------------------------------------------
(without the line
    :font "verdana 20"
 the program works fine.)

 
My environement is as follows:
OS:   Ubuntu 12.04
$ sbcl --version
SBCL 1.0.55.0.debian
$ wish
% puts $tcl_version
8.5


It seems to me that many options of tk give this kind of error messages
everywhere in my 'wrong' programming environement! 
The above is one of the simple examples.
I would like to know how to fix the problem.
Thank you in advance.
--
haruichi yabuki <hyabuki at zb.ztv.ne.jp>




More information about the ltk-user mailing list