CLIM mail archive

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

Can gadgets be deactivated?



    Date: Fri, 2 Oct 1992 14:29 EDT
    From: Jeff Morrill <jmorrill@BBN.COM>

    I am trying to implement a hierarchical dialog box.  At the top
    level, it is a "radio box", in other words a mutually exclusive
    set of four choices.  Under each top-level choice is a couple of
    toggle buttons that control options related to the choice.  Like this:

     Choose a Beverage:
       o Coffee
	   x Decaf
	   x Colombian
       o Tea
	   x Herbal
       o Beer
	   x Light
	   x Imported
       o Milk
	   x Skim

    What I would like is to deactivate some of the toggle buttons
    when they don't apply.  So if the user picks "Tea", the only
    active toggle button would be "Herbal".  By deactivate, I
    mean that it loses its mouse-sensitivity and it goes gray.

Yes, in the soon-to-be-released (really!) CLIM 2.0 Beta, there are two
functions, ACTIVATE-GADGET and DEACTIVATE-GADGET, that do exactly what
you want.  Deactivation prevents any sort of "active" gesture (such as
sliding a slider, or pushing a pushbutton), and, on toolkits that
support it, cause some sort of visual indication that the gadget has
been deactivated (typically, "graying over").

    Its purpose is analogous to the :ACTIVE menu-item
    option to MENU-CHOOSE in clim 2.

    I'm not only interested in deactivating toggle buttons, but in
    every sort of gadget (text, scrolling-list, radio-box, ...).
    The underlying toolkits apparently support this behavior at least
    some of the time.  I can't think of any approach that's not more
    trouble than its worth.  Has anybody done this?


0,,

References:

Main Index | Thread Index