--- a/DropObject.st Fri Mar 05 18:56:19 2004 +0100
+++ b/DropObject.st Fri Mar 05 20:04:29 2004 +0100
@@ -422,24 +422,23 @@
!
isPrintable
- "returns false if file contains nonprintable characters"
-
+ "return false if file contains nonprintable characters"
+
|stream buff size|
isPrintable isNil ifTrue:[
isPrintable := false.
-
- (info isNil or:[self isDirectory]) ifFalse:[
+ (info isNil or:[ self isDirectory ]) ifFalse:[
stream := theObject readStreamOrNil.
stream notNil ifTrue:[
buff := String new:300.
size := stream nextBytes:300 into:buff.
stream close.
- ].
- 1 to:size do:[:i|
- (buff at:i) isPrintable ifFalse:[
- ^ isPrintable
- ]
+ 1 to:size do:[:i |
+ (buff at:i) isPrintable ifFalse:[
+ ^ false
+ ]
+ ].
].
isPrintable := true
]
@@ -513,5 +512,5 @@
!DropObject class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libview2/DropObject.st,v 1.14 2003-06-12 11:09:59 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libview2/DropObject.st,v 1.15 2004-03-05 19:03:49 stefan Exp $'
! !