Doubleclick on pixel opens colorInspector.
--- a/ImageEditView.st Thu May 02 18:30:11 1996 +0200
+++ b/ImageEditView.st Wed May 08 01:16:57 1996 +0200
@@ -161,6 +161,17 @@
self showColorAtX:x y:y.
!
+buttonMultiPress:button x:x y:y
+ button == 1 ifTrue:[
+ |clr|
+ clr := self getColorAtX:x y:y.
+ clr inspect.
+ ].
+ super buttonMultiPress:button x:x y:y
+
+ "Created: 8.5.1996 / 00:18:06 / stefan"
+!
+
buttonPress:button x:x y:y
button == 1 ifTrue:[
self showColorAtX:x y:y.
@@ -169,19 +180,32 @@
super buttonPress:button x:x y:y
!
-showColorAtX:x y:y
- |pi clr|
+getColorAtX:x y:y
+ |pi|
pi := (x @ y) - margin.
pi := pi // magnification.
((0@0 corner:image extent) containsPoint:pi) ifTrue:[
- clr := image at:pi.
- colorPanel notNil ifTrue:[
- colorPanel setColor:clr.
- ] ifFalse:[
- Transcript showCr:clr displayString
- ]
+ ^ image at:pi.
+ ].
+ ^ nil
+
+ "Created: 8.5.1996 / 00:15:55 / stefan"
+!
+
+showColorAtX:x y:y
+ |clr|
+
+ clr := self getColorAtX:x y:y.
+ clr notNil ifTrue:[
+ colorPanel notNil ifTrue:[
+ colorPanel setColor:clr.
+ ] ifFalse:[
+ Transcript showCr:clr displayString
+ ]
]
+
+ "Modified: 8.5.1996 / 00:20:45 / stefan"
! !
!ImageEditView methodsFor:'image processing'!
@@ -380,5 +404,5 @@
!ImageEditView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg2/ImageEditView.st,v 1.16 1996-04-27 18:21:55 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg2/ImageEditView.st,v 1.17 1996-05-07 23:16:57 stefan Exp $'
! !
--- a/ImgEditV.st Thu May 02 18:30:11 1996 +0200
+++ b/ImgEditV.st Wed May 08 01:16:57 1996 +0200
@@ -161,6 +161,17 @@
self showColorAtX:x y:y.
!
+buttonMultiPress:button x:x y:y
+ button == 1 ifTrue:[
+ |clr|
+ clr := self getColorAtX:x y:y.
+ clr inspect.
+ ].
+ super buttonMultiPress:button x:x y:y
+
+ "Created: 8.5.1996 / 00:18:06 / stefan"
+!
+
buttonPress:button x:x y:y
button == 1 ifTrue:[
self showColorAtX:x y:y.
@@ -169,19 +180,32 @@
super buttonPress:button x:x y:y
!
-showColorAtX:x y:y
- |pi clr|
+getColorAtX:x y:y
+ |pi|
pi := (x @ y) - margin.
pi := pi // magnification.
((0@0 corner:image extent) containsPoint:pi) ifTrue:[
- clr := image at:pi.
- colorPanel notNil ifTrue:[
- colorPanel setColor:clr.
- ] ifFalse:[
- Transcript showCr:clr displayString
- ]
+ ^ image at:pi.
+ ].
+ ^ nil
+
+ "Created: 8.5.1996 / 00:15:55 / stefan"
+!
+
+showColorAtX:x y:y
+ |clr|
+
+ clr := self getColorAtX:x y:y.
+ clr notNil ifTrue:[
+ colorPanel notNil ifTrue:[
+ colorPanel setColor:clr.
+ ] ifFalse:[
+ Transcript showCr:clr displayString
+ ]
]
+
+ "Modified: 8.5.1996 / 00:20:45 / stefan"
! !
!ImageEditView methodsFor:'image processing'!
@@ -380,5 +404,5 @@
!ImageEditView class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg2/Attic/ImgEditV.st,v 1.16 1996-04-27 18:21:55 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg2/Attic/ImgEditV.st,v 1.17 1996-05-07 23:16:57 stefan Exp $'
! !