CLIM mail archive

[Prev][Next][Index][Thread]

Trouble with ACCEPTING-VALUES buttons



Platform: CLIM 2.0beta2, ACL 4.2beta, HPs700.

I'm mystified. I have an accepting-values menu that consistently creates
radio-buttons when what I want to specify are check-buttons. I.e. when I
click on one of the buttons, other buttons will be reset. There is an
example among the clim2 demos in the ACL distribution, test-suite.lisp,
with the header:

  ;; $fiHeader: test-suite.lisp,v 1.61 93/04/16 09:45:40 cer Exp $

that does exactly what I want, I think. The below, non-functional code
is almost identical. What's wrong with it? I've tried +check-box-view+
in the accept without any luck.

  (defparameter
      *special-features-list*
    '((:label "Reconfigure On-line Modules"
       :value reconfigure-on-line-modules
       :documentation
       "Set up new parameter values for On-line modules")
      (:label "Bypass IC: Start Sybase Poller Process"
       :value ic-bypass
       :documentation
       "Starts a process polling for EFD alarms stored in Sybase")
      #+ignore etc...))

  (defun special-features ()
  #+ignore blablabla...

  (restart-case
      (accepting-values (stream :own-window t :label "Special Features")
        (mapc
         #'(lambda (sf-plist)
             (let ((value (getf sf-plist :value))
                   (doc (getf sf-plist :documentation))
                   (label (getf sf-plist :label)))
               (set value
                    (accept 'boolean
                            :stream stream
                            :view +gadget-dialog-view+
                            :default NIL
                            :prompt label))
               (terpri stream)
               (with-drawing-options (stream
                                      :text-style fix-bold-normal-font
                                      :ink +blue+)
                 (format stream "~&(~A)~%" doc))))
         *special-features-list*))
    (abort ()
      ;; (format (frame-error-output frame) "~&Nothing happens")
      (return-from special-features nil)))


fix-bold-normal-font is just a param:

  (defparameter fix-bold-normal-font
      (let ((ts (make-text-style :fix :bold :normal)))
	(setf (text-style-mapping (find-port) ts) "*-bold-r-*-*-18-*")
	ts))

 ---000---

While I'm wasting all this bandwidth: Is it possible to change the
background and foreground colors of the :own-window accepting-values
menu? I've tried specializing the class CLIM:ACCEPT-VALUES with
:background and :foreground slots and supplied it in the :frame-class
option to accepting-values, to no avail.

Thanks.

Eyvind.


~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
  Eyvind Ness         Internet: Eyvind.Ness@HRP.No
  Research Scientist  Voicenet: +47 69 183100 ext. 275
  CRS Division        Faxnet:   +47 69 187109
  OECD HRP            Papernet: PO Box 173, N-1751 Halden, Norway

~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~

Follow-Ups:

Main Index | Thread Index