예제 #1
0
파일: search.py 프로젝트: gcross/QC-Talks
def load_font( fn, size = None ):
    if size is None:
        f = open( fn, 'rb' )
        t = cPickle.load( f )
        f.close()
        return diafont.new_font( t )
    else:
        return diafont.new_font( fn, size )
예제 #2
0
파일: search.py 프로젝트: markovg/slithy
def load_font(fn, size=None):
    if size is None:
        f = open(fn, 'rb')
        t = cPickle.load(f)
        f.close()
        return diafont.new_font(t)
    else:
        return diafont.new_font(fn, size)
예제 #3
0
파일: test.py 프로젝트: gcross/QC-Talks
import diafont, cPickle

f = open( 'minion.slf', 'rb' )
y = cPickle.load(f)
f.close()

print y[0]

x = diafont.new_font( y )

print x.name
print x.pixelsize
예제 #4
0
import diafont, cPickle

f = open('minion.slf', 'rb')
y = cPickle.load(f)
f.close()

print y[0]

x = diafont.new_font(y)

print x.name
print x.pixelsize