NextPrevUpTopContentsIndex

4.5.3 Radio buttons

Radio buttons can be created explicitly although they are usually part of a button panel as described in Choices. The :selected keyword is used to specify whether or not the button is selected, and the :text keyword can be used to label the button.

(contain (make-instance 'radio-button
                        :text "Radio Button"
                        :selected t))

Figure 4.7 An explicitly created radio button

Although a single radio button is of limited use, having an explicit radio button class gives you greater flexibility, since associated radio buttons need not be physically grouped together. Generally, the easiest way of creating a group of radio buttons is by using a button panel, but doing so means that they will be geometrically, as well as semantically, connected.

 


LispWorks CAPI User Guide (Macintosh version) - 17 Mar 2008

NextPrevUpTopContentsIndex