Image.st
changeset 3865 18532e89cdca
parent 3864 b04f2f0c5eae
child 3866 c01473a90934
--- a/Image.st	Mon Apr 28 12:14:49 2003 +0200
+++ b/Image.st	Mon Apr 28 12:15:34 2003 +0200
@@ -2186,7 +2186,7 @@
         #( red0 green0 blue0  red1 green1 blue1 ... redN greenN blueN)
      where each component must be a byteValue in 0..255."
 
-    self colorMap:(MappedPalette rgbBytesVector:anArray)
+    self colorMap:(Colormap "MappedPalette" rgbBytesVector:anArray)
 !
 
 colorMapFromRGBValueArray:anArray
@@ -2195,7 +2195,7 @@
         #( rgb0 rgb1  ... rgbN)
      where each element must be an rgbValue in 0..FFFFFF."
 
-    self colorMap:(MappedPalette rgbValueVector:anArray)
+    self colorMap:(Colormap "MappedPalette" rgbValueVector:anArray)
 !
 
 container:aVisualContainer
@@ -5866,74 +5866,14 @@
     "Modified: 29.5.1996 / 10:52:36 / cg"
 !
 
-asOrderedDitheredGrayImageDepth:depth
-    "return a dithered depth-x grey image from the receiver image.
-     Uses an 8x8 dithermatrix."
-
-    |dither|
-
-    dither := self class orderedDitherMatrixOfSize:8.
-
-    (depth == 1) ifTrue:[
-	"/ for monochrome, there is highly specialized
-	"/ monochrome dither code available
-
-	^ Depth1Image
-	    width:width
-	    height:height
-	    fromArray:(
-		self
-		    orderedDitheredMonochromeBitsWithDitherMatrix:dither
-		    ditherWidth:8)
-    ].
-
-    ^ (self class implementorForDepth:depth)
-	width:width
-	height:height
-	fromArray:(
-	    self
-		orderedDitheredGrayBitsWithDitherMatrix:dither
-		ditherWidth:8
-		depth:depth)
-
-    "
-     |i i1 i2 i4 i8|
-
-     i := Image fromFile:'goodies/bitmaps/claus.gif'.
-     i1 := i asOrderedDitheredGrayImageDepth:1.
-     i1 inspect.
-
-     i2 := i asOrderedDitheredGrayImageDepth:2.
-     i2 inspect.
-
-     i4 := i asOrderedDitheredGrayImageDepth:4.
-     i4 inspect.
-
-     i8 := i asOrderedDitheredGrayImageDepth:8.
-     i8 inspect.
-    "
-
-    "
-     |i i1 i2 i4 i8|
-     i := Image fromFile:'goodies/bitmaps/garfield.gif'.
-     i1 := i asOrderedDitheredGrayImageDepth:1.
-     i1 inspect.
-
-     i2 := i asOrderedDitheredGrayImageDepth:2.
-     i2 inspect.
-
-     i4 := i asOrderedDitheredGrayImageDepth:4.
-     i4 inspect.
-
-     i8 := i asOrderedDitheredGrayImageDepth:8.
-     i8 inspect.
-
-     i2 := i8 asOrderedDitheredGrayImageDepth:2.
-     i2 inspect.
-    "
-
-    "Created: 7.6.1996 / 18:03:54 / cg"
-    "Modified: 24.6.1997 / 22:19:36 / cg"
+displayOn:aGC x:x y:y
+    "draw the receiver in the graphicsContext, aGC.
+     Smalltalk-80 compatibility"
+
+    aGC displayForm:self x:x y:y.
+
+    "Modified: 23.4.1996 / 11:12:31 / cg"
+    "Created: 12.5.1996 / 20:14:31 / cg"
 !
 
 displayOn:aGC x:x y:y opaque:opaque
@@ -12536,7 +12476,7 @@
 !Image class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview/Image.st,v 1.335 2003-04-28 10:14:11 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview/Image.st,v 1.336 2003-04-28 10:15:21 cg Exp $'
 ! !
 
 Image initialize!