Source. [a0ed7be20632c0aa]

import Diagrams.Prelude hiding (Empty)
import SplayDia
import Diagrams.TwoD.Layout.Tree

dia = frame 0.1 . hsep 1 . map centerXY $    -- $
  [ drawSplay (nd 'g' (nd 'p' (nd 'x' (sub 'A') (sub 'B')) (sub 'C')) (sub 'D'))
  , arrowV unitX
  , drawSplay (nd 'p' (nd 'x' (sub 'A') (sub 'B')) (nd 'g' (sub 'C') (sub 'D')))
  , arrowV unitX
  , drawSplay (nd 'x' (sub 'A') (nd 'p' (sub 'B') (nd 'g' (sub 'C') (sub 'D'))))
  ]