Skip to content

Instantly share code, notes, and snippets.

View davelab6's full-sized avatar
🤓
Obsessed with variable fonts

Dave Crossland davelab6

🤓
Obsessed with variable fonts
View GitHub Profile
Script started on Wed Aug 28 12:12:44 2013
(lldb) error: Aborting reading of commands after command #5: 'run' continued the target.
Executing commands in '/Applications/FontForge.app/Contents/MacOS/debug-script'.
(lldb) version
LLDB-179.5
(lldb) settings set frame-format "frame #${frame.index}: ${frame.pc}{ ${module.file.basename}`${function.name-with-args}{${function.pc-offset}}}{ at ${line.file.basename}:${line.number}}\n"
(lldb) target create /Applications/FontForge.app/Contents/Resources/opt/local/bin/fontforge
Current executable set to '/Applications/FontForge.app/Contents/Resources/opt/local/bin/fontforge' (x86_64).
(lldb) target select 0
Current targets:
@davelab6
davelab6 / fontforge.rb
Last active December 21, 2015 23:09
This formula is now upstream.
Merged inline:
https://github.com/mxcl/homebrew/commit/f5d735f591d5a53a9f63745c4edb868192d5a163
https://github.com/mxcl/homebrew/commit/d07838f37a185ffc7e5f9af31decb191d0ad7636
Moved to https://gist.github.com/davelab6/6380365

Star Wars opening crawl from 1977

I freaking love Star Wars, but could not find a web version of the original opening crawl from 1977. So I created this one.

I wrote an article where I explain how this works. Watch the Start Wars opening crawl on YouTube.

Stuff I used:

  • CSS (animation, transform)
  • HTML audio (the opening theme)
SplineFontDB: 3.0
FontName: Untitled1
FullName: Untitled1
FamilyName: Untitled1
Weight: Medium
Copyright: Created by Ben Martin with FontForge 2.0 (http://fontforge.sf.net)
UComments: "2013-3-19: Created."
Version: 001.000
ItalicAngle: 0
UnderlinePosition: -100
#!/usr/bin/python
# -*- coding: utf-8 -*-
from fontTools import ttLib
def writeFont(font, filename):
font.save(filename)
print "Wrote font to", filename
#!/usr/bin/ruby
=begin
Usage: rtftomarkdown.rb FILENAME.rtf
Uses textutil, available on Mac only (installed by default)
Outputs to STDOUT
Notes:
Links are replaced with Markdown references (duplicate links combined).
@davelab6
davelab6 / noto-deva-example.html
Created April 25, 2014 09:21
Colorful example of Noto Sans Devanagari
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Example</title>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/FitText.js/1.1/jquery.fittext.min.js"></script>
<style>
/*
SplineFontDB: 3.0
FontName: unifont mono
FullName: GNU Unifont mono
FamilyName: GNU Unifont mono
Weight: Medium
UComments: "Line 1
Line 2"
Version: 1.0-1.84
ItalicAngle: 0
UnderlinePosition: -100
from __future__ import division
from mutatorMath.objects.location import Location
from mutatorMath.objects.mutator import buildMutator
"""
Simple demo that can be run in Drawbot
http://www.drawbot.com