Correctly count the graph width. Closes #18
Merge branch 'ribbon'