[Seaside] How do I render an SVG string?

Hannes Hirzel hannes.hirzel at gmail.com
Tue Mar 29 14:27:24 UTC 2011


Johan,

I had a look at
MCHttpRepository
	location: 'http://www.squeaksource.com/SeasideDynamicSVG'
	user: ''
	password: ''

It is geared towards beeing a graphics API to work with an SVG canvas.
This will be useful for me later.

The thing I am looking for at this very moment is just how do I  "pass
through" an existing XML svg string.

Or put the question otherwise: how do I pass through XHTML or SVG
strings unaltered?

--Hannes



On 3/29/11, Johan Brichau <johan at inceptive.be> wrote:
> Take a look at the SeasideDynamicSVG project, available on squeaksource
>
> On 29 Mar 2011, at 12:44, Hannes Hirzel wrote:
>
>> Hello
>>
>> A quick question:
>> How do I output some SVG code?
>>
>> (http://www.w3.org/Graphics/SVG/)
>>
>> mySVGstring := '<svg width="100%" height="100%" version="1.1"
>> xmlns="http://www.w3.org/2000/svg">
>>
>> <path d="M250 150 L150 350 L350 350 Z"
>> style="fill:yellow;stroke:red;stroke-width:24"/>
>>
>> </svg>'.
>>
>>   html ........ mySVGstring.
>>
>> What do I need to put on the place of ....... ?
>>
>> Regards and thank you in advance
>> Hannes
>>
>>
>>
>> Note: The class WASvgFunctionalTest
>>
>> has the example
>>
>> renderContentOn: html
>> 	html object
>> 		type: 'image/svg+xml' seasideMimeType;
>> 		width: 600;
>> 		height: 800;
>> 		standby: 'loading tiger';
>> 		url: 'http://croczilla.com/bits_and_pieces/svg/samples/tiger/tiger.svg';
>> 		with: 'Your browser doesn''t support SVG'
>> _______________________________________________
>> seaside mailing list
>> seaside at lists.squeakfoundation.org
>> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
> _______________________________________________
> seaside mailing list
> seaside at lists.squeakfoundation.org
> http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: SeasideDynamicSVG.PNG
Type: image/png
Size: 43194 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/seaside/attachments/20110329/7a5f3ba9/SeasideDynamicSVG-0001.png


More information about the seaside mailing list