The Trunk: Tools-bp.220.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: Tools-bp.220.mcz

commits-2
Andreas Raab uploaded a new version of Tools to project The Trunk:
http://source.squeak.org/trunk/Tools-bp.220.mcz

==================== Summary ====================

Name: Tools-bp.220
Author: bp
Time: 2 April 2010, 11:39:31.81 pm
UUID: e5e40b2c-99fc-45a1-9310-9c82bf1705f4
Ancestors: Tools-nice.219

fix height for button rows in browsers

=============== Diff against Tools-nice.219 ===============

Item was added:
+ ----- Method: Browser>>switchesFrame: (in category 'initialize-release') -----
+ switchesFrame: bottomFraction
+ ^LayoutFrame new
+ leftFraction: 0.25 offset: 0;
+ topFraction: bottomFraction offset: self buttonHeight negated - 4;
+ rightFraction: 0.5 offset: 0;
+ bottomFraction: bottomFraction offset: 0!

Item was added:
+ ----- Method: CodeHolder>>buttonHeight (in category 'toolbuilder') -----
+ buttonHeight
+ ^Preferences standardButtonFont height + 12!

Item was added:
+ ----- Method: CodeHolder>>optionalButtonsFrame (in category 'toolbuilder') -----
+ optionalButtonsFrame
+ ^LayoutFrame new
+ leftFraction: 0 offset: 0;
+ topFraction: 0 offset: 0;
+ rightFraction: 1 offset: 0;
+ bottomFraction: 0 offset: self buttonHeight!

Item was changed:
  SystemOrganization addCategory: #'Tools-ArchiveViewer'!
  SystemOrganization addCategory: #'Tools-Base'!
  SystemOrganization addCategory: #'Tools-Browser'!
  SystemOrganization addCategory: #'Tools-Changes'!
  SystemOrganization addCategory: #'Tools-Debugger'!
  SystemOrganization addCategory: #'Tools-Explorer'!
  SystemOrganization addCategory: #'Tools-File Contents Browser'!
  SystemOrganization addCategory: #'Tools-FileList'!
  SystemOrganization addCategory: #'Tools-Inspector'!
- SystemOrganization addCategory: #'Tools-Process Browser'!
  SystemOrganization addCategory: #'Tools-Menus'!
+ SystemOrganization addCategory: #'Tools-Process Browser'!

Item was added:
+ ----- Method: Browser>>classListFrame: (in category 'initialize-release') -----
+ classListFrame: bottomFraction
+ ^LayoutFrame new
+ leftFraction: 0.25 offset: 0;
+ topFraction: 0 offset: 0;
+ rightFraction: 0.5 offset: 0;
+ bottomFraction: bottomFraction offset: self buttonHeight negated - 3!

Item was added:
+ ----- Method: CodeHolder>>annotationFrame (in category 'toolbuilder') -----
+ annotationFrame
+ ^LayoutFrame new
+ leftFraction: 0 offset: 0;
+ topFraction: 1 offset: self annotationPaneHeight negated - 1;
+ rightFraction: 1 offset: 0;
+ bottomFraction: 1 offset: 0!

Item was added:
+ ----- Method: CodeHolder>>textFrame (in category 'toolbuilder') -----
+ textFrame
+ | spacing topOffset bottomOffset |
+ spacing := 3.
+ topOffset := self wantsOptionalButtons
+ ifTrue: [self buttonHeight + spacing]
+ ifFalse: [spacing].
+ bottomOffset := self wantsAnnotationPane
+ ifTrue: [self annotationPaneHeight negated]
+ ifFalse: [0].
+ ^LayoutFrame new
+ leftFraction: 0 offset: 0;
+ topFraction: 0 offset: topOffset;
+ rightFraction: 1 offset: 0;
+ bottomFraction: 1 offset: bottomOffset!

Item was changed:
  ----- Method: Browser>>openEditString: (in category 'initialize-release') -----
  openEditString: aString
          "Create a pluggable version of all the views for a Browser, including views and controllers."
  "Example:
  Browser fullOnClass: Browser.
  "
  | builder max |
  builder := ToolBuilder default.
  max := self wantsOptionalButtons ifTrue:[0.42] ifFalse:[0.5].
  ^self buildWindowWith: builder specs: {
  (0@0 corner: 0.25@max) -> [self buildSystemCategoryListWith: builder].
+ (self classListFrame: max) -> [self buildClassListWith: builder].
+ (self switchesFrame: max) -> [self buildSwitchesWith: builder].
- (0.25@0 corner: 0.5@(max-0.08)) -> [self buildClassListWith: builder].
- (0.25@(max-0.08) corner: 0.5@max) -> [self buildSwitchesWith: builder].
  (0.5@0 corner: 0.75@max) -> [self buildMessageCategoryListWith: builder].
  (0.75@0 corner: 1@max) -> [self buildMessageListWith: builder].
  "(0@max corner: 1@0.5) -> [self buildOptionalButtonsWith: builder]."
  (0@max corner: 1@1) -> [self buildCodePaneWith: builder].
  }!

Item was added:
+ ----- Method: CodeHolder>>annotationPaneHeight (in category 'toolbuilder') -----
+ annotationPaneHeight
+ ^Preferences standardCodeFont height * 2 + 5!

Item was changed:
  ----- Method: CodeHolder>>buildCodePaneWith: (in category 'toolbuilder') -----
  buildCodePaneWith: builder
  | textSpec top buttonSpec annoSpec |
+ self wantsOptionalButtons ifTrue: [
- self wantsOptionalButtons ifTrue:[
  top := builder pluggablePanelSpec new.
  top children: OrderedCollection new.
  buttonSpec := self buildOptionalButtonsWith: builder.
+ buttonSpec frame: self optionalButtonsFrame.
+ top children add: buttonSpec].
- buttonSpec frame: (0@0 corner: 1@0.11).
- top children add: buttonSpec.
- ].
  textSpec := builder pluggableCodePaneSpec new.
  textSpec
  model: self;
  getText: #contents;
  setText: #contents:notifying:;
  selection: #contentsSelection;
  menu: #codePaneMenu:shifted:.
+ self wantsAnnotationPane ifTrue: [
+ top ifNil: [
- self wantsAnnotationPane ifTrue:[
- top ifNil:[
  top := builder pluggablePanelSpec new.
+ top children: OrderedCollection new].
- top children: OrderedCollection new.
- ].
  annoSpec := builder pluggableInputFieldSpec new.
  annoSpec model: self; getText: #annotation.
+ annoSpec frame: self annotationFrame.
+ top children add: annoSpec].
+ top ifNotNil: [
+ textSpec frame: self textFrame.
+ top children add: textSpec].
+ ^top ifNil: [textSpec]!
- annoSpec frame: (0@0.88 corner: 1@1).
- top children add: annoSpec.
- ].
- top ifNotNil:[
- textSpec frame: (0 @ (buttonSpec ifNil:[0] ifNotNil:[0.12])
- corner: 1 @ (annoSpec ifNil:[1] ifNotNil:[0.88])).
- top children add: textSpec.
- ].
- ^top ifNil:[textSpec]!

Item was removed:
- ----- Method: Browser>>addClassAndSwitchesTo:at:with: (in category 'toolbuilder') -----
- addClassAndSwitchesTo: windowSpec at: frame with: builder
- | listSpec panelSpec |
-
- listSpec := self buildClassListWith: builder.
- listSpec frame: (frame origin corner: frame right @ (frame bottom - 0.08)).
- windowSpec children add: listSpec.
-
- panelSpec := self buildSwitchesWith: builder.
- panelSpec frame: (frame left@(frame bottom - 0.08) corner: frame corner).
- windowSpec children addLast: panelSpec.!