fgl-visualize-0.1.0.1: Convert FGL graphs to dot (graphviz) files
Safe HaskellSafe-Inferred
LanguageHaskell98

Data.Graph.Inductive.Dot

Description

FGL To Dot is an automatic translation and labeling of FGL graphs (see the Graph class) to graphviz Dot format that can be written out to a file and displayed.

    let dot = showDot (fglToDot graph)
    writeFile "file.dot" dot
    system("dot -Tpng -ofile.png file.dot")
Synopsis

Documentation

fglToDot :: (Show a, Show b, Graph gr) => gr a b -> Dot () Source #

Generate a Dot graph using the show instances of the node and edge labels as displayed graph labels

fglToDotString :: Graph gr => gr String String -> Dot () Source #

Generate a Dot graph using the Node and Edge strings as labels

fglToDotUnlabeled :: Graph gr => gr a b -> Dot () Source #

Generate a Dot graph without any edge or node labels

fglToDotGeneric :: Graph gr => gr a b -> (a -> String) -> (b -> String) -> ([(String, String)] -> [(String, String)]) -> Dot () Source #

Generate a Dot graph using the provided functions to mutate the node labels, edge labels and list of attributes.