links to this page:    
View this PageEdit this PageUploads to this PageHistory of this PageTop of the SwikiRecent ChangesSearch the SwikiHelp Guide
Construct a Workspace window
Last updated at 6:48 am UTC on 14 April 2018
 ToolBuilder open: Workspace

Sequence of message sends to construct a Workspace windows with the ToolBuilder.

 ToolBuilder class>>open:
 open: aClass
	^self default open: aClass

 open: anObject
	"Build and open the object. Answer the widget opened."
	^ (self build: anObject) openAsTool

 build: anObject
	"Build the given object using this tool builder"
	^anObject buildWith: self

 Workspace class(Model class)>>buildWith:
 buildWith: toolBuilder
	^self new buildWith: toolBuilder

 buildWith: builder
	| windowSpec |
	windowSpec := 	self buildWindowWith: builder specs: {
		(0@0corner: 1@1) -> [self buildCodePaneWith: builder].
	^builder build: windowSpec

 buildCodePaneWith: builder
	| textSpec |
	textSpec := builder pluggableCodePaneSpec new.
		model: self;
		getText: #contents; 
		setText: #contents:notifying:; 
		selection: #contentsSelection; 
		menu: #codePaneMenu:shifted:.