示例#1
0
文件: gradient.py 项目: tylott/enable
def gradient():
    gc = GraphicsContext((500, 500))
    gc.scale_ctm(1.25, 1.25)
    draw(gc)
    file_path = tempfile.mktemp(suffix='.png')
    gc.save(file_path, file_format='png')
    return file_path
示例#2
0
def main():
    gc = GraphicsContext((500, 500))

    gc.scale_ctm(1.25, 1.25)
    draw(gc)

    gc.save(splitext(__file__)[0] + '.png', file_format='png')
示例#3
0
def main():
    gc = GraphicsContext((500, 500))

    gc.scale_ctm(1.25, 1.25)
    draw(gc)

    gc.save(splitext(__file__)[0]+'.png', file_format='png')