module Graphics.Gnuplot.Private.Frame where import qualified Graphics.Gnuplot.Private.Plot as Plot import qualified Graphics.Gnuplot.Private.FrameOptionSet as OptionSet import qualified Graphics.Gnuplot.Private.Display as Display import qualified Graphics.Gnuplot.Private.Graph as Graph import Data.Monoid (mappend, ) data T graph = Cons { T graph -> T graph option :: OptionSet.T graph, T graph -> T graph plot :: Plot.T graph } instance Graph.C graph => Display.C (T graph) where toScript :: T graph -> Script toScript T graph frame = (T graph -> Script forall graph. C graph => T graph -> Script Plot.optionsToScript (T graph -> Script) -> T graph -> Script forall a b. (a -> b) -> a -> b $ T graph -> T graph forall graph. T graph -> T graph option T graph frame) Script -> Script -> Script forall a. Monoid a => a -> a -> a `mappend` (T graph -> Script forall graph. C graph => T graph -> Script Plot.toScript (T graph -> Script) -> T graph -> Script forall a b. (a -> b) -> a -> b $ T graph -> T graph forall graph. T graph -> T graph plot T graph frame)