Hoogle Search

Within LTS Haskell 24.19 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. showAmountWithZeroCommodity :: Amount -> String

    hledger-lib Hledger.Data.Amount

    Like showAmount, but show a zero amount's commodity if it has one.

    showAmountWithZeroCommodity = wbUnpack . showAmountB defaultFmt{displayZeryCommodity=True}
    

  2. showAmountWithoutCost :: Amount -> String

    hledger-lib Hledger.Data.Amount

    Get the string representation of an amount, without any @ cost.

    showAmountWithoutCost = wbUnpack . showAmountB noCostFmt
    

  3. showCommoditySymbol :: Text -> Text

    hledger-lib Hledger.Data.Amount

    Show space-containing commodity symbols quoted, as they are in a journal.

  4. showMixedAmount :: MixedAmount -> String

    hledger-lib Hledger.Data.Amount

    Render a mixed amount using its amount display styles and the default amount format, after normalising it (to at most one amount in each of its commodities). See showMixedAmountB for special cases.

  5. showMixedAmountB :: AmountFormat -> MixedAmount -> WideBuilder

    hledger-lib Hledger.Data.Amount

    Render a mixed amount using its amount display styles and the given amount format, as a builder for efficiency. (This can be converted to a Text with wbToText or to a String with wbUnpack). Warning: this (and its showMixedAmount aliases above) basically assumes amounts have no costs. It can show misleading costs or not show costs which are there. If a maximum width is given then:

    • If displayed on one line, it will display as many Amounts as can fit in the given width, and further Amounts will be elided. There will always be at least one amount displayed, even if this will exceed the requested maximum width.
    • If displayed on multiple lines, any Amounts longer than the maximum width will be elided.
    Zero-equivalent amounts are shown as just "0". The special "missing" amount is shown as the empty string (?).

  6. showMixedAmountDebug :: MixedAmount -> String

    hledger-lib Hledger.Data.Amount

    Get an unambiguous string representation of a mixed amount for debugging.

  7. showMixedAmountElided :: Int -> Bool -> MixedAmount -> String

    hledger-lib Hledger.Data.Amount

    Like showMixedAmountOneLineWithoutCost, but show at most the given width, with an elision indicator if there are more. With a True argument, adds ANSI codes to show negative amounts in red. See showMixedAmountB for special cases.

  8. showMixedAmountLinesB :: AmountFormat -> MixedAmount -> [WideBuilder]

    hledger-lib Hledger.Data.Amount

    Helper for showMixedAmountB (and postingAsLines, ...) to show a list of Amounts on multiple lines. This returns the list of WideBuilders: one for each Amount, and padded/elided to the appropriate width. This does not honour displayOneLine; all amounts will be displayed as if displayOneLine were False.

  9. showMixedAmountLinesPartsB :: AmountFormat -> MixedAmount -> [(WideBuilder, Amount)]

    hledger-lib Hledger.Data.Amount

    Like showMixedAmountLinesB but also returns the amounts associated with each text builder.

  10. showMixedAmountOneLine :: MixedAmount -> String

    hledger-lib Hledger.Data.Amount

    Get the one-line string representation of a mixed amount (also showing any costs). See showMixedAmountB for special cases.

Page 69 of many | Previous | Next