Subbu,
Thanks this is a lot of fun and useful. So I tried to use it for fractions
(although I really like your art work project at Ofset
<http://community.ofset.org/index.php/Grab_area_button>better, but I am
thinking about fractions lately)
I used the "do menu item | stencil a sketch" scripting tile in a "Mouse
Down" script. The rectangle then moves forward by its width. So with a
series of successive clicks you can make a fraction.
It get's my vote for inclusion in the next release.
Thanks,
Stephen
On Fri, Jul 22, 2011 at 10:02 PM, K. K. Subramaniam <kksubbu.ml(a)gmail.com>wrote:
> Hi Steve,
>
> I have attached a patch to Morphic that adds three functions to 'extras...'
> menu for any Morph. These enable anyone to quick convert an assembly of
> morphs
> into a sketch (e.g. a car assembled using rectangles and ellipses), use any
> morph as a stencil to cut out a sketch from underlying screen area and to
> create silhouette (shadow) sketch respectively.
>
> To use the patch, just drop it into Etoys and select "file it in". I would
> appreciate it if you could use it and let me know if it is useful. If so, I
> will send it to Etoys Inbox.
>
> Subbu
>
Bert Freudenberg uploaded a new version of ReleaseBuilder to project Etoys:
http://source.squeak.org/etoys/ReleaseBuilder-bf.10.mcz
==================== Summary ====================
Name: ReleaseBuilder-bf.10
Author: bf
Time: 29 August 2011, 9:52:29 pm
UUID: 6df46d7b-9113-4a0c-aab0-40dbeb89efe7
Ancestors: ReleaseBuilder-bf.9
fix copyrigth check
=============== Diff against ReleaseBuilder-bf.9 ===============
Item was changed:
ReleaseBuilder subclass: #ReleaseBuilderSqueakland
instanceVariableNames: ''
classVariableNames: ''
poolDictionaries: ''
category: 'ReleaseBuilder'!
+ !ReleaseBuilderSqueakland commentStamp: '<historical>' prior: 0!
- !ReleaseBuilderSqueakland commentStamp: 'bf 10/13/2010 01:16' prior: 0!
Note: as of this writing, the only reliable way to get rid of all but the current project is to execute the following, one line at a time...
+ Smalltalk zapAllOtherProjects. "close inspector if it popped up"
- Smalltalk zapAllOtherProjects.
ProjectHistory currentHistory initialize.
Smalltalk garbageCollect.
Project rebuildAllProjects.
ReleaseBuilderSqueakland new prepareReleaseImage.!
Item was changed:
----- Method: ReleaseBuilderSqueakland>>checkCopyright (in category 'utilities') -----
checkCopyright
| inNotice inImage inFile dir |
dir := FileDirectory on: Smalltalk imagePath.
[inFile := (dir readOnlyFileNamed: 'NOTICE') wantsLineEndConversion: true; contentsOfEntireFile]
on: FileDoesNotExistException do: [:ex |
dir = FileDirectory default
ifTrue: [dir := dir containingDirectory. ex retry]
ifFalse: [self error: 'NOTICE file not found']].
inFile = Utilities copyrightNotice ifFalse: [self error: 'NOTICE file does not match image'].
inNotice := ((Utilities copyrightNotice findTokens: Character cr)
select: [:s | s includesSubString: '(c)'])
collect: [:s | s withBlanksTrimmed].
+ inNotice := {inNotice first. inNotice last}.
+ inImage := (Smalltalk copyright findTokens: Character cr) asArray.
- inImage := Smalltalk copyright findTokens: Character cr.
inNotice = inImage ifFalse: [self error: 'Copyright declarations do not match'].!
Karl Ramberg uploaded a new version of Etoys to project Etoys:
http://source.squeak.org/etoys/Etoys-kfr.93.mcz
==================== Summary ====================
Name: Etoys-kfr.93
Author: kfr
Time: 28 August 2011, 7:31:07 pm
UUID: 2bbca75a-f220-7449-96b5-b203ce0e8c50
Ancestors: Etoys-kfr.92
http://tracker.squeakland.org/browse/SQ-983
=============== Diff against Etoys-kfr.92 ===============
Karl Ramberg uploaded a new version of Etoys to project Etoys:
http://source.squeak.org/etoys/Etoys-kfr.92.mcz
==================== Summary ====================
Name: Etoys-kfr.92
Author: kfr
Time: 28 August 2011, 7:27:42 pm
UUID: 48a7b6b1-18f3-9149-9e01-1cfcd196f98c
Ancestors: Etoys-kfr.91
http://tracker.squeakland.org/browse/SQ-982
=============== Diff against Etoys-kfr.91 ===============
Item was changed:
----- Method: Morph>>putOnForeground (in category '*Etoys') -----
putOnForeground
+ self holdsSeparateDataForEachInstance
+ ifTrue: [self
+ confirm: 'Caution -- every card of this background
- "Place the receiver, formerly on the background, onto the foreground. If the receiver needs data carried on its behalf by the card, those data will be lost, so in this case get user confirmation before proceeding."
-
- self holdsSeparateDataForEachInstance "later add the refinement of not putting up the following confirmer if only a single instance of the current background's uniclass exists"
- ifTrue:
- [self confirm: 'Caution -- every card of this background
formerly had its own value for this
item. If you put it on the foreground,
+ the values of this item on all other
- the values of this item on all other
cards will be lost' translated
orCancel: [^ self]].
-
self removeProperty: #shared.
+ self stack reassessBackgroundShape!
- self stack reassessBackgroundShape.
- "still work to be done here!!"!
Karl Ramberg uploaded a new version of Etoys to project Etoys:
http://source.squeak.org/etoys/Etoys-kfr.91.mcz
==================== Summary ====================
Name: Etoys-kfr.91
Author: kfr
Time: 28 August 2011, 7:24:38 pm
UUID: dbf9fba5-d0fe-3243-bd8f-6ac79b982011
Ancestors: Etoys-kfr.90
http://tracker.squeakland.org/browse/SQ-981
=============== Diff against Etoys-kfr.90 ===============
Item was changed:
----- Method: Morph class>>additionsToViewerCategoryTests (in category '*eToys-scripting') -----
additionsToViewerCategoryTests
+ ^ #(#tests #(#(#slot #isOverColor 'whether any part of the object is over the given color' #Boolean #readOnly #Player #seesColor: #unused #unused) #(#slot #isUnderMouse 'whether the object is under the current mouse position' #Boolean #readOnly #Player #getIsUnderMouse #unused #unused) #(#slot #colorSees 'whether the given color sees the given color' #Boolean #readOnly #Player #color:sees: #unused #unused) #(#slot #overlaps 'whether I overlap a given object' #Boolean #readOnly #Player #overlaps: #unused #unused) #(#slot #overlapsAny 'whether I overlap a given object or one of its siblings or similar objects' #Boolean #readOnly #Player #overlapsAny: #unused #unused) #(#slot #touchesA 'whether I overlap any Sketch that is showing the same picture as a particular prototype.' #Boolean #readOnly #Player #touchesA: #unused #unused) #(#slot #obtrudes 'whether the object sticks out over its container''s edge' #Boolean #readOnly #Player #getObtrudes #unused #unused)) )!
- "Answer viewer additions for the 'tests' category."
-
- "Note: Because of intractable performance problems in continuously evaluating isOverColor in a Viewer, the isOverColor entry is not given a readout"
-
- ^#(
- #tests
- (
- (slot isOverColor 'whether any part of the object is over the given color' Boolean readOnly Player seesColor: unused unused)
- (slot isUnderMouse 'whether the object is under the current mouse position' Boolean readOnly Player getIsUnderMouse unused unused)
- (slot colorSees 'whether the given color sees the given color' Boolean readOnly Player color:sees: unused unused)
- (slot overlaps 'whether I overlap a given object' Boolean readOnly Player overlaps: unused unused)
- (slot overlapsAny 'whether I overlap a given object or one of its siblings or similar objects' Boolean readOnly Player overlapsAny: unused unused)
- (slot touchesA 'whether I overlap any Sketch that is showing the same picture as a particular prototype.' Boolean readOnly Player touchesA: unused unused)
- (slot obtrudes 'whether the object sticks out over its container''s edge' Boolean readOnly Player getObtrudes unused unused)
- )
- )
- !