--- a/VariablePanel.st Fri Oct 09 11:39:40 2015 +0200
+++ b/VariablePanel.st Fri Oct 09 11:40:30 2015 +0200
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
"
COPYRIGHT (c) 1991 by Claus Gittinger
All Rights Reserved
@@ -2188,12 +2190,14 @@
resizeSubviewsFrom:start to:stop
"readjust size of some subviews"
- |step nSubviews subViews|
+ |step nSubviews subViews bhHalf|
subViews := self subViews.
nSubviews := subViews size.
nSubviews == 0 ifTrue:[ ^ self ].
+ bhHalf := barHeight // 2.
+ "/ Transcript showCR:barHeight.
(start <= stop) ifTrue:[
step := 1
] ifFalse:[
@@ -2208,15 +2212,20 @@
index == 1 ifTrue:[
o1 := 0.
] ifFalse:[
- o1 := barHeight // 2 - bw
+ barHeight odd ifTrue:[
+ o1 := bhHalf + 1 - bw
+ ] ifFalse:[
+ o1 := bhHalf - bw
+ ].
].
- index == nSubviews ifTrue:[
+ index == nSubviews ifTrue:[
o2 := 0.
] ifFalse:[
- o2 := barHeight // 2 - bw
+ o2 := (barHeight-bhHalf) - bw
].
newOrg := view computeOrigin.
+ "/ Transcript showCR:newOrg.
newOrg notNil ifTrue:[
(index ~~ 1) ifTrue:[
orientation == #vertical ifTrue:[
@@ -2227,6 +2236,9 @@
].
].
newExt := view computeExtent.
+ "/ Transcript show:view layout;show:' -> '.
+ "/ Transcript show:view relativeExtent;show:' -> '.
+ "/ Transcript showCR:newExt.
newExt notNil ifTrue:[
orientation == #vertical ifTrue:[
newExt y:(newExt y - o2 - o1)
@@ -2234,6 +2246,7 @@
newExt x:(newExt x - o2 - o1)
]
].
+ "/ Transcript showCR:(newOrg extent:newExt).
view pixelOrigin:newOrg extent:newExt.
].
shown ifTrue:[