I don't know how to do it with Polymorph.
surf := AthensCairoSurface extent: 100@100.
surf drawDuring: [:can |
surf clear.
can setPaint: Color red.
can drawShape: (
can createPath: [:path |
path�
absolute;
moveTo: 0@25;
curveVia: 25@0 to: 50@ 25;
curveVia: 75@0 to: 100@ 25;
lineTo: 50@75;
lineTo: 0@25
])
].
Display getCanvas drawImage: surf asForm at: 25@25
Athens is by default in Pharo 3. If you are on Pharo 2, there is a configuration to load it somewhere :
Gofer new
� � smalltalkhubUser: 'Pharo' project: 'Athens';
� � configuration;
� � load.
ConfigurationOfAthens loadStable.
But I don't know if you have to specify a version for Pharo 2.0 or something like that.