6 class Group(widget
.Widget
):
7 """An object for grouping together Form elements.
9 <pre>Group(name=None,value=None)</pre>
12 <dt>name<dd>name as used in the Form
13 <dt>value<dd>values that are currently selected in the group
16 <p>See [[gui-button]] for several examples.</p>
18 <p>When the value changes, an <tt>gui.CHANGE</tt> event is sent.
19 Although note, that when the value is a list, it may have to be sent by hand via
20 <tt>g.send(gui.CHANGE)</tt></p>
23 def __init__(self
,name
=None,value
=None):
24 widget
.Widget
.__init
__(self
,name
=name
,value
=value
)
28 """Add a widget to this group.
30 <pre>Group.add(w)</pre>
32 self
.widgets
.append(w
)
34 def __setattr__(self
,k
,v
):
35 _v
= self
.__dict
__.get(k
,NOATTR
)
37 if k
== 'value' and _v
!= NOATTR
and _v
!= v
:
42 for w
in self
.widgets
: