--- a/ImageEditor.st Wed Apr 11 20:32:38 2001 +0200
+++ b/ImageEditor.st Mon Apr 23 22:59:08 2001 +0200
@@ -2171,7 +2171,7 @@
clearMaskedPixels
"clear all masked pixels (to pixelValue 0)"
- |depth newColorMap newImage oldImage usedColors oldToNew oldBits newBits tmpBits|
+ |newImage oldImage|
oldImage := self image.
@@ -2179,11 +2179,16 @@
self withExecuteCursorDo:[
newImage := oldImage clearMaskedPixels.
+ 0 to:newImage height - 1 do:[:y |
+ 0 to:newImage width - 1 do:[:x |
+ (newImage maskAtX:x y:y) == 0 ifTrue:[
+ newImage pixelAtX:x y:y put:0
+ ]
+ ]
+ ].
+
(imageEditView image:newImage) notNil ifTrue:[
self fetchImageData.
-"/ self listOfColors contents: newImage colorMap.
-"/ self findColorMapMode.
-"/ self updateLabelsAndHistory.
]
]
!
@@ -2500,13 +2505,13 @@
!
fetchImageData
- |image|
-
- (image := imageEditView image) notNil ifTrue:[
- self listOfColors contents:(image colorMap).
- self findColorMapMode.
- self updateLabelsAndHistory.
- ]
+ |image|
+
+ (image := imageEditView image) notNil ifTrue:[
+ self listOfColors contents:(image colorMap).
+ self findColorMapMode.
+ self updateLabelsAndHistory.
+ ]
!
makeGrayScale