Nice work, Nicolai!

Brick does not work - It uses some of Canvas' private api, and it is
> difficult to provide this with Athens.


I will try to fix it when have time. Actually there was no need to use that
private api, I just was too lazy to do slightly more math when converting
global coordinates to local ones in drawing methods :)

Cheers,
Alex

On Fri, Jan 23, 2015 at 5:40 PM, Nicolai Hess <nicolaih...@web.de> wrote:

>
>
> 2015-01-10 13:18 GMT+01:00 Nicolai Hess <nicolaih...@web.de>:
>
>>
>> I think I got the MorphTreeTransformMorph now working, need to clean up
>> the code
>> and maybe I 'll upload this to the athens repository.
>>
>> nicolai
>>
>>
>>
>
> I don't know how often I thought "I got this working", but NOW I think I
> got this morphic transformation working :)
>
> I give up to use the AthensTextRenderer classes, they aren't implemented
> fully, to much work for me to do this.
> Instead, I just subclass the DisplayScanner and reimplemented all
> Canvas-draw-methods with athens-drawing-methods.
>
> Still some morphs aren't "ported", but they use some magic. For example,
> for some morphs the drawOn:Canvas methods
> calls many other methods drawBackroundOn: aCanvas, drawIconOn: aCanvas,
> drawLinesOn: ...
> (for exampe: IndentingListItemMorph, MorphTreeMorph). Porting this morphs
> means, we have to duplicate all this methods.
> (Ok there are other options, but I don't want to change something in the
> original Morphic/Canvas workflow).
> Other Morphs just delegate the drawing call, that delegate the calls
> further and deep in this call change the
> drawing actually happens. This again means I have to duplicate all this
> methods just to use an AthensCanvas for drawing.
>
> So, for those Morphs I use a Canvas Wrapper (AthensCanvasWrapper). I
> already wrote about this one, it implements (most)
> of the Morphic/Canvas API on top of Athens, it was an alternative approach
> for Morphic<->Athens porting. This one is
> now a much more advanced version and I can use it in combination with the
> other drawOnAthensCanvas methods.
>
> The drawOnAthensCanvas method in MorphTreeNodeMorph for example just calls
> this
> drawOnAthensCanvas: anAthensCanvas
>     self drawOnCanvasWrapperFor: anAthensCanvas
> which in turn creates an AthensCanvasWrapper and then calls
>   self drawOn: wrapper
> The same Morphic/Canvas drawOn method is used! But the rendering is done
> with Athens.
>
> Rubric does not work - Itself already duplicates many code, I don't want
> to look at this now.
> Brick does not work - It uses some of Canvas' private api, and it is
> difficult to provide this with Athens.
>
>
> Many other things are working,
> PLEASE try it out. Morphic on Athens looks great (except the font issue
> ...).
>
> Just take a fresh image (I use 40442) and load the attached
>
> morphic_on_athens.cs (<-- all code for Morphic<->Athens porting)
> athens_test_display.3.cs (<-- Tests Athens for the whole MorphicWorld)
>
> Open a Workspace (old workspace preferred) and execute
>
> AthensTestDisplay testSwitchToAthensFor: 25.
>
> This will switch the world display rendering for 25 seconds from Morphics
> Canvas-Api to
> Athens.
>
>
> Feedback welcome.
>
>
>
>
>
>
>
>

Reply via email to