Image.st
changeset 2527 5391e6e2c8a6
parent 2526 0575694feb88
child 2530 81b8ffe7662f
--- a/Image.st	Tue Mar 23 18:21:56 1999 +0100
+++ b/Image.st	Tue Mar 23 18:56:17 1999 +0100
@@ -850,13 +850,14 @@
     "create & return an Image from a rectangular area in another image. 
      This can also be used to get a subimage in another depth."
 
-    |newImage|
+    |cls newImage|
 
     self == Image ifTrue:[
-        newImage := (self implementorForDepth:anImage depth) new.
+        cls := (self implementorForDepth:anImage depth).
     ] ifFalse:[
-        newImage := self new.
-    ].
+        cls := self.
+    ].
+    newImage := cls new.
     ^ newImage fromSubImage:anImage in:aRectangle.
 
     "
@@ -974,7 +975,9 @@
      Data must be a ByteArray containing correctly aligned bits for the specified
      depth."
 
-    |img newBits srcRowBytes dstRowBytes srcIndex dstIndex|
+    |img newBits srcRowBytes dstRowBytes 
+     srcIndex "{ Class: SmallInteger }"
+     dstIndex "{ Class: SmallInteger }" |
 
     img := (self implementorForDepth:d) new width:w height:h depth:d .
 
@@ -11597,6 +11600,6 @@
 !Image class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview/Image.st,v 1.264 1999-03-23 17:21:56 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview/Image.st,v 1.265 1999-03-23 17:56:17 cg Exp $'
 ! !
 Image initialize!