squeakers,
I think the implementation for PasteUpMorph::cursorWrapped: is flawed.
I used a Holder to hold 4 Sketches to use in an animation cycle. I made a 'tick count' variable and each tick of a scrip set the Holder cursor to tick count. Once tick is greater than 4 things go wrong, the first sketch gets shown twice and the last never.
The code for PasteUpMorph::cursorWrapped looks like it would work if the 'indexing' of elements was zero based - but it seems to be '1' based - at least for a 'Holder'.
the relevant part of the method is: t2 > submorphs size ifTrue: [submorphs size > 0 ifTrue: [cursor _ cursor \ submorphs size] ifFalse: [cursor _ 1]].
I think it probbaly means 'cursor _ cursor \ submorphs size + 1' but there could be other users of PasteUpMorph that are zero based.
Is this a bug? seems that it would be easier to make animation cycles work like kids would expect them to with a change like this. Can someone give me a reference to the bug reporting / fixing proceedure for squeakland codebase?
regards, nicholas
Nicholas Bennett wrote:
squeakers,
I think the implementation for PasteUpMorph::cursorWrapped: is flawed.
I used a Holder to hold 4 Sketches to use in an animation cycle. I made a 'tick count' variable and each tick of a scrip set the Holder cursor to tick count. Once tick is greater than 4 things go wrong, the first sketch gets shown twice and the last never.
The code for PasteUpMorph::cursorWrapped looks like it would work if the 'indexing' of elements was zero based - but it seems to be '1' based - at least for a 'Holder'.
the relevant part of the method is: t2 > submorphs size ifTrue: [submorphs size > 0 ifTrue: [cursor _ cursor \ submorphs size] ifFalse: [cursor _ 1]].
I think it probbaly means 'cursor _ cursor \ submorphs size + 1' but there could be other users of PasteUpMorph that are zero based.
Is this a bug? seems that it would be easier to make animation cycles work like kids would expect them to with a change like this. Can someone give me a reference to the bug reporting / fixing proceedure for squeakland codebase?
regards, nicholas
Squeakland mailing list Squeakland@squeakland.org http://squeakland.org/mailman/listinfo/squeakland
Why not use a etoy test. Take a look at the attached script. Karl
karl,
Thanks for your reply.
I can see how one could code around the issue where ever one got caught by it.
I cannot help thinking though that the current #cursorWrapped 'just cannot be right' so I'll look into reporting a bug and providing a fix.
regards, nicholas
From: karl karl.ramberg@chello.se To: Nicholas Bennett nicholasjbennett@hotmail.com CC: squeakland@squeakland.org Subject: Re: [Squeakland] bug in PasteUpMorph::cursorWrapped: ? Date: Sat, 04 Jun 2005 21:41:13 +0200
Nicholas Bennett wrote:
squeakers,
I think the implementation for PasteUpMorph::cursorWrapped: is flawed.
I used a Holder to hold 4 Sketches to use in an animation cycle. I made a 'tick count' variable and each tick of a scrip set the Holder cursor to tick count. Once tick is greater than 4 things go wrong, the first sketch gets shown twice and the last never.
The code for PasteUpMorph::cursorWrapped looks like it would work if the 'indexing' of elements was zero based - but it seems to be '1' based - at least for a 'Holder'.
the relevant part of the method is: t2 > submorphs size ifTrue: [submorphs size > 0 ifTrue: [cursor _ cursor \ submorphs size] ifFalse: [cursor _ 1]].
I think it probbaly means 'cursor _ cursor \ submorphs size + 1' but there could be other users of PasteUpMorph that are zero based.
Is this a bug? seems that it would be easier to make animation cycles work like kids would expect them to with a change like this. Can someone give me a reference to the bug reporting / fixing proceedure for squeakland codebase?
regards, nicholas
Squeakland mailing list Squeakland@squeakland.org http://squeakland.org/mailman/listinfo/squeakland
Why not use a etoy test. Take a look at the attached script. Karl << Sketch5.jpeg >>
Hi, Nicholas - We do think you've found a bug and we are investigating...thanks for bringing it to our attention. Should you find other bugs, inconsistencies, etc. you are welcome to either share with this list or send directly to webmaster@squeakland.org. thanks and cheers, Kim
At 7:13 PM -0700 6/3/05, Nicholas Bennett wrote:
squeakers,
I think the implementation for PasteUpMorph::cursorWrapped: is flawed.
I used a Holder to hold 4 Sketches to use in an animation cycle. I made a 'tick count' variable and each tick of a scrip set the Holder cursor to tick count. Once tick is greater than 4 things go wrong, the first sketch gets shown twice and the last never.
The code for PasteUpMorph::cursorWrapped looks like it would work if the 'indexing' of elements was zero based - but it seems to be '1' based - at least for a 'Holder'.
the relevant part of the method is: t2 > submorphs size ifTrue: [submorphs size > 0 ifTrue: [cursor _ cursor \ submorphs size] ifFalse: [cursor _ 1]].
I think it probbaly means 'cursor _ cursor \ submorphs size + 1' but there could be other users of PasteUpMorph that are zero based.
Is this a bug? seems that it would be easier to make animation cycles work like kids would expect them to with a change like this. Can someone give me a reference to the bug reporting / fixing proceedure for squeakland codebase?
regards, nicholas
Squeakland mailing list Squeakland@squeakland.org http://squeakland.org/mailman/listinfo/squeakland
squeakland@lists.squeakfoundation.org