replace specific references to Cairo type by B

This will allow the examples to build under, say, the SVG backend as
well, while retaining the ability to give (simple!) explicit type
signatures to diagrams.