Permalink
Browse files

fix expression to work with new fixity of .+^ (fixes #27)

See conal/vector-space@f5ef4fd .  Note that
we could make use of the new left-associativity to omit some
parentheses here, which looks nice, but then we would have to jack up
the lower bound on vector-space (which, for consistency, we'd want to
do also on a bunch of other diagrams packages).  For now, the current
code should still compile with older versions of vector-space.
  • Loading branch information...
1 parent f89a434 commit 15929297a4882e4f8b2328be6a6859828c592e1f Brent Yorgey committed Dec 10, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/Diagrams/Backend/Cairo/Text.hs
@@ -147,7 +147,7 @@ textVisualBoundedIO :: Style R2 -> String -> IO (Diagram Cairo R2)
textVisualBoundedIO style str = do
te <- queryCairo $ getTextExtents style str
let box = fromCorners (origin .+^ bearing te)
- (origin .+^ bearing te ^+^ (textSize te))
+ ((origin .+^ bearing te) .+^ textSize te)
return . setEnvelope (getEnvelope box) . applyStyle style $ baselineText str
kerningCorrection :: Style R2 -> Char -> Char -> Double

0 comments on commit 1592929

Please sign in to comment.