19 (obj := self basicNew) createDialog.
23 createLBArea: aText lb: aLb [
24 ^(GuiVBox new); expandable; attribute: 'SIZE' value: '0x0';
25 add: (GuiLabel new: aText; expandableHorizontal; attribute: 'SIZE' value: '0x0');
26 "add: (aLb expandable; attribute: 'SIZE' value: '100x90'; attribute: 'VISIBLECOLUMNS' value: '1');"
27 add: (aLb expandable; attribute: 'SIZE' value: '0x90'; attribute: 'VISIBLECOLUMNS' value: '1');
28 add: ((GuiHBox new; expandableHorizontal; attribute: 'SIZE' value: '0x0');
29 add: (GuiButton new: 'Create'; expandableHorizontal; attribute: 'SIZE' value: '0x0');
30 add: (GuiButton new: 'Remove'; expandableHorizontal; attribute: 'SIZE' value: '0x0'));
35 | vb hb pa ca ma va split |
37 lbPackages := GuiList new; action: [ self fillClasses ].
38 lbClasses := GuiList new; action: [ self fillMethods. self fillVars ].
39 lbMethods := GuiList new; action: [ self showMethod ].
40 lbVars := GuiList new.
42 edText := GuiMultiEdit new; expandable; attribute: 'SIZE' value: '0x120'.
44 pa := self createLBArea: 'Packages' lb: lbPackages.
45 ca := self createLBArea: 'Classes' lb: lbClasses.
46 ma := self createLBArea: 'Methods' lb: lbMethods.
47 va := self createLBArea: 'Variables' lb: lbVars.
49 split := GuiVSplit new: ma and: va.
50 split := GuiVSplit new: ca and: split.
51 split := GuiVSplit new: pa and: split.
54 add: (GuiButton new: 'Apply' action: [ self applyMethod ]; expandableHorizontal);
55 add: (GuiButton new: 'GST-compile' action: [ self gstCompile ]; expandableHorizontal);
64 dialog := GuiDialog new: 'LST Class Browser' widget: vb onClose: [ GuiSingleton setQuitFlag ].
72 Package packages keysDo: [:p | lbPackages << p asString ].
80 (si := lbPackages selected) ifNil: [ ^self ].
81 si := lbPackages at: si.
82 pkg := Package find: si asSymbol.
85 pkg do: [:c | (c isKindOf: Class) ifTrue: [ c isMeta ifFalse: [ lbClasses << c asString ]]].
92 (si := lbClasses selected) ifNil: [ ^self ].
93 si := lbClasses at: si.
94 cls := globals at: (si asSymbol) ifAbsent: [ ^self ].
95 cls class methods do: [:mth | lbMethods << ('^' + mth name asString) ].
96 cls methods do: [:mth | lbMethods << mth name asString ].
102 (si := lbClasses selected) ifNil: [ ^self ].
103 si := lbClasses at: si.
104 cls := globals at: (si asSymbol) ifAbsent: [ ^self ].
105 cls class instanceVariables do: [:vn | lbVars << ('^' + vn asString) ].
106 cls instanceVariables do: [:vn | lbVars << vn asString ].
110 | si cls mth isMeta m |
112 (si := lbClasses selected) ifNil: [ ^self ].
113 si := lbClasses at: si.
114 cls := globals at: (si asSymbol) ifAbsent: [ ^self ].
115 (si := lbMethods selected) ifNil: [ ^self ].
116 si := lbMethods at: si.
117 si firstChar == $^ ifTrue: [ cls := cls class. mth := si from: 2. isMeta := '^' ] ifFalse: [ mth := si. isMeta := '' ].
118 m := cls findMethodInAll: mth asSymbol ifAbsent: [ ^self ].
119 edText value: isMeta + m text.
139 System newProcessGroupWith: (Process newWithMethod: #REPL class: REPL new).
141 browser := Browser new.
142 GuiSingleton add: browser dialog.
144 GuiSingleton mainLoop.