Draw face user Kantale
From PyPedia
Contents |
[edit] Documentation
Draws a pretty face by using Javascript's canvas.
Example taken from: http://simeonvisser.hubpages.com/hub/HTML5-Tutorial-Basics-of-Canvas-Drawing
[edit] Parameters
<inputs> </inputs>
[edit] Return
[edit] See also
[edit] Code
def Draw_face_user_Kantale(): to_draw = """ var ctx = canvas.getContext("2d"); ctx.beginPath(); ctx.arc(150, 150, 100, 0, 2 * Math.PI, false); ctx.closePath(); ctx.fillStyle = "rgb(255, 0, 0)"; ctx.stroke(); ctx.fill(); ctx.beginPath(); ctx.arc(120, 130, 20, 0, 2 * Math.PI, false); ctx.closePath(); ctx.fillStyle = "rgb(255, 255, 255)"; ctx.stroke(); ctx.fill(); ctx.beginPath(); ctx.arc(123, 133, 4, 0, 2 * Math.PI, false); ctx.closePath(); ctx.fillStyle = "rgb(0, 0, 255)"; ctx.stroke(); ctx.fill(); ctx.beginPath(); ctx.arc(180, 130, 20, 0, 2 * Math.PI, false); ctx.closePath(); ctx.fillStyle = "rgb(255, 255, 255)"; ctx.stroke(); ctx.fill(); ctx.beginPath(); ctx.arc(183, 133, 4, 0, 2 * Math.PI, false); ctx.closePath(); ctx.fillStyle = "rgb(0, 0, 255)"; ctx.stroke(); ctx.fill(); ctx.beginPath(); ctx.arc(155, 165, 60, 0, 3, false); ctx.closePath(); ctx.lineWidth = 5; ctx.strokeStyle = "rgb(255, 255, 0)"; ctx.fillStyle = "rgb(255, 255, 255)"; ctx.stroke(); ctx.fill(); """ Draw_user_Kantale(to_draw, False, 300, 300)
[edit] Unit Tests
def uni1(): return True
[edit] Development Code
def Draw_face_user_Kantale(): pass
[edit] Permissions
[edit] Documentation Permissions
Kantale
[edit] Code Permissions
Kantale
[edit] Unit Tests Permissions
Kantale