Re: [Pharo-users] Canvas Transform Goes Haywire if Scaled

2015-02-05 Thread Werner Kassens
On 02/05/2015 03:27 PM, Sean P. DeNigris wrote: This seems so complicated. I would naively think that the API should do much of this for you. For example, why doesn't it know that when there's an offset AND a scale, the transform's offset should be adjusted by the scale? Hi Sean, i guess i would

Re: [Pharo-users] Canvas Transform Goes Haywire if Scaled

2015-02-05 Thread Sean P. DeNigris
Thank you Werner and Nicolai! You were both right :) The transform offset needed to be scaled and the clipping needed to be both translated and scaled, too. The final code was: morph := Morph new topLeft: 200@400; openInWorld. outp

Re: [Pharo-users] Canvas Transform Goes Haywire if Scaled

2015-02-05 Thread Werner Kassens
Hi Sean, the thing is clipped. as you can see here: morph := Morph new topLeft: 200@400; openInWorld. outputRect := (0@0) corner: (250.0@220.0). canvas := Display defaultCanvasClass extent: outputRect extent depth: Display depth. scale := 0.5.

Re: [Pharo-users] Canvas Transform Goes Haywire if Scaled

2015-02-05 Thread Nicolai Hess
2015-02-05 6:29 GMT+01:00 Sean P. DeNigris : > The following works as I expect: > > morph := Morph new > topLeft: 200@400; > openInWorld. > > outputRect := morph fullBounds. > canvas := Display defaultCanvasClass extent: outputRect extent > d

Re: [Pharo-users] Canvas Transform Goes Haywire if Scaled

2015-02-05 Thread Werner Kassens
On 02/05/2015 06:29 AM, Sean P. DeNigris wrote: I had both translation and scale working in a spike by translating with FormCanvas>>#translateBy:during: and then magifying with "canvas form magnifyBy: 0.5", but I want to do this in my morph's drawing method, so I want to do both with the canvas.