|
Class: RadioButton
Object
|
+--GraphicsMedium
|
+--DisplaySurface
|
+--SimpleView
|
+--View
|
+--Label
|
+--Button
|
+--Toggle
|
+--RadioButton
- Package:
- stx:libwidg
- Category:
- Views-Interactors
- Version:
- rev:
1.59
date: 2018/07/28 08:08:29
- user: cg
- file: RadioButton.st directory: libwidg
- module: stx stc-classLibrary: libwidg
- Author:
- Claus Gittinger
like a Toggle, but do not turn off when pressed again, instead only
turn off when another RadioButton is pressed (see RadioButtonGroup).
written fall 91 by claus
defaults
-
activeForm
-
ActiveForm := nil.
self updateStyleCache
-
disabledActiveForm
-
DisabledActiveForm := nil.
self updateStyleCache
-
disabledPassiveForm
-
DisabledPassiveForm := nil.
self updateStyleCache
-
enteredActiveForm
-
EnteredActiveForm := nil.
self updateStyleCache
-
enteredPassiveForm
-
EnteredPassiveForm := nil.
self updateStyleCache
-
motifCheckBotForm
-
-
motifCheckInnerForm
-
-
motifCheckTopForm
-
-
passiveForm
-
PassiveForm := nil.
self updateStyleCache
-
round3DCheckBotForm
-
-
round3DCheckInnerForm
-
-
round3DCheckTopForm
-
fromArray:#[2r00000111 2r11000000
-
roundHalfLightForm
-
fromArray:#[2r00000000 2r00000000
-
roundOffForm
-
DSVColumnView>>updateStyleCache calls us before our style
cache has been initialized
-
roundOffForm_old
-
-
roundOnForm
-
DSVColumnView>>updateStyleCache calls us before our style
cache has been initialized
-
roundOnForm_old
-
-
updateStyleCache
-
self updateStyleCache
image specs
-
radioOffDisabledIcon_vista
-
-
radioOffDisabledIcon_w95
-
-
radioOffDisabledIcon_xp
-
-
radioOffEnteredIcon_vista
-
-
radioOffEnteredIcon_w95
-
-
radioOffEnteredIcon_xp
-
-
radioOffIcon_vista
-
-
radioOffIcon_w95
-
This resource specification was automatically generated
by the ImageEditor of ST/X.
usage example(s):
self radioOffIcon_w95 inspect
ImageEditor openOnClass:self andSelector:#radioOffIcon_w95
Icon flushCachedIcons
|
-
radioOffIcon_xp
-
This resource specification was automatically generated
by the ImageEditor of ST/X.
usage example(s):
self radioOffIcon_xp inspect
ImageEditor openOnClass:self andSelector:#radioOffIcon_xp
Icon flushCachedIcons
|
-
radioOnDisabledIcon_vista
-
-
radioOnDisabledIcon_w95
-
-
radioOnDisabledIcon_xp
-
-
radioOnEnteredIcon_vista
-
-
radioOnEnteredIcon_w95
-
-
radioOnEnteredIcon_xp
-
-
radioOnIcon_vista
-
-
radioOnIcon_w95
-
This resource specification was automatically generated
by the ImageEditor of ST/X.
usage example(s):
self radioOnIcon_w95 inspect
ImageEditor openOnClass:self andSelector:#radioOnIcon_w95
Icon flushCachedIcons
|
-
radioOnIcon_xp
-
This resource specification was automatically generated
by the ImageEditor of ST/X.
usage example(s):
self radioOnIcon_xp inspect
ImageEditor openOnClass:self andSelector:#radioOnIcon_xp
Icon flushCachedIcons
|
accessing
-
allViewBackground: something if: condition
-
-
forceRadioButtonStyle
-
force the radioButton to be displayed as round/motif radio button -
even if the styleSheet defaults differently.
(as in IRIS style)
changing state
-
turnOff
-
-
turnOn
-
drawing
-
drawToggleImage
-
drawing of the radio image is done here.
-
drawWin95FocusFrame
-
redefined to draw the focus frame around the string-only
initialization
-
defaultControllerClass
-
-
initStyle
-
setup viewStyle specifics
native widget support
-
nativeWindowType
-
return a symbol describing my native window type
(may be used internally by the device as a native window creation hint,
if the device supports native windows)
private
-
computeLabelOrigin
-
(comment from inherited method)
compute the origin of the form/text.
redefined to move label to the right if there is a lamp.
-
lampImageHeight
-
-
lampImageWidth
-
-
rawLabelSizeOf: aLogo
-
compute the extent needed to hold the label plus the lamp
queries
-
is3D
-
(comment from inherited method)
return true, if the receiver is a 3D style view
See more examples in RadioButtonGroup class>>examples
example1: one on behavior (using RadioButtons)
|top panel b group|
top := StandardSystemView new.
top extent:200@200.
panel := HorizontalPanelView
origin:0.0@0.0
corner:1.0@1.0
in:top.
group := RadioButtonGroup new.
b := RadioButton label:'am' in:panel.
group add:b.
b := RadioButton label:'fm' in:panel.
group add:b.
b := RadioButton label:'off' in:panel.
group add:b.
b enabled:false.
group value:1.
top open
|
example2: zero or one on behavior (using Toggles)
|top panel b group|
top := StandardSystemView new.
top extent:200@200.
panel := HorizontalPanelView
origin:0.0@0.0
corner:1.0@1.0
in:top.
group := RadioButtonGroup new.
b := Toggle label:'am' in:panel.
group add:b.
b := Toggle label:'fm' in:panel.
group add:b.
b := Toggle label:'off' in:panel.
group add:b.
group value:1.
top open
|
a selectionInListView and a group displaying the same value:
|top top2 panel b sv group selectionInList|
top := StandardSystemView extent:200@200.
panel := HorizontalPanelView
origin:0.0@0.0 corner:1.0@1.0 in:top.
group := RadioButtonGroup new.
selectionInList := SelectionInList new.
selectionInList list:#('am' 'fm' 'off').
selectionInList selectionIndexHolder:group.
b := Toggle label:'am' in:panel.
group add:b.
b := Toggle label:'fm' in:panel.
group add:b.
b := Toggle label:'off' in:panel.
group add:b.
group value:1.
top open.
top2 := StandardSystemView extent:200@200.
sv := SelectionInListView in:top2.
sv model:selectionInList.
sv origin:0.0@0.0 corner:1.0@1.0.
top2 open.
|
|