Functions / text font
font(font)
font( )
font(string font)

Allows to set font to a jCanvaScript text or to check it. By default font is 10px sans-serif.
font( )
return: string font
Code
<script type="text/javascript">
	function start_1(idCanvas)
	{
		alert(jc('#myText_1').font());
	}
	function onload_1(idCanvas)
	{
		jc.start(idCanvas);
		jc.clear(idCanvas);
		jc.text("Text example",90,130)
			.id('myText_1');
		jc.start(idCanvas);
	}
</script>
<canvas id="canvas_1" width="250px" height="265px"></canvas>
View
font(string font)
return: object
Allows to set font to a jCanvaScript text.
Code
<script type="text/javascript">
	function start_2(idCanvas)
	{
		jc('#myText_2')
			.font('15px Times New Roman');
		jc.start(idCanvas);
	}
	function stop_2(idCanvas)
	{
		jc('#myText_2')
			.font('10px Tahoma');
		jc.start(idCanvas);
	}
	function onload_2(idCanvas)
	{
		jc.start(idCanvas);
		jc.text("Text example",90,130)
			.id('myText_2');
		jc.start(idCanvas);
	}
</script>
<canvas id="canvas_2" width="250px" height="265px"></canvas>
View