--- a/SelTreeV.st Sat Oct 31 13:03:29 1998 +0100
+++ b/SelTreeV.st Sun Nov 01 13:57:46 1998 +0100
@@ -19,7 +19,7 @@
showDirectoryIndicatorForRoot imageOpened imageClosed imageItem
discardMotionEvents registeredImages supportsExpandAll
buildInArray drawVLinesFromLevel highlightMode editorWidget
- editorIndex'
+ editorIndex editValueFgColor'
classVariableNames:'DefaultHilightMode SelectionInset'
poolDictionaries:''
category:'Views-Text'
@@ -972,6 +972,9 @@
self displayOpaqueString:label x:x0 y:y0.
value notNil ifTrue:[
+ isSel ifFalse:[
+ self paint:editValueFgColor on:bgColor
+ ].
self displayOpaqueString:value x:(xV + SelectionInset) y:y0
].
@@ -1422,6 +1425,8 @@
lineColor := lineColor isNil ifTrue:[fgColor]
ifFalse:[lineColor onDevice:device].
+
+ editValueFgColor := editValueFgColor onDevice:device.
!
destroy
@@ -1556,6 +1561,7 @@
self model:nil. "/ creates a default model.
highlightMode := #label.
+ editValueFgColor := Color blue.
!
realize
@@ -1782,7 +1788,7 @@
openEditor
"open an editor on selection
"
- |node x0 x1 y0 focusView|
+ |node x0 x1 y0|
editorWidget notNil ifTrue:[
^ self
@@ -1795,22 +1801,17 @@
) ifTrue:[
^ self
].
- focusView := nil.
- editorWidget withAllSubViewsDo:[:v|
- focusView := v.
- v font:font
- ].
+ editorWidget withAllSubViewsDo:[:v| v font:font ].
+
y0 := self yOfVisibleLine:y0.
x0 := self xOfValueNode:node.
x1 := (editorWidget preferredExtent x) max:50.
x1 := (x0 + x1) min:(self width - 5).
- "/ editorWidget geometryLayout:(Rectangle left:x0 right:x1 top:y0 + 1 bottom:y0 - 2 + fontHeight).
editorWidget geometryLayout:(Rectangle left:x0 right:x1 top:y0 bottom:y0 + fontHeight).
self addComponent:editorWidget.
editorWidget realize.
- self windowGroup focusView:focusView.
self paint:bgColor.
self fillRectangleX:(x0 - SelectionInset)
@@ -2311,5 +2312,5 @@
!SelectionInTreeView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg2/Attic/SelTreeV.st,v 1.69 1998-10-31 12:02:10 ca Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg2/Attic/SelTreeV.st,v 1.70 1998-11-01 12:57:46 ca Exp $'
! !
--- a/SelectionInTreeView.st Sat Oct 31 13:03:29 1998 +0100
+++ b/SelectionInTreeView.st Sun Nov 01 13:57:46 1998 +0100
@@ -19,7 +19,7 @@
showDirectoryIndicatorForRoot imageOpened imageClosed imageItem
discardMotionEvents registeredImages supportsExpandAll
buildInArray drawVLinesFromLevel highlightMode editorWidget
- editorIndex'
+ editorIndex editValueFgColor'
classVariableNames:'DefaultHilightMode SelectionInset'
poolDictionaries:''
category:'Views-Text'
@@ -972,6 +972,9 @@
self displayOpaqueString:label x:x0 y:y0.
value notNil ifTrue:[
+ isSel ifFalse:[
+ self paint:editValueFgColor on:bgColor
+ ].
self displayOpaqueString:value x:(xV + SelectionInset) y:y0
].
@@ -1422,6 +1425,8 @@
lineColor := lineColor isNil ifTrue:[fgColor]
ifFalse:[lineColor onDevice:device].
+
+ editValueFgColor := editValueFgColor onDevice:device.
!
destroy
@@ -1556,6 +1561,7 @@
self model:nil. "/ creates a default model.
highlightMode := #label.
+ editValueFgColor := Color blue.
!
realize
@@ -1782,7 +1788,7 @@
openEditor
"open an editor on selection
"
- |node x0 x1 y0 focusView|
+ |node x0 x1 y0|
editorWidget notNil ifTrue:[
^ self
@@ -1795,22 +1801,17 @@
) ifTrue:[
^ self
].
- focusView := nil.
- editorWidget withAllSubViewsDo:[:v|
- focusView := v.
- v font:font
- ].
+ editorWidget withAllSubViewsDo:[:v| v font:font ].
+
y0 := self yOfVisibleLine:y0.
x0 := self xOfValueNode:node.
x1 := (editorWidget preferredExtent x) max:50.
x1 := (x0 + x1) min:(self width - 5).
- "/ editorWidget geometryLayout:(Rectangle left:x0 right:x1 top:y0 + 1 bottom:y0 - 2 + fontHeight).
editorWidget geometryLayout:(Rectangle left:x0 right:x1 top:y0 bottom:y0 + fontHeight).
self addComponent:editorWidget.
editorWidget realize.
- self windowGroup focusView:focusView.
self paint:bgColor.
self fillRectangleX:(x0 - SelectionInset)
@@ -2311,5 +2312,5 @@
!SelectionInTreeView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg2/SelectionInTreeView.st,v 1.69 1998-10-31 12:02:10 ca Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg2/SelectionInTreeView.st,v 1.70 1998-11-01 12:57:46 ca Exp $'
! !