N-gones: Difference between revisions
From JSXGraph Wiki
A WASSERMANN (talk | contribs) No edit summary |
A WASSERMANN (talk | contribs) No edit summary |
||
(6 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
<html> | <html> | ||
<form><textarea id="inputtext" rows=12 cols=35 wrap="off" style="width:600px;"> | <form><textarea id="inputtext" rows=12 cols=35 wrap="off" style="width:600px;"> | ||
function n_eck(ne,sz) { | function n_eck(ne,sz) { | ||
Line 19: | Line 16: | ||
t.cs(); | t.cs(); | ||
t.setProperty({strokeWidth: | t.setProperty({strokeWidth:4,strokeOpacity:0.6,fillOpacity:0.3}); | ||
t.hideTurtle(); | t.hideTurtle(); | ||
mn_eck(36,20); | mn_eck(36,20); | ||
Line 28: | Line 25: | ||
</html> | </html> | ||
===Output=== | ===Output=== | ||
< | <jsxgraph box="box" width="600" height="600"> | ||
var brd = JXG.JSXGraph.initBoard('box', {boundingbox: [-300, 300, 300, -300]}); | |||
var brd = JXG.JSXGraph.initBoard('box', { | var t = brd.create('turtle',[],{fillColor:'yellow'}); | ||
var t = brd. | |||
function run() { | function run() { | ||
brd.suspendUpdate(); | brd.suspendUpdate(); | ||
var code = | var code = document.getElementById('inputtext').value; | ||
if (code=='') { return; } | if (code=='') { return; } | ||
eval(code); | eval(code); | ||
Line 44: | Line 40: | ||
} | } | ||
run(); | run(); | ||
</ | </jsxgraph> | ||
* [[Slow version]] | |||
===References=== | ===References=== |
Latest revision as of 09:13, 6 August 2015
Output
References
This example is from