Stencil, Forms

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Stencil, Forms

Frédéric Ferrère-2
Hello, all-

first, i apologize about my english :)

I've played with forms and stencils and an error occured in the
following piece of code :

(ImageMorph new image contentsOfArea: (Rectangle origin: 0@0 extent:
10@10)) stencil

evaluate this code and the following error occurs :

"Error : Instances of UndefinedObject are not indexable"

But the following code doesn't  raise any error :

ImageMorph new image stencil contentsOfArea: (Rectangle origin: 0@0
extent: 10@10)

Any ideas ?

Thanks

--
FERRERE Frédéric

Reply | Threaded
Open this post in threaded view
|

Re: Stencil, Forms

K. K. Subramaniam
On Saturday 19 May 2007 3:07 pm, Frédéric Ferrère wrote:

> Hello, all-
>
> first, i apologize about my english :)
>
> I've played with forms and stencils and an error occured in the
> following piece of code :
>
> (ImageMorph new image contentsOfArea: (Rectangle origin: 0@0 extent:
> 10@10)) stencil
>
> evaluate this code and the following error occurs :
>
> "Error : Instances of UndefinedObject are not indexable"
stencil needs a form with a color table. contentsOfArea does not copy over
color maps automatically (see comment in ColorForms). Hence the error.

Try:
ImageMorph new explore
and
(ImageMorph new contentsOfArea: (0@0 extent: 10@10)) explore
to see the difference.

Hope this helps .. Subbu