#4377: sizedText function for Text.PrettyPrint
---------------------------------+------------------------------------------
Reporter: lerkok | Owner:
Type: proposal | Status: new
Priority: normal | Component: libraries/pretty
Version: | Keywords: text, sizedText, pretty
printing, Text.PrettyPrint
Testcase: | Blockedby:
Os: Unknown/Multiple | Blocking:
Architecture: Unknown/Multiple | Failure: None/Unknown
---------------------------------+------------------------------------------
Comment(by lerkok):
Thanks for the responses..
Looks like an appropriate definition would be:
{{{
sizedText :: Int -> String -> Doc
sizedText l s = textBeside_ (Str s) l Empty
}}}
Based on Thomas's suggestion to use `textBeside_` and Christians
suggestion that any padding should be done on the user side if necessary.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4377#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs