formatting-7.0.0: Combinator-based type-safe formatting (like printf() or FORMAT)

Safe HaskellNone
LanguageHaskell2010

Formatting.Internal.Raw

Contents

Description

Reexports of things that were previously in the text-format package.

Synopsis

Format control

left :: Buildable a => Int -> Char -> a -> Builder Source #

Pad the left hand side of a string until it reaches k characters wide, if necessary filling with character c.

right :: Buildable a => Int -> Char -> a -> Builder Source #

Pad the right hand side of a string until it reaches k characters wide, if necessary filling with character c.

Integers

hex :: Integral a => a -> Builder Source #

Render an integer using hexadecimal notation. (No leading "0x" is added.)

Floating point numbers

fixed Source #

Arguments

:: Real a 
=> Int

Number of digits of precision after the decimal.

-> a 
-> Builder 

Render a floating point number using normal notation, with the given number of decimal places.

shortest :: Real a => a -> Builder Source #

Render a floating point number using the smallest number of digits that correctly represent it.

(<>) :: Builder -> Builder -> Builder infixr 4 Source #

The normal mappend function with right associativity instead of left.

i2d :: Int -> Char Source #

Unsafe conversion for decimal digits.

decimal :: forall a. (Integral a, Bounded a) => a -> Builder Source #

newtype Shown a Source #

Render a value using its Show instance.

Constructors

Shown 

Fields

Instances
Bounded a => Bounded (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

minBound :: Shown a #

maxBound :: Shown a #

Enum a => Enum (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

succ :: Shown a -> Shown a #

pred :: Shown a -> Shown a #

toEnum :: Int -> Shown a #

fromEnum :: Shown a -> Int #

enumFrom :: Shown a -> [Shown a] #

enumFromThen :: Shown a -> Shown a -> [Shown a] #

enumFromTo :: Shown a -> Shown a -> [Shown a] #

enumFromThenTo :: Shown a -> Shown a -> Shown a -> [Shown a] #

Eq a => Eq (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

(==) :: Shown a -> Shown a -> Bool #

(/=) :: Shown a -> Shown a -> Bool #

Floating a => Floating (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

pi :: Shown a #

exp :: Shown a -> Shown a #

log :: Shown a -> Shown a #

sqrt :: Shown a -> Shown a #

(**) :: Shown a -> Shown a -> Shown a #

logBase :: Shown a -> Shown a -> Shown a #

sin :: Shown a -> Shown a #

cos :: Shown a -> Shown a #

tan :: Shown a -> Shown a #

asin :: Shown a -> Shown a #

acos :: Shown a -> Shown a #

atan :: Shown a -> Shown a #

sinh :: Shown a -> Shown a #

cosh :: Shown a -> Shown a #

tanh :: Shown a -> Shown a #

asinh :: Shown a -> Shown a #

acosh :: Shown a -> Shown a #

atanh :: Shown a -> Shown a #

log1p :: Shown a -> Shown a #

expm1 :: Shown a -> Shown a #

log1pexp :: Shown a -> Shown a #

log1mexp :: Shown a -> Shown a #

Fractional a => Fractional (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

(/) :: Shown a -> Shown a -> Shown a #

recip :: Shown a -> Shown a #

fromRational :: Rational -> Shown a #

Integral a => Integral (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

quot :: Shown a -> Shown a -> Shown a #

rem :: Shown a -> Shown a -> Shown a #

div :: Shown a -> Shown a -> Shown a #

mod :: Shown a -> Shown a -> Shown a #

quotRem :: Shown a -> Shown a -> (Shown a, Shown a) #

divMod :: Shown a -> Shown a -> (Shown a, Shown a) #

toInteger :: Shown a -> Integer #

Num a => Num (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

(+) :: Shown a -> Shown a -> Shown a #

(-) :: Shown a -> Shown a -> Shown a #

(*) :: Shown a -> Shown a -> Shown a #

negate :: Shown a -> Shown a #

abs :: Shown a -> Shown a #

signum :: Shown a -> Shown a #

fromInteger :: Integer -> Shown a #

Ord a => Ord (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

compare :: Shown a -> Shown a -> Ordering #

(<) :: Shown a -> Shown a -> Bool #

(<=) :: Shown a -> Shown a -> Bool #

(>) :: Shown a -> Shown a -> Bool #

(>=) :: Shown a -> Shown a -> Bool #

max :: Shown a -> Shown a -> Shown a #

min :: Shown a -> Shown a -> Shown a #

Read a => Read (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Real a => Real (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

toRational :: Shown a -> Rational #

RealFloat a => RealFloat (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

RealFrac a => RealFrac (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

properFraction :: Integral b => Shown a -> (b, Shown a) #

truncate :: Integral b => Shown a -> b #

round :: Integral b => Shown a -> b #

ceiling :: Integral b => Shown a -> b #

floor :: Integral b => Shown a -> b #

Show a => Show (Shown a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

showsPrec :: Int -> Shown a -> ShowS #

show :: Shown a -> String #

showList :: [Shown a] -> ShowS #

Show a => Buildable (Shown a) Source # 
Instance details

Defined in Formatting.Buildable

Methods

build :: Shown a -> Builder Source #

Integer format control

newtype Hex a Source #

Render an integral type in hexadecimal.

Constructors

Hex a 
Instances
Enum a => Enum (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

succ :: Hex a -> Hex a #

pred :: Hex a -> Hex a #

toEnum :: Int -> Hex a #

fromEnum :: Hex a -> Int #

enumFrom :: Hex a -> [Hex a] #

enumFromThen :: Hex a -> Hex a -> [Hex a] #

enumFromTo :: Hex a -> Hex a -> [Hex a] #

enumFromThenTo :: Hex a -> Hex a -> Hex a -> [Hex a] #

Eq a => Eq (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

(==) :: Hex a -> Hex a -> Bool #

(/=) :: Hex a -> Hex a -> Bool #

Integral a => Integral (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

quot :: Hex a -> Hex a -> Hex a #

rem :: Hex a -> Hex a -> Hex a #

div :: Hex a -> Hex a -> Hex a #

mod :: Hex a -> Hex a -> Hex a #

quotRem :: Hex a -> Hex a -> (Hex a, Hex a) #

divMod :: Hex a -> Hex a -> (Hex a, Hex a) #

toInteger :: Hex a -> Integer #

Num a => Num (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

(+) :: Hex a -> Hex a -> Hex a #

(-) :: Hex a -> Hex a -> Hex a #

(*) :: Hex a -> Hex a -> Hex a #

negate :: Hex a -> Hex a #

abs :: Hex a -> Hex a #

signum :: Hex a -> Hex a #

fromInteger :: Integer -> Hex a #

Ord a => Ord (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

compare :: Hex a -> Hex a -> Ordering #

(<) :: Hex a -> Hex a -> Bool #

(<=) :: Hex a -> Hex a -> Bool #

(>) :: Hex a -> Hex a -> Bool #

(>=) :: Hex a -> Hex a -> Bool #

max :: Hex a -> Hex a -> Hex a #

min :: Hex a -> Hex a -> Hex a #

Read a => Read (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Real a => Real (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

toRational :: Hex a -> Rational #

Show a => Show (Hex a) Source # 
Instance details

Defined in Data.Text.Format.Types

Methods

showsPrec :: Int -> Hex a -> ShowS #

show :: Hex a -> String #

showList :: [Hex a] -> ShowS #

Integral a => Buildable (Hex a) Source # 
Instance details

Defined in Formatting.Buildable

Methods

build :: Hex a -> Builder Source #