-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | A Perl printf like formatter. -- -- A Perl printf like formatter. @package printf-mauke @version 0.3 module Text.Printf.Mauke -- | Format a variable number of arguments according to a format string, -- similar to (s)printf in Perl. The return value is either a -- String or IO (), in which case the result is -- printed to stdout. -- -- The format string consists of ordinary characters (everything except -- '%'), which are passed through unchanged, and formatting -- directives, which have the following form: -- --
--   % flag* vector? width? precision? type
--   
-- -- (* and ? mean 0 or more and 0 or 1 of the preceding -- item, respectively.) -- -- Flags: -- -- -- -- The vector flag v tells printf to format each -- character in the string argument according to the current directive, -- then joins the results with a separator that defaults to ".". -- When *v is used, the separator is taken from the argument -- list (use e.g. printf "%*v.2x" "" str if you want no -- separator). -- -- The width is either a decimal integer or *, in which -- case the width is taken from the argument list (this argument must be -- an integer). It specifies the minimum width for this field. Shorter -- values are padded on the left with spaces (but this can be changed by -- the 0 and - flags). If the width taken from -- the argument list is negative, it behaves as if the - flag -- was specified. -- -- The precision consists of a . followed by digits or a -- * (see the description of width above). The effects -- depend on the format type: -- -- -- -- Types: -- -- printf :: (PrintfType r) => String -> r -- | Like printf, except that the result is printed to the specified -- Handle. hPrintf :: (HPrintfType r) => Handle -> String -> r class FromChar a fromChar :: (FromChar a) => Char -> a class ToChar a toChar :: (ToChar a) => a -> Char class PrintfType a class HPrintfType a class PrintfArg a instance Eq Type instance Ord Type instance Show Type instance Read Type instance Eq Flag instance Ord Flag instance Show Flag instance Read Flag instance Eq Spec instance Ord Spec instance Show Spec instance Read Spec instance Eq Arg instance Ord Arg instance Show Arg instance Read Arg instance Default Type instance Default Spec instance PrintfArg Fd instance PrintfArg CRLim instance PrintfArg CTcflag instance PrintfArg CUid instance PrintfArg CNlink instance PrintfArg CGid instance PrintfArg CSsize instance PrintfArg CPid instance PrintfArg COff instance PrintfArg CMode instance PrintfArg CIno instance PrintfArg CUIntMax instance PrintfArg CIntMax instance PrintfArg CUIntPtr instance PrintfArg CIntPtr instance PrintfArg CULLong instance PrintfArg CLLong instance PrintfArg CSigAtomic instance PrintfArg CWchar instance PrintfArg CSize instance PrintfArg CPtrdiff instance PrintfArg CULong instance PrintfArg CLong instance PrintfArg CUInt instance PrintfArg CInt instance PrintfArg CUShort instance PrintfArg CShort instance PrintfArg CUChar instance PrintfArg CSChar instance PrintfArg CChar instance PrintfArg WordPtr instance PrintfArg IntPtr instance PrintfArg Word64 instance PrintfArg Word32 instance PrintfArg Word16 instance PrintfArg Word8 instance PrintfArg Word instance PrintfArg Int64 instance PrintfArg Int32 instance PrintfArg Int16 instance PrintfArg Int8 instance PrintfArg Int instance PrintfArg Integer instance (Integral a) => PrintfArg (Ratio a) instance PrintfArg CLDouble instance PrintfArg CDouble instance PrintfArg CFloat instance PrintfArg Float instance PrintfArg Double instance (ToChar a) => PrintfArg [a] instance PrintfArg Char instance (Default a) => HPrintfType (IO a) instance (PrintfArg a, HPrintfType r) => HPrintfType (a -> r) instance (Default a) => PrintfType (IO a) instance (PrintfArg a, PrintfType r) => PrintfType (a -> r) instance (FromChar a) => PrintfType [a] instance ToChar Char instance FromChar Char