@@ -142,33 +142,7 @@ data Image =
142142 --
143143 -- Any image of zero size equals the empty image.
144144 | EmptyImage
145− deriving (Eq, Generic)
146−
147−instance Show Image where
148− show ( HorizText { attr, displayText, outputWidth, charWidth } )
149− = "HorizText " ++ show displayText
150− ++ "@(" ++ show attr ++ ","
151− ++ show outputWidth ++ ","
152− ++ show charWidth ++ ")"
153− show ( BGFill { outputWidth, outputHeight } )
154− = "BGFill (" ++ show outputWidth ++ "," ++ show outputHeight ++ ")"
155− show ( HorizJoin { partLeft = l, partRight = r, outputWidth = c } )
156− = "HorizJoin " ++ show c ++ " (" ++ show l ++ " <|> " ++ show r ++ ")"
157− show ( VertJoin { partTop = t, partBottom = b, outputWidth = c, outputHeight = r } )
158− = "VertJoin [" ++ show c ++ ", " ++ show r ++ "] (" ++ show t ++ ") <-> (" ++ show b ++ ")"
159− show ( CropRight { croppedImage, outputWidth, outputHeight } )
160− = "CropRight [" ++ show outputWidth ++ "," ++ show outputHeight ++ "]"
161− ++ " (" ++ show croppedImage ++ ")"
162− show ( CropLeft { croppedImage, leftSkip, outputWidth, outputHeight } )
163− = "CropLeft [" ++ show leftSkip ++ "," ++ show outputWidth ++ "," ++ show outputHeight ++ "]"
164− ++ " (" ++ show croppedImage ++ ")"
165− show ( CropBottom { croppedImage, outputWidth, outputHeight } )
166− = "CropBottom [" ++ show outputWidth ++ "," ++ show outputHeight ++ "]"
167− ++ " (" ++ show croppedImage ++ ")"
168− show ( CropTop { croppedImage, topSkip, outputWidth, outputHeight } )
169− = "CropTop [" ++ show topSkip ++ "," ++ show outputWidth ++ "," ++ show outputHeight ++ "]"
170− ++ " (" ++ show croppedImage ++ ")"
171− show ( EmptyImage ) = "EmptyImage"
145+ deriving (Eq, Generic, Show, Read)
172146
173147-- | pretty print just the structure of an image.
174148ppImageStructure :: Image -> String