Commit 88ad50d0 authored by John H's avatar John H

initial push

parents
#!/usr/bin/env python2
# usage: $ python2 print-font-robofab.py League-Gothic.ufo
from robofab.world import RFont
import sys
font = RFont(sys.argv[1])
for glyph in font:
print glyph.name
#!/usr/bin/env python2
# usage: $ rotate-font-robofab.py League-Gothic.ufo League-Gothic-tranformed.ufo
from robofab.world import RFont
from fontTools.misc.transform import Identity
import sys
import math
matrix = Identity
matrix = matrix.rotate(.25 * math.pi)
#math.radians(45)
font = RFont(sys.argv[1])
for glyph in font:
glyph.transform(matrix)
font.save(sys.argv[2])
#!/usr/bin/env python2
# intro to OSP
- rockstars around the world
- lady picture show
- univers else, sans guilt,
- cosic, radio panik, vj12
#!/usr/bin/ruby
file = "motion-length.ps"
x = 80
y = 80
text = "morphologic"
# directory setup
fullpath = File.expand_path(__FILE__)
dir = File.dirname(fullpath)
(1..text.length).each do |n|
ps = "/fontsize 64 def
/headerfont /Courier findfont fontsize scalefont def
headerfont setfont
#{x+n*20} #{y} moveto
(#{text[n-1]}) show"
Dir.chdir("#{dir}/tmp")
f = File.open(file, 'w')
f.puts ps
f.close
cmd = Thread.new do
%x[convert #{file} motion-length-#{n}.png]
end
cmd.join
end
#!/usr/bin/ruby
file = "motion-size.ps"
x = 80
y = 80
text = "morphologic"
n = 1
# directory setup
fullpath = File.expand_path(__FILE__)
dir = File.dirname(fullpath)
(1..72).each do |n|
ps = "/fontsize #{n} def
/headerfont /Courier findfont fontsize scalefont def
headerfont setfont
#{x} #{y} moveto
(#{text}) show"
Dir.chdir("#{dir}/tmp-size")
f = File.open(file, 'w')
f.puts ps
f.close
cmd = Thread.new do
%x[convert -background white #{file} motion-size-#{n}.png]
end
cmd.join
end
#!/usr/bin/ruby
file = "motion-size.ps"
x = 80
y = 80
text = "fuck it"
n = 1
# directory setup
fullpath = File.expand_path(__FILE__)
dir = File.dirname(fullpath)
(1..72).each do |n|
ps = "/fontsize #{n} def
/headerfont /Courier findfont fontsize scalefont def
headerfont setfont
#{x} #{y} moveto
(#{text}) show"
Dir.chdir("#{dir}/tmp-size")
f = File.open(file, 'w')
f.puts ps
f.close
cmd = Thread.new do
%x[convert #{file} motion-length-#{n}.png]
end
cmd.join
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment