[Squeakland] drawing on images

Scott Wallace scott.wallace at squeakland.org
Sat Dec 25 19:03:00 PST 2004


The copy of my memo below that reached me via Squeakland had for some 
reason had its inline graphic stripped, rendering the final paragraph 
rather inscrutable...

Here's another attempt to send the graphic that was supposed to 
follow the final paragraph:



... and if that again fails to make it way through, here in text is 
the sense of what the phrase in the script said:

	Playfield's graphic <- myPicture's graphic

Cheers,

  -- Scott


At 4:23 AM -0800 12/23/04, Scott Wallace wrote:
>Hi, Randy,
>
>Only PasteUpMorphs (a.k.a. Playfields) are equipped to accommodate 
>pen trails.  So the way to get pen trails drawn on an imported 
>graphic is to make the imported graphic be the "background" of a 
>playfield.
>
>This is easy enough to do in a variety of ways but there is no 
>one-step command to do it -- though probably there should be.
>
>Here's one way:  Get a fresh playfield from Supplies; from its debug 
>halo handle choose "inspect morph"; in the bottom pane of the 
>resulting Inspector type and then evaluate an expression like:
>	self backgroundForm: (Form fromFileNamed: 'myGraphic.jpeg')
>where you have substituted the correct file name.
>
>If you have a graphic previously "imported" into Squeak, with name 
>"myGraphic", you could instead use something like:
>	self backgroundForm: (Imports default imports at: 'myGraphic')
>
>
>Another slightly more tedious way that doesn't involve evaluating 
>any smalltalk expressions is to "open" the graphic from a file-list 
>(into a Sketch which you rename, say, "myPicture,") and then build 
>an etoy script for the playfield of the following form, and run it 
>once:
>
>
>
>Cheers,
>
>  -- Scott
>
>
>At 7:26 PM -0500 12/20/04, Randy Heiland wrote:
>>Is there any way to have my (pen down) objects draw over the top of imported
>>images?
>>
>>--Randy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: P304329A3_2
Type: image/png
Size: 31200 bytes
Desc: not available
Url : http://squeakland.org/pipermail/squeakland/attachments/20041225/a08903c9/P304329A3_2-0001.png


More information about the Squeakland mailing list