(初學者)我想知道有關Python turtle 的文字編輯!

188 views
Skip to first unread message

Coco

unread,
Nov 17, 2017, 12:54:56 AM11/17/17
to python.tw
我想要用 turtle 畫一個狗掌來當作一個非營利組織的LOGO,
這是我目前的圖案(code),但是我還想加文字在上面 "FOHA" (Friends of Homeless Animals) ,可以教我怎麼把文字加上去嗎?謝謝。

from turtle import *
 
turtle = Turtle("turtle")

#CIRCLES

CIRCLES = [ #((set position), radius)
    ((0, 0), 60), # first circle
    ((-120, -40), 50), # second circle
    ((140, 0), 60), # third circle
    ((260, -40), 50), # last circle
    ]

for position, radius in CIRCLES:
    turtle.pencolor('yellow')
    turtle.pensize('10')
    turtle.penup()
    turtle.color('saddle brown')
    turtle.begin_fill()
    turtle.setposition(position)
    turtle.pendown()
    turtle.circle(radius)
    turtle.end_fill()
    turtle.hideturtle() #Make the turtle invisible


#HEART
turtle = shape("turtle")

def curvemove():
    for i in range(200):
        right(1)
        forward(1)

penup()
color('dark orange')        
begin_fill()
setposition(70, 0)
left(-40)
forward(111.65)
curvemove()
left(120)
curvemove()
forward(111.65)
end_fill()
done()

#Friends of Homeless Animal (FOHA)

Sonic Yang

unread,
Nov 17, 2017, 7:47:56 AM11/17/17
to pyth...@googlegroups.com

--
這是 Google 網上論壇針對「python.tw」群組發送的訂閱通知郵件。
如要取消訂閱這個群組並停止接收來自這個群組的郵件,請傳送電子郵件到 pythontw+unsubscribe@googlegroups.com
如要在這個群組張貼留言,請傳送電子郵件到 pyth...@googlegroups.com
請前往以下網址造訪這個群組:https://groups.google.com/group/pythontw
如需更多選項,請前往:https://groups.google.com/d/optout

Reply all
Reply to author
Forward
0 new messages