Karya, built on 2023-08-29T07:47:28 (patch 7a412d5d6ba4968ca4155ef276a062ccdeb9109a)
Safe HaskellSafe-Inferred

Util.Diffs

Description

Functions to produce text diffs.

Synopsis

Documentation

newtype ColorCode Source #

Constructors

ColorCode Text 

Instances

Instances details
Show ColorCode Source # 
Instance details

Defined in Util.Diffs

colored1 :: Text -> Text -> Text Source #

Only show the "from" side of the diff, if it's just deletion then that will be enough.

highlightLines :: ColorCode -> IntMap [CharRange] -> [Text] -> [Text] Source #

Apply color ranges as produced by ranges.

data Numbered a Source #

Constructors

Numbered 

Fields

Instances

Instances details
Show a => Show (Numbered a) Source # 
Instance details

Defined in Util.Diffs

Methods

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

show :: Numbered a -> String #

showList :: [Numbered a] -> ShowS #

numberedDiff :: (a -> a -> Bool) -> [a] -> [a] -> [Diff.Diff (Numbered a)] Source #