~drgeo-developers/drgeo/trunk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
| list area morph extent |
"System configurations"
Utilities setAuthorName: 'Hilaire Fernandes' initials: 'hlsf'.
Preferences at: #logDebuggerStackToFile put: false.
Preferences at: #autoNumberUserChanges put: false.
"Delete all windows but the taskbar"
self runningWorld doOneCycleNow.
list := UISupervisor ui submorphs reject: [:aMorph | aMorph is: #TaskbarMorph].
 list do: [:each | each delete].
"Adjust font size"
Preferences at: #guiElementsSize put: #smallFonts.
"Adjust taskbar size"
morph := UISupervisor ui taskbar.
morph scale: 1/2.
Display fullScreenMode: true.
self runningWorld doOneCycleNow.
Transcript show: 'Hello'.
"Compute the available free space for windows placement"
area _ RealEstateAgent maximumUsableArea extendBy: 0 @ morph morphHeight negated.
extent _ area extent // 2.
"Install DrGeo code"
Feature require: #'DrGeo'.
"Open a few System Browsers"
BrowserWindow openBrowser 
	morphPosition: 0@0;
	morphExtent: extent.
BrowserWindow openBrowser 
	morphPosition: area width // 2 @ 0; 
	morphExtent: extent.
"Open a System Browser on a specific class"
morph _ BrowserWindow openBrowser 
	morphPosition: area extent // 2;
	morphExtent: extent.
morph model setClass: (Smalltalk at: #DrGeo) selector: nil.
"Open a Workspace with some default contents"
morph _ Workspace openWorkspace.
morph model actualContents: 'DrGeoSystem beDevelopment.
DrGeoSystem beWorkstation.
DrGeo new.
NaturalLanguageTranslator privateStartUp .
TextDomainManager registerCategoryPrefix: ''DrGeo'' domain: ''drgeo''.
TextDomainManager allKnownDomains.
DrGSmalltalkSketchBrowser open: DrGeoSystem smalltalkSketchesPath label: ''Browse''.
DrGSmalltalkSketchEditor open: ''DrGeoSketch new'' label: ''Edit Smalltalk Sketch''.
PreferenceBrowser open: DrGeoSystem preferences label: ''Dr. Geo Preferences''.
Smalltalk browseAllSelect: [:m| m pragmas anySatisfy: [:p | p key = #drgeosettings]].'.
morph 
	morphPosition: 0 @ (area height // 2);
	morphExtent: extent x @ (2 / 3 * extent y).
"Open a transcript for logs"
TranscriptWindow openTranscript 
	morphPosition: 0 @ (area height // 2 + (2 / 3 * extent y));
	morphExtent: extent x @ (1 / 3 * extent y ).
Smalltalk saveAs: 'drgeo' clearAllClassState: false