Copyright | (c) 2015 diagrams-rasterific team (see LICENSE) |
---|---|
License | BSD-style (see LICENSE) |
Maintainer | diagrams-discuss@googlegroups.com |
Safe Haskell | None |
Language | Haskell2010 |
Experimental module to create text with an envelope and trace. The
texterifc functions build diagrams with text size of
and
a s specified slant and weight. The size should be changed only with
the scale functions and changing the slant and/or weight after the
text has benn created can result in an slightly incorrect envelope.local
1
- texterific' :: (TypeableFloat n, Renderable (Text n) b) => FontSlant -> FontWeight -> String -> QDiagram b V2 n Any
- texterific :: (TypeableFloat n, Renderable (Text n) b) => String -> QDiagram b V2 n Any
- fromFontStyle :: FontSlant -> FontWeight -> Font
- textBoundingBox :: RealFloat n => Font -> PointSize -> String -> BoundingBox V2 n
Documentation
texterific' :: (TypeableFloat n, Renderable (Text n) b) => FontSlant -> FontWeight -> String -> QDiagram b V2 n Any Source #
Create a primitive text diagram from the given FontSlant
,
FontWeight
, and string, with baseline alignment, envelope and trace
based on the BoundingBox
of the text.
texterific :: (TypeableFloat n, Renderable (Text n) b) => String -> QDiagram b V2 n Any Source #
Create a primitive text diagram from the given string, with
baseline alignment, envelope and trace based on the BoundingBox
of the text. Designed to be a replacement for the function text
in Diagrams.TwoD.Text.
fromFontStyle :: FontSlant -> FontWeight -> Font Source #
Get an OpenSans font with the given FontSlant
and FontWeight
.
textBoundingBox :: RealFloat n => Font -> PointSize -> String -> BoundingBox V2 n Source #
Get the BoundingBox
for some font with the origin at the start of
the baseline.