N-gones - Slow version: Difference between revisions

From JSXGraph Wiki
No edit summary
No edit summary
Line 20: Line 20:
mn_eck(36,20);
mn_eck(36,20);
</textarea><br />
</textarea><br />
<input type="button" value="run" onClick="run()">
<input type="button" value="run" onClick="runturtle()">
<input type="button" value="clear" onClick="clearturtle()">
<input type="button" value="clear" onClick="clearturtle()">
</form>
</form>
Line 28: Line 28:
var brd = JXG.JSXGraph.initBoard('jxgbox', {originX:300, originY:300, unitX:1, unitY:1});
var brd = JXG.JSXGraph.initBoard('jxgbox', {originX:300, originY:300, unitX:1, unitY:1});
var t = brd.createElement('turtle',[],{fillColor:'yellow'});
var t = brd.createElement('turtle',[],{fillColor:'yellow'});
function run() {
 
function runturtle() {
   var code = $('inputtext').value;
   var code = $('inputtext').value;
   if (code=='') { return; }
   if (code=='') { return; }
Line 36: Line 37:
   t.cs();
   t.cs();
}
}
//run();
//runturtle();
</jsxgraph>
</jsxgraph>

Revision as of 15:48, 25 February 2009