[Laszlo-user] DrawView
Khurram Samad
khurram at geniteam.com
Tue Sep 4 04:46:01 PDT 2007
Can someone help on drawView ?
Issue: The text is created as a subview of the drawview whereas the drawing
is done on the drawview itself. I want the text to behave just like any
other drawing on the draw view. Following is a sample code that exhibits
this property of drawview and text.
<canvas>
<drawview width="250" height="250">
<handler name="oninit">
this.lineWidth=10;
this.fillStyle=0x3366cc;
this.strokeStyle=0x003388;
this.rect(10,10,150,150);
this.closePath();
this.stroke();
this.fill();
t = new LzText(this);
t.setText("Undead Text");
t.setX(30);
t.setY(30);
this.beginPath();
this.moveTo(30,30);
this.lineTo(100,50);
this.stroke();
this.closePath();
this.beginPath();
this.moveTo(70,30);
this.lineTo(10,50);
this.stroke();
this.closePath();
</handler>
</drawview>
</canvas>
-- Khurram Samad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.openlaszlo.org/pipermail/laszlo-user/attachments/20070904/c15f9268/attachment-0001.html
More information about the Laszlo-user
mailing list