summaryrefslogtreecommitdiff
path: root/docs/pycon2010/graph.py
blob: 96ffde72ee89a91018135b4fd75b7c77b962c423 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
from turtle import *
pu()
goto(-400,-400)

def label(txt):
    write(txt, font=('Arial', 20, 'italic'))
hideturtle()
width(6)

def line(len, _label):
    start = pos()
    pd()
    forward(len)
    pu()
    forward(30)
    pd()
    label(_label)
    pu()
    goto(start)

def tech(x, y, _label):
    pu()
    goto(x, y)
    pd()
    write(_label, font=('Arial', 40, 'bold'))
    pu()
    
line(600, "Easy to write")
left(90)
line(600, "Easy to use")

tech(-360, 160, 'GUI')
tech(-390, 100, 'AJAX')
tech(-300, -10, 'webapp')
tech(190, -380, 'CLU')
tech(60, -320, 'TUI')
tech(100, -210, 'cmd')
tech(80, -80, 'cmd2')

while True:
    pass