!x1k      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~Safe None24567(qrainbow*Text formatting such as bold, italic, etc. rainbow@A simple enumeration for eight values. Represents eight colors.rainbow A color; a J value means that the terminal's default color is used. The type of the  generally will be an  $ to represent one of 8 colors, or a ! to represent one of 256 colors.&rainbow#Takes the last non-Nothing Color.  is no color.9rainbow-The foreground and background color, and the a. This represents all colors and formatting attributes for either an 8- or 256-color terminal.FrainbowKFor each field, the resulting field is True if either field is True. For , every field is False.Orainbow Holds the 9% for both 8- and 256-color terminals.VrainbowUses the underlying  instances for  and .\rainbowA chunk is some textual data coupled with a description of what color the text is, attributes like whether it is bold or underlined, etc. The chunk knows what foreground and background colors and what attributes to use for both an 8 color terminal and a 256 color terminal.brainbow Creates a \0 with no formatting and with the given text. A \ is also an instance of " so you can create them with the OverloadedStrings extension. Such a \. has the text of the string and no formatting.erainbowUses the underlying  instances for the O and for the underlying  . Therefore 2 will have no formatting, no colors, and no text.frainbow Creates a \, with no formatting and with the given text.grainbowUses the underlying $ instances for both the underlying O and the underlying .lrainbowXStores colors that may affect 8-color terminals, 256-color terminals, both, or neither.rrainbowUses the underlying  instance for the s. Thus the last non- y is used. This can be useful to specify one color for 8-color terminals and a different color for 256-color terminals.I    !"#$%9:=<;>?@ABCDEOPRQSTU\]_^`ablmonpqxyI   !"#$% EDCBA@?>9:=<;UTSOPRQa`\]_^bqplmonyxNone=?T rainbowUses q to obtain the terminal's color capability. If this says there are at least 256 colors are available, returns A. Otherwise, if there are at least 8 colors available, returns . Otherwise, returns .9If the terminfo database could not be read (that is, if  is returned), then return .rainbowLike  but also consults a provided  . If the  is not a terminal, ( is returned. Otherwise, the value of  is returned.rainbowConvert a list of \ to a list of U. The length of the returned list may be longer than the length of the input list.QSo, for example, to print a bunch of chunks to standard output using 256 colors: kmodule PrintMyChunks where import qualified Data.ByteString as BS import Rainbow myChunks :: [Chunk String] myChunks = [ chunk "Roses" & fore red, chunk "\n", chunk "Violets" & fore blue, chunk "\n" ] myPrintedChunks :: IO () myPrintedChunks = mapM_ BS.putStr . chunksToByteStrings toByteStringsColors256 $ myChunks@To use the highest number of colors that this terminal supports: myPrintedChunks' :: IO () myPrintedChunks' = do printer <- byteStringMakerFromEnvironment mapM_ BS.putStr . chunksToByteStrings printer $ myChunksrainbow%Writes a list of chunks to the given . First uses ? to determine how many colors to use. Then creates a list of  using # and then writes them to the given .rainbow%Writes a list of chunks to the given #, followed by a newline character. First uses ? to determine how many colors to use. Then creates a list of  using # and then writes them to the given .rainbow+Writes a list of chunks to standard output. First uses ? to determine how many colors to use. Then creates a list of  using ) and then writes them to standard output.rainbowCWrites a list of chunks to standard output, followed by a newline. First uses ? to determine how many colors to use. Then creates a list of  using ) and then writes them to standard output.rainbow Writes a \ to standard output. Uses S each time you apply it, so this might be inefficient. You are better off using  and the functions in Data.ByteString to print your \$s if you are printing a lot of them.rainbow Writes a \2 to standard output, and appends a newline. Uses S each time you apply it, so this might be inefficient. You are better off using  and the functions in Data.ByteString to print your \$s if you are printing a lot of them.rainbowFunction that converts \ to %. This function, when applied to a \, returns a difference list.6z{|}~6z{|}~None 24567SXjrainbowBold. What actually happens when you use Bold is going to depend on your terminal. For example, xterm allows you actually use a bold font for bold, if you have one. Otherwise, it might simulate bold by using overstriking. Another possibility is that your terminal might use a different color to indicate bold. For more details (at least for xterm), look at xterm (1) and search for  boldColors.lIf your terminal uses a different color for bold, this allows an 8-color terminal to really have 16 colors.rainbowsChange the foreground color. Whether this affects 8-color terminals, 256-color terminals, or both depends on the l.rainbowsChange the background color. Whether this affects 8-color terminals, 256-color terminals, or both depends on the l.rainbowEnsures that a l affects only a 256-color terminal. For instance, to make text that is blue on an 8-color terminal but red on a 256-color terminal:  $ "Blue on 8, red on 256" &  ( <>  ) rainbowA l for any of the 256 colors available. Supply the color number. Exactly which color you'll get for a given number is dependent on the terminal; though there seem to be common defaults, often the user can configure this however she likes. The resulting l& will affect 256-color terminals only.+\bl+\bl      !"#$%&'()*+,-./0123456789:;<=>>?@ABCDEFGHIJKLMNOPQRSSTUVWXYZ[\]^__`abcdefghijklmnnopqrstuvwxyz{|}~CDGIBEFHCDGIBEFHWV !"#$%&'()*y'rainbow-0.34.2.2-1ah5PZE6w84FK2I3qiFqVN Rainbow.TypesRainbow.TranslateRainbow Paths_rainbowSystem.Console.Terminfo.BaseSetupTermErrorFormat_bold_faint_italic _underline_blink_inverse _invisible _strikeoutEnum8E0E1E2E3E4E5E6E7Color enum8toWord8blackredgreenyellowbluemagentacyanwhitegrey brightRed brightGreen brightYellow brightBlue brightMagenta brightCyan brightWhite $fMonoidColor$fSemigroupColor $fEqColor $fShowColor $fOrdColor$fGenericColor$fFunctorColor$fFoldableColor$fTraversableColor $fEqEnum8 $fOrdEnum8 $fShowEnum8$fBoundedEnum8 $fEnumEnum8$fGenericEnum8 $fShowFormat $fEqFormat $fOrdFormat$fGenericFormatStyle_fore_back_formatblinkboldfaintinverse invisibleitalic strikeout underline$fMonoidFormat$fSemigroupFormat $fShowStyle $fEqStyle $fOrdStyle$fGenericStyle$fFunctorStyle$fFoldableStyle$fTraversableStyleScheme_style8 _style256backforeformat $fMonoidStyle$fSemigroupStyle $fEqScheme $fOrdScheme $fShowScheme$fGenericSchemeChunk_scheme_yarnstyle256style8chunk$fMonoidScheme$fSemigroupScheme $fMonoidChunk$fIsStringChunk$fSemigroupChunk $fEqChunk $fShowChunk $fOrdChunk$fGenericChunkRadiant_color8 _color256schemeyarn$fMonoidRadiant$fSemigroupRadiant $fEqRadiant $fOrdRadiant $fShowRadiant$fGenericRadiantcolor256color8singleescapecsisgrparams sgrSingle sgrDouble normalDefault foreBlackforeRed foreGreen foreYellowforeBlue foreMagentaforeCyan foreWhite foreDefault backBlackbackRed backGreen backYellowbackBlue backMagentabackCyan backWhite backDefaultfore256back256 foreColor8 backColor8 renderFormat renderStyle8renderStyle256rendertoByteStringsColors0toByteStringsColors8toByteStringsColors256byteStringMakerFromEnvironmentbyteStringMakerFromHandlechunksToByteStrings hPutChunks hPutChunksLn putChunks putChunksLnputChunk putChunkLnonly256version getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileNamebase GHC.MaybeNothingMaybeGHC.WordWord8GHC.BasememptyMonoid Data.StringIsString text-1.2.3.1Data.Text.InternalText Semigroupterminfo-0.4.1.2setupTermFromEnvGHC.IO.Handle.TypesHandlebytestring-0.10.8.2Data.ByteString.Internal ByteString