[Cuis-dev] [Ann] Changes for VectorGraphics
Juan Vuletich
juan at jvuletich.org
Sun Aug 9 06:39:09 PDT 2020
Hi Hilaire,
On 8/8/2020 4:17 PM, Hilaire Fernandes via Cuis-dev wrote:
> Le 07/08/2020 à 02:38, Juan Vuletich via Cuis-dev a écrit :
>>>
>>> - Looking at Clock morph source, it looks you can make your origin
>>> point whatever you want, is it that ?
>>>
>>
>> Yep. Today 0 at 0 is the center of rotation, but we could make that more
>> flexible.
>
> I wrongly expressed myself. Look at the drawOn: method of ClocklMorph,
> I understand line drawing starting at 0 at 0 is the center of the morph
> area. While it isued to be at the top left corner of the morph area.
>
Yes and no. The good part is that the area is defined by the morph
itself. Consider this example:
Morph subclass: #BezierExample01
instanceVariableNames: ''
classVariableNames: ''
poolDictionaries: ''
category: 'VectorGraphics-Experiments'!
drawOn: aCanvas
aCanvas strokeWidth: 40 color: (Color black alpha: 0.7) do: [
aCanvas cubicBezier: {-100 at 50. 150 at 300. 300 at 400. 300 at 100} ]
That's all it is needed! Try it. The morph, in its @drawOn: method,
decides what space it uses. The position of 0 at 0 is a consequence of
where the morph decides to draw itself in its own coordinate system. The
framework handles all damage repair and coordinates conversions for you.
>>> - With my Polygon Morph, I still have the same issue I described in
>>> my previous sources (see attached cs)
>>>
>>
>> Oh, yes. Now I got it. Fixed too.
> Did you commit? Because the issue is still there.
Cuis will not modify any code without you telling it to. So you need to
load all the updated code in your image.
Be sure to:
- Pull the repo
- Install all the numbered updates to the base image (World / Changes /
Install New Updates is usually enough, but if your folder structure is
not the recommended in the docs, I can't be sure all updates will be
loaded. Same if changes you made to your image modify this behavior)
- Re install any packages that might have changed. VectorGraphics is now
at v1.169. You can check this near the start of the
VectorGraphics.pock.st file (it is human legible text in standard chunk
format). To see what version you have loaded, World / Open / Installed
Packages. The way to reinstall a package is to point at it in the
FileList, and click on [Install Package].
Hope this helps.
> Hilaire
>
> --
> GNU Dr. Geo
> http://drgeo.eu
Cheers,
--
Juan Vuletich
www.cuis-smalltalk.org
https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev
https://github.com/jvuletich
https://www.linkedin.com/in/juan-vuletich-75611b3
@JuanVuletich
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20200809/ecb068d7/attachment.htm>
More information about the Cuis-dev
mailing list