UILayoutTool.st
changeset 293 54d00bdebfa9
parent 283 2f98233309f0
child 296 e542c6fb0de7
--- a/UILayoutTool.st	Tue Aug 26 17:40:16 1997 +0200
+++ b/UILayoutTool.st	Tue Aug 26 17:40:37 1997 +0200
@@ -107,13 +107,16 @@
 
 helpSpec
     "return a dictionary filled with helpKey -> helptext associations.
-     These are used by the activeHelp tool.
+     These are used by the activeHelp tool."
+
     "
+    UIHelpTool openOnClass:UILayoutTool    
+    "
+
   ^ super helpSpec addPairsFrom:#(
 
 #leftAbsolute
-'offset of the left edge; positive
-is to the right, negative to the left'
+'offset of the left edge; positive is to the right, negative to the left'
 
 #originY
 'absolute origin y'
@@ -122,23 +125,19 @@
 'absolute corner y'
 
 #makeLeftAbsolute
-'compute current left offset and relative
-origin x to an absolute origin x'
+'compute current left offset and relative origin x to an absolute origin x'
 
 #topAbsolute
-'offset of the top edge; positive
-is to the bottom, negative to the top'
+'offset of the top edge; positive is to the bottom, negative to the top'
 
 #makeTopRelative
-'compute current relative origin y and offset
-of the top edge to a relative origin y'
+'compute current relative origin y and offset of the top edge to a relative origin y'
 
 #leftRelative
 'relative origin x'
 
 #makeLeftRelative
-'compute current relative origin x and offset
-of the left edge to a relative origin x'
+'compute current relative origin x and offset of the left edge to a relative origin x'
 
 #topRelative
 'relative origin y'
@@ -153,8 +152,7 @@
 'tool to set the layout of the component'
 
 #makeTopAbsolute
-'compute current top offset and relative
-origin y to an absolute origin y'
+'compute current top offset and relative origin y to an absolute origin y'
 
 )
 ! !
@@ -687,10 +685,15 @@
 !
 
 selection:aSelection
-    |appl slice|
+    |appl slice sel|
 
-    selection = aSelection ifFalse:[
-        (selection := aSelection) notNil ifTrue:[
+    aSelection isNumber ifTrue:[
+        aSelection ~~ 0 ifTrue:[sel := tabList at:aSelection]
+    ] ifFalse:[
+        sel := aSelection
+    ].
+    selection = sel ifFalse:[
+        (selection := sel) notNil ifTrue:[
             slice := self selectedSlice.
             appl  := slice last asString.
             appl := Smalltalk classNamed:(self class name asString, '::', appl).
@@ -701,30 +704,53 @@
         self noteBookView client:appl.
     ].
     self update
+
 ! !
 
 !UILayoutTool::AlignmentOrigin class methodsFor:'help specs'!
 
 helpSpec
     "return a dictionary filled with helpKey -> helptext associations.
-     These are used by the activeHelp tool.
+     These are used by the activeHelp tool."
+
     "
+    UIHelpTool openOnClass:UILayoutTool::AlignmentOrigin    
+    "
+
   ^ super helpSpec addPairsFrom:#(
 
-#alignVertical    'vertical inset to the location point of the component'
-#alignHorizontal  'horizontal inset to the location point of the component'
+#alignLeftCenter
+'align components leftCenter to location'
+
+#alignBottomCenter
+'align components bottomCenter to location'
 
-#alignTopLeft      'align components topLeft to location'
-#alignLeftCenter   'align components leftCenter to location'
-#alignBottomLeft   'align components bottomLeft to location'
+#alignHorizontal
+'horizontal inset to the location point of the component'
+
+#alignBottomRight
+'align components bottomRight to location'
+
+#alignTopCenter
+'align components topCenter to location'
 
-#alignTopRight     'align components topRight to location'
-#alignRightCenter  'align components rightCenter to location'
-#alignBottomRight  'align components bottomRight to location'
+#alignTopLeft
+'align components topLeft to location'
+
+#alignTopRight
+'align components topRight to location'
+
+#alignCenter
+'align components center to location'
 
-#alignTopCenter    'align components topCenter to location'
-#alignCenter       'align components center to location'
-#alignBottomCenter 'align components bottomCenter to location'
+#alignVertical
+'vertical inset to the location point of the component'
+
+#alignBottomLeft
+'align components bottomLeft to location'
+
+#alignRightCenter
+'align components rightCenter to location'
 
 )
 ! !
@@ -1014,12 +1040,19 @@
 
 helpSpec
     "return a dictionary filled with helpKey -> helptext associations.
-     These are used by the activeHelp tool.
+     These are used by the activeHelp tool."
+
     "
+    UIHelpTool openOnClass:UILayoutTool::Extent    
+    "
+
   ^ super helpSpec addPairsFrom:#(
 
-#vrtExtent      'vertical extent of the component'
-#hrzExtent      'horizontal extent of the component'
+#vrtExtent
+'vertical extent of the component'
+
+#hrzExtent
+'horizontal extent of the component'
 
 )
 ! !
@@ -1116,36 +1149,37 @@
 
 helpSpec
     "return a dictionary filled with helpKey -> helptext associations.
-     These are used by the activeHelp tool.
+     These are used by the activeHelp tool."
+
     "
+    UIHelpTool openOnClass:UILayoutTool::LayoutFrame    
+    "
+
   ^ super helpSpec addPairsFrom:#(
 
 #makeRightRelative
-'compute current relative corner x and offset
-of the right edge to a relative corner x'
+'compute current relative corner x and offset of the right edge to a relative corner x'
+
+#makeBottomAbsolute
+'compute current bottom offset and relative corner y to an absolute corner y'
+
+#bottomAbsolute
+'offset of the bottom edge; positive is to the bottom, negative to the top'
+
+#rightRelative
+'relative corner x'
 
 #makeBottomRelative
-'compute current relative corner y and offset
-of the bottom edge to a relative corner y'
-
-#makeBottomAbsolute
-'compute current bottom offset and relative
-corner y to an absolute corner y'
+'compute current relative corner y and offset of the bottom edge to a relative corner y'
 
 #makeRightAbsolute
-'compute current right offset and relative
-corner x to an absolute corner x'
+'compute current right offset and relative corner x to an absolute corner x'
 
-#bottomAbsolute
-'offset of the bottom edge; positive
-is to the bottom, negative to the top'
+#bottomRelative
+'relative corner y'
 
 #rightAbsolute
-'offset of the right edge; positive
-is to the right, negative to the left'
-
-#rightRelative          'relative corner x'
-#bottomRelative         'relative corner y'
+'offset of the right edge; positive is to the right, negative to the left'
 
 )
 ! !