# HG changeset patch # User Claus Gittinger # Date 1458922341 -3600 # Node ID d5ce6fbb34cddc07f79991efa431a19f91d3a5bf # Parent e43475084bb57946b12357021137ff53889e092a #DOCUMENTATION class: Point comment/format in: #scaleBy: #translateBy: diff -r e43475084bb5 -r d5ce6fbb34cd Point.st --- a/Point.st Fri Mar 25 17:11:32 2016 +0100 +++ b/Point.st Fri Mar 25 17:12:21 2016 +0100 @@ -589,7 +589,7 @@ scaleBy:aScale "scale the receiver, by replacing coordinates by the product - of the receivers coordinates and the scale (a Point or Number). + of the receiver's coordinates and the scale (a Point or Number). This is destructive (modifies the receiver, not a copy) and should only be used if you know, that you are the exclusive owner of the receiver." @@ -597,14 +597,14 @@ |scalePoint| (aScale isMemberOf:Point) ifTrue:[ "type hint to stc" - x := x * aScale x. - y := y * aScale y. - ^ self + x := x * aScale x. + y := y * aScale y. + ^ self ]. aScale isNumber ifTrue:[ - x := x * aScale. - y := y * aScale. - ^ self + x := x * aScale. + y := y * aScale. + ^ self ]. "this is the general (& clean) code ..." @@ -616,7 +616,7 @@ translateBy:anOffset "translate the receiver, by replacing coordinates by the sum - of the receivers coordinated and the scale (a Point or Number). + of the receiver's coordinated and the scale (a Point or Number). This is destructive (modifies the receiver, not a copy) and should only be used if you know, that you are the exclusive owner of the receiver." @@ -624,14 +624,14 @@ |offsetPoint| (anOffset isMemberOf:Point) ifTrue:[ "type hint to stc" - x := x + anOffset x. - y := y + anOffset y. - ^ self + x := x + anOffset x. + y := y + anOffset y. + ^ self ]. anOffset isNumber ifTrue:[ - x := x + anOffset. - y := y + anOffset. - ^ self + x := x + anOffset. + y := y + anOffset. + ^ self ]. "this is the general (& clean) code ..."