CheckBox.st
author Claus Gittinger <cg@exept.de>
Sun, 17 Dec 1995 14:28:56 +0100
changeset 114 bd13b6f557ea
parent 112 bb2cb6c553d2
child 115 0147e9d06caa
permissions -rw-r--r--
access methods for colors
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     1
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     2
 COPYRIGHT (c) 1995 by Claus Gittinger
49
claus
parents: 44
diff changeset
     3
	      All Rights Reserved
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     4
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     5
 This software is furnished under a license and may be used
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     6
 only in accordance with the terms of that license and with the
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     7
 inclusion of the above copyright notice.   This software may not
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     8
 be provided or otherwise made available to, or used by, any
97c1c943bef6 Initial revision
claus
parents:
diff changeset
     9
 other person.  No title to or ownership of the software is
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    10
 hereby transferred.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    11
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    12
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    13
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    14
HorizontalPanelView subclass:#CheckBox
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
    15
	instanceVariableNames:'toggleView labelView labelForegroundColor
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
    16
		disabledLabelForegroundColor'
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
    17
	classVariableNames:'DefaultLabelForegroundColor DefaultDisabledLabelForegroundColor'
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
    18
	poolDictionaries:''
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
    19
	category:'Views-Interactors'
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    20
!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    21
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    22
!CheckBox class methodsFor:'documentation'!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    23
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    24
copyright
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    25
"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    26
 COPYRIGHT (c) 1995 by Claus Gittinger
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    27
	      All Rights Reserved
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    28
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    29
 This software is furnished under a license and may be used
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    30
 only in accordance with the terms of that license and with the
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    31
 inclusion of the above copyright notice.   This software may not
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    32
 be provided or otherwise made available to, or used by, any
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    33
 other person.  No title to or ownership of the software is
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    34
 hereby transferred.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    35
"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
    36
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    37
!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    38
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    39
documentation
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    40
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    41
    CheckBox has been added somwehat in a hurry 
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    42
    - obviously, much more protocol is needed.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    43
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    44
    For now, set actions etc. via sends to the components,
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    45
    labelView and toggleView.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    46
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    47
!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    48
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    49
examples
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    50
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    51
  no-op checkBox:
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    52
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    53
     |b|
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    54
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    55
     b := CheckBox new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    56
     b label:'foo'.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    57
     b open
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    58
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    59
56
claus
parents: 55
diff changeset
    60
  no-op checkBox, disabled:
claus
parents: 55
diff changeset
    61
claus
parents: 55
diff changeset
    62
     |b|
claus
parents: 55
diff changeset
    63
claus
parents: 55
diff changeset
    64
     b := CheckBox new.
claus
parents: 55
diff changeset
    65
     b label:'foo'.
claus
parents: 55
diff changeset
    66
     b disable.
claus
parents: 55
diff changeset
    67
     b open
claus
parents: 55
diff changeset
    68
claus
parents: 55
diff changeset
    69
claus
parents: 55
diff changeset
    70
  changing colors 
claus
parents: 55
diff changeset
    71
  (a demo only: it is no good style to fight the styleSheet):
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    72
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    73
     |panel b|
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    74
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    75
     panel := VerticalPanelView new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    76
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    77
     b := CheckBox in:panel.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    78
     b label:'foo'.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    79
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    80
     b := CheckBox in:panel.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    81
     b label:'bar'.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    82
     b labelView foregroundColor:Color red.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    83
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    84
     b := CheckBox in:panel.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    85
     b label:'baz'.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    86
     b toggleView activeForegroundColor:Color blue.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    87
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    88
     panel open
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    89
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    90
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    91
  using action-blocks:
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    92
49
claus
parents: 44
diff changeset
    93
     |b|
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    94
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    95
     b := CheckBox new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    96
     b label:'check'.
49
claus
parents: 44
diff changeset
    97
     b action:[:value | Transcript show:'set to: '; showCr:value].
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    98
     b open.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
    99
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   100
49
claus
parents: 44
diff changeset
   101
  with a model (default ST-80 behavior, sending #value: to the model):
claus
parents: 44
diff changeset
   102
  (see changing value in the inspector)
claus
parents: 44
diff changeset
   103
claus
parents: 44
diff changeset
   104
     |b model|
claus
parents: 44
diff changeset
   105
claus
parents: 44
diff changeset
   106
     model := ValueHolder newBoolean.
claus
parents: 44
diff changeset
   107
claus
parents: 44
diff changeset
   108
     b := CheckBox new.
claus
parents: 44
diff changeset
   109
     b label:'check'.
claus
parents: 44
diff changeset
   110
     b model:model.
claus
parents: 44
diff changeset
   111
     b open.
claus
parents: 44
diff changeset
   112
     model inspect.
claus
parents: 44
diff changeset
   113
56
claus
parents: 55
diff changeset
   114
49
claus
parents: 44
diff changeset
   115
  with a model and different changeSelector
claus
parents: 44
diff changeset
   116
  (using a plug here, for demonstration only):
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   117
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   118
     |b model|
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   119
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   120
     model := Plug new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   121
     model respondTo:#changeCheck: with:[:arg | Transcript showCr:'change to ' , arg printString].
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   122
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   123
     b := CheckBox new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   124
     b label:'check'.
59
claus
parents: 58
diff changeset
   125
     b model:model; changeMessage:#changeCheck:.
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   126
     b open.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   127
56
claus
parents: 55
diff changeset
   128
claus
parents: 55
diff changeset
   129
  with models, one checkBox disabling the others:
claus
parents: 55
diff changeset
   130
claus
parents: 55
diff changeset
   131
     |dialog translator enableChannel val1 val2 val3 eBox box1 box2 box3|
claus
parents: 55
diff changeset
   132
claus
parents: 55
diff changeset
   133
     translator := Plug new.
claus
parents: 55
diff changeset
   134
     translator respondTo:#enableDisable 
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   135
		with:[
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   136
			enableChannel value
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   137
			    ifTrue:[
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   138
				box1 enable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   139
				box2 enable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   140
				box3 enable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   141
			    ]
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   142
			    ifFalse:[
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   143
				box1 disable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   144
				box2 disable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   145
				box3 disable.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   146
			    ]
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   147
		     ].
56
claus
parents: 55
diff changeset
   148
claus
parents: 55
diff changeset
   149
     enableChannel := true asValue.
claus
parents: 55
diff changeset
   150
     enableChannel onChangeSend:#enableDisable to:translator.
claus
parents: 55
diff changeset
   151
     val1 := true asValue.
claus
parents: 55
diff changeset
   152
     val2 := false asValue.
claus
parents: 55
diff changeset
   153
     val3 := true asValue.
claus
parents: 55
diff changeset
   154
claus
parents: 55
diff changeset
   155
     dialog := Dialog new.
claus
parents: 55
diff changeset
   156
     dialog addCheckBox:'enable' on:enableChannel.
claus
parents: 55
diff changeset
   157
     dialog addVerticalSpace.
claus
parents: 55
diff changeset
   158
     dialog leftIndent:30.
claus
parents: 55
diff changeset
   159
     box1 := dialog addCheckBox:'value1' on:val1.
claus
parents: 55
diff changeset
   160
     dialog addVerticalSpace.
claus
parents: 55
diff changeset
   161
     box2 := dialog addCheckBox:'value2' on:val2.
claus
parents: 55
diff changeset
   162
     dialog addVerticalSpace.
claus
parents: 55
diff changeset
   163
     box3 := dialog addCheckBox:'value3' on:val3.
claus
parents: 55
diff changeset
   164
     dialog addVerticalSpace.
claus
parents: 55
diff changeset
   165
     dialog addOkButton.
claus
parents: 55
diff changeset
   166
claus
parents: 55
diff changeset
   167
     dialog open.
claus
parents: 55
diff changeset
   168
claus
parents: 55
diff changeset
   169
49
claus
parents: 44
diff changeset
   170
  multiple checkBoxes on a single model (using different aspects)
claus
parents: 44
diff changeset
   171
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   172
     |top panel b model value1 value2|
49
claus
parents: 44
diff changeset
   173
claus
parents: 44
diff changeset
   174
     value1 := true.
claus
parents: 44
diff changeset
   175
     value2 := false.
claus
parents: 44
diff changeset
   176
     model := Plug new.
claus
parents: 44
diff changeset
   177
     model respondTo:#value1 with:[value1].
claus
parents: 44
diff changeset
   178
     model respondTo:#value1: with:[:val | value1 := val].
claus
parents: 44
diff changeset
   179
     model respondTo:#value2 with:[value2].
claus
parents: 44
diff changeset
   180
     model respondTo:#value2: with:[:val | value2 := val].
claus
parents: 44
diff changeset
   181
claus
parents: 44
diff changeset
   182
     top := DialogBox new.
claus
parents: 44
diff changeset
   183
     top extent:200@300.
claus
parents: 44
diff changeset
   184
claus
parents: 44
diff changeset
   185
     panel := VerticalPanelView new.
claus
parents: 44
diff changeset
   186
claus
parents: 44
diff changeset
   187
     b := CheckBox in:panel.
claus
parents: 44
diff changeset
   188
     b label:'check1'.
59
claus
parents: 58
diff changeset
   189
     b model:model; aspect:#value1; changeMessage:#value1:.
49
claus
parents: 44
diff changeset
   190
claus
parents: 44
diff changeset
   191
     b := CheckBox in:panel.
claus
parents: 44
diff changeset
   192
     b label:'check2'.
59
claus
parents: 58
diff changeset
   193
     b model:model; aspect:#value2; changeMessage:#value2:.
49
claus
parents: 44
diff changeset
   194
claus
parents: 44
diff changeset
   195
     top addComponent:panel.
claus
parents: 44
diff changeset
   196
     top addAbortButton; addOkButton.
claus
parents: 44
diff changeset
   197
     top openModal.
claus
parents: 44
diff changeset
   198
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   199
     top accepted ifTrue:[
49
claus
parents: 44
diff changeset
   200
	 Transcript show:'value1: '; showCr:model value1.
claus
parents: 44
diff changeset
   201
	 Transcript show:'value2: '; showCr:model value2.
claus
parents: 44
diff changeset
   202
     ]
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   203
"
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   204
! !
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   205
62
claus
parents: 59
diff changeset
   206
!CheckBox class methodsFor:'instance creation'!
claus
parents: 59
diff changeset
   207
76
claus
parents: 66
diff changeset
   208
label:aStringOrImage model:aModel
claus
parents: 66
diff changeset
   209
    "create & return a new checkBox, on aModel (typically a ValueHolder),
claus
parents: 66
diff changeset
   210
     with aStringOrImage as label."
claus
parents: 66
diff changeset
   211
claus
parents: 66
diff changeset
   212
    ^ (self new model:aModel) label:aStringOrImage
claus
parents: 66
diff changeset
   213
claus
parents: 66
diff changeset
   214
    "Created: 17.9.1995 / 14:20:58 / claus"
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   215
!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   216
55
claus
parents: 49
diff changeset
   217
model:aModel
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   218
    "create & return a new checkBox, on aModel (typically a ValueHolder)"
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   219
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   220
    ^ self new model:aModel
56
claus
parents: 55
diff changeset
   221
! !
claus
parents: 55
diff changeset
   222
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   223
!CheckBox class methodsFor:'defaults'!
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   224
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   225
updateStyleCache
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   226
    DefaultLabelForegroundColor := StyleSheet colorAt:'checkBoxLabelForegroundColor'.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   227
    DefaultDisabledLabelForegroundColor := StyleSheet colorAt:'checkBoxDisabledLabelForegroundColor'.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   228
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   229
    "
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   230
     self updateStyleCache
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   231
    "
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   232
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   233
    "Created: 14.12.1995 / 14:47:22 / cg"
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   234
    "Modified: 14.12.1995 / 14:47:36 / cg"
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   235
! !
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   236
56
claus
parents: 55
diff changeset
   237
!CheckBox methodsFor:'accessing'!
claus
parents: 55
diff changeset
   238
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   239
labelView
49
claus
parents: 44
diff changeset
   240
    "return the labelView; allows manipulation of the
claus
parents: 44
diff changeset
   241
     labels attributes (colors etc.)"
claus
parents: 44
diff changeset
   242
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   243
    ^ labelView
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   244
!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   245
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   246
toggleView
49
claus
parents: 44
diff changeset
   247
    "return the toggleView; allows manipulation of the
claus
parents: 44
diff changeset
   248
     toggles attributes (colors etc.)"
claus
parents: 44
diff changeset
   249
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   250
    ^ toggleView
56
claus
parents: 55
diff changeset
   251
! !
claus
parents: 55
diff changeset
   252
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   253
!CheckBox methodsFor:'accessing-behavior'!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   254
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   255
action:aBlock
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   256
    "forward to toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   257
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   258
    toggleView action:aBlock
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   259
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   260
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   261
disable
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   262
    "forward to toggle & change labels color"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   263
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   264
    |clr|
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   265
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   266
    toggleView disable.
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   267
    clr := disabledLabelForegroundColor.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   268
    clr isNil ifTrue:[ clr := toggleView disabledForegroundColor ].
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   269
    labelView foregroundColor:clr.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   270
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   271
    "Modified: 14.12.1995 / 14:50:54 / cg"
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   272
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   273
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   274
enable
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   275
    "forward to toggle & change labels color"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   276
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   277
    |clr|
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   278
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   279
    toggleView enable.
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   280
    clr := labelForegroundColor.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   281
    clr isNil ifTrue:[ clr := toggleView foregroundColor ].
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   282
    labelView foregroundColor:clr.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   283
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   284
    "Modified: 14.12.1995 / 14:51:19 / cg"
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   285
!
78
claus
parents: 76
diff changeset
   286
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   287
pressAction:aBlock
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   288
    toggleView pressAction:aBlock.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   289
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   290
    "Created: 22.9.1995 / 15:54:04 / claus"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   291
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   292
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   293
releaseAction:aBlock
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   294
    toggleView releaseAction:aBlock.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   295
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   296
    "Created: 22.9.1995 / 15:54:11 / claus"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   297
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   298
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   299
turnOff
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   300
    "forward to toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   301
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   302
    toggleView turnOff
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   303
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   304
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   305
turnOn
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   306
    "forward to toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   307
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   308
    toggleView turnOn
78
claus
parents: 76
diff changeset
   309
! !
claus
parents: 76
diff changeset
   310
56
claus
parents: 55
diff changeset
   311
!CheckBox methodsFor:'accessing-look'!
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   312
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   313
activeLogo:anImageOrString
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   314
    toggleView activeLogo:anImageOrString
56
claus
parents: 55
diff changeset
   315
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   316
    "Created: 22.9.1995 / 15:44:08 / claus"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   317
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   318
114
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   319
disabledLabelForegroundColor
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   320
    disabledLabelForegroundColor isNil ifTrue:[ ^ toggleView disabledForegroundColor ].
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   321
    ^ disabledLabelForegroundColor
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   322
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   323
    "Created: 16.12.1995 / 19:47:45 / cg"
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   324
    "Modified: 16.12.1995 / 19:56:41 / cg"
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   325
!
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   326
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   327
font
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   328
    "forward from label"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   329
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   330
    ^ labelView font
49
claus
parents: 44
diff changeset
   331
!
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   332
56
claus
parents: 55
diff changeset
   333
font:aFont
claus
parents: 55
diff changeset
   334
    "forward to label & resize"
55
claus
parents: 49
diff changeset
   335
56
claus
parents: 55
diff changeset
   336
    labelView font:aFont.
claus
parents: 55
diff changeset
   337
    labelView forceResize.
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   338
    self layoutChanged.
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   339
    self resize.
49
claus
parents: 44
diff changeset
   340
!
claus
parents: 44
diff changeset
   341
56
claus
parents: 55
diff changeset
   342
label
claus
parents: 55
diff changeset
   343
    "forward from label"
claus
parents: 55
diff changeset
   344
claus
parents: 55
diff changeset
   345
    ^ labelView label
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   346
!
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   347
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   348
label:aString
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   349
    "forward to label & resize"
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   350
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   351
    labelView label:aString.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   352
    labelView forceResize.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   353
    self layoutChanged.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   354
    self resize.
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   355
!
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   356
114
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   357
labelForegroundColor
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   358
    labelForegroundColor isNil ifTrue:[ ^ toggleView foregroundColor ].
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   359
    ^ labelForegroundColor
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   360
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   361
    "Created: 16.12.1995 / 19:47:20 / cg"
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   362
    "Modified: 16.12.1995 / 19:56:57 / cg"
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   363
!
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   364
79
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   365
passiveLogo:anImageOrString
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   366
    toggleView passiveLogo:anImageOrString
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   367
Claus Gittinger <cg@exept.de>
parents: 78
diff changeset
   368
    "Created: 22.9.1995 / 15:44:14 / claus"
56
claus
parents: 55
diff changeset
   369
! !
claus
parents: 55
diff changeset
   370
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   371
!CheckBox methodsFor:'accessing-mvc'!
63
claus
parents: 62
diff changeset
   372
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   373
aspectMessage:aspectSymbol
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   374
    "forward to label & toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   375
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   376
    labelView aspectMessage:aspectSymbol.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   377
    toggleView aspectMessage:aspectSymbol
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   378
!
63
claus
parents: 62
diff changeset
   379
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   380
changeMessage:aChangeSelector
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   381
    "forward to toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   382
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   383
    toggleView changeMessage:aChangeSelector
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   384
!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   385
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   386
model:aModel
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   387
    "forward to label & toggle"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   388
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   389
    labelView model:aModel.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   390
    toggleView model:aModel
63
claus
parents: 62
diff changeset
   391
! !
claus
parents: 62
diff changeset
   392
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   393
!CheckBox methodsFor:'accessing-state'!
55
claus
parents: 49
diff changeset
   394
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   395
isOn
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   396
    ^ toggleView isOn
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   397
! !
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   398
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   399
!CheckBox methodsFor:'initialization'!
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   400
112
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   401
initStyle
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   402
    super initStyle.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   403
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   404
    DefaultLabelForegroundColor notNil ifTrue:[
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   405
        labelForegroundColor := DefaultLabelForegroundColor on:device.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   406
    ].
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   407
    DefaultDisabledLabelForegroundColor notNil ifTrue:[
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   408
        disabledLabelForegroundColor := DefaultDisabledLabelForegroundColor on:device.
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   409
    ].
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   410
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   411
    "Created: 14.12.1995 / 14:50:03 / cg"
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   412
!
bb2cb6c553d2 allow labels colors to be set from styleSheet
Claus Gittinger <cg@exept.de>
parents: 100
diff changeset
   413
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   414
initialize
56
claus
parents: 55
diff changeset
   415
    super initialize.
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   416
56
claus
parents: 55
diff changeset
   417
    borderWidth := 0.
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   418
49
claus
parents: 44
diff changeset
   419
    hLayout := #fixLeftSpace.
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   420
    vLayout := #center.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   421
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   422
    toggleView := CheckToggle in:self.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   423
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   424
    labelView := Label in:self.
58
claus
parents: 56
diff changeset
   425
    labelView label:'check'; borderWidth:0.
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   426
    labelView forceResize.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   427
    labelView adjust:#left.
62
claus
parents: 59
diff changeset
   428
    self height:labelView preferredExtent y + ViewSpacing.
55
claus
parents: 49
diff changeset
   429
56
claus
parents: 55
diff changeset
   430
    "
claus
parents: 55
diff changeset
   431
     all of my input goes to the toggle
claus
parents: 55
diff changeset
   432
    "
claus
parents: 55
diff changeset
   433
    self delegate:(KeyboardForwarder toView:toggleView).
44
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   434
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   435
    "
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   436
     |b|
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   437
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   438
     b := CheckBox new.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   439
     b label:'foo'.
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   440
     b open
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   441
    "
97c1c943bef6 Initial revision
claus
parents:
diff changeset
   442
! !
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   443
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   444
!CheckBox methodsFor:'private'!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   445
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   446
sendChangeMessageWith:aValue
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   447
    "redefined to have mimic changes being sent from the toggle
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   448
     instead of myself"
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   449
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   450
    toggleView sendChangeMessageWith:aValue
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   451
! !
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   452
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   453
!CheckBox methodsFor:'queries'!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   454
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   455
preferredExtent
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   456
    |prefCheck prefLabel bw2|
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   457
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   458
^ super preferredExtent + (10@0).
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   459
"/    prefCheck := toggleView preferredExtent.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   460
"/    prefLabel := labelView preferredExtent.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   461
"/    bw2 := borderWidth * 2.
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   462
"/    ^ (prefCheck x + prefLabel x + (3 * ViewSpacing)) @ ((prefCheck y max:prefLabel y) + bw2 + 2)
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   463
! !
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   464
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   465
!CheckBox class methodsFor:'documentation'!
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   466
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   467
version
114
bd13b6f557ea access methods for colors
Claus Gittinger <cg@exept.de>
parents: 112
diff changeset
   468
    ^ '$Header: /cvs/stx/stx/libwidg2/CheckBox.st,v 1.16 1995-12-17 13:28:56 cg Exp $'
100
3d33433f459c checkin from browser
Claus Gittinger <cg@exept.de>
parents: 86
diff changeset
   469
! !