Graph-Easy
==========

See Graph::Easy under LIMITATIONS for some hot topics.

In addition:

Important short-term TODO:

* It would be good if we could remove Node::Empty (it blocks an empty field
  just to draw the right/bottom border pieces)
  (we might put these "invisible" nodes into a different "cells" field,
   which will be rendered, but not queryied for path finding etc)
* missing edges sometimes do not result in an error message
* unplacing edge-crossings does not work properly, leaving stray crossings
* implement HTML nodes as triangles, house, etc. using slanted edges
* define missing HTML edge cells (selfloops, corners and CROSS w. end/start
  points)
* as_html(): output of node-clusters is slightly wrong
* as_html(): there is no space between two nodes placed next (with filler
	     cell) to each other. Make filler cells output a &nbsp;
* put framebuffer related routines into own package (Graph::Easy::As_ascii)
  to avoid the dilemma that we need them from both Node and Graph.
  Likewise, some routines used by objects (e.g. graph, node etc) should
  be in a super-package and inherited)
* as_html(): put edges into the proper group and set their cell_class so that
	     they inherit the background from the group
* as_txt: output of autosplit nodes is broken when no label gets set
  "[A|B]" results in "[ A|B ] { label: A; }"
* use "shape: record" and label="{ { 00 | 01 | 02 } | { 10 | 112 | 12 } }" to
  implement auto-split nodes in graphviz

Parser:

* edge parsing " -- test \>-->" => "test >" as edge label
* deal with " -> [ node ], [node2], [node3]"
* parse nested graphs
* support for node splitting ala:

    "[ A ] | [ B | C ] || [ D | E ]"

* support for attribute lists on autosplit nodes ala:

    "[ A || B | C ] { background: red|blue|green; }"

* use "{}" to nest blocks?
* Nodes with both "|" and "\|" in their name are not parsed correctly
* handle RGB colors with percentages or fractions like: rgb(100%,50%,0.5)
* quoting of "[" and "{" inside edge labels ala:

  [ A ] -- label \[ 8 ] --> [ B ]

Output:

* selfloop edges should counter the general flow:

                    Until not done
                  +----------------+
                  v                |
  +-------+     +--------------------+     +-----+
  | Start | --> | Main               | --> | End |
  +-------+     +--------------------+     +-----+

  versus (loop still going left):

                  Until not done
                +----------------+
                v                |
  +-----+     +--------------------+     +-------+
  | End | <-- | Main               | <-- | Start |
  +-----+     +--------------------+     +-------+

* support different edge starting point styles ala:

  ----->  |----->  o----->  +----->  *----->  >>---->

* support egde "style: invisible"
* as_txt(): output of node clusters is not optimal
* as_txt(): output of node chains is not optimal
* as_ascii(): output group borders and group labels
* better support for different shapes (circle, box, rounded, polygon etc)
  in ASCII
* as_graphviz(): support "border-style: double" together with fill colors
* need better support for different edge styles in Graphviz
* as_ascii() and others: grow cells around point-shaped nodes to intrude:

	...........................
        :      :  |   :     :     :
	:      :  |   :     :     :
	:      :  v   :     :     :
	...........................
        :       :   :       :     :
	:-----> : * : <---- :     :
        :       :   :       :     :
	...........................

* as_boxart has some incorrect corner pieces:
   echo "[A|B|C||D]" | perl examples/as_boxart
   ┌───┬───┬───┐
   │ A │ B │ C │
   └───┼───┴───┘
   │ D │
   └───┘
   echo "[A| |C||D| |E]" |perl examples/as_boxart
   ┌───┬  │───┐
   │ A │  │ C │
   └───┼   ───┤
   │   │  │   │
   │ D │  │ E │
   └───┘   ───┘

Layout:

* the longest-chain code (walk recursively children of startig node) needs
  some tuning, especially when it encounters loops in the graph.
* allow user to specify max graph width (in cells) to avoid overly wide graphs
* auto-grow nodes to be multicelled depending on the dimensions of their label
  ("main page" gets 2x1, while "a \nb \nc \nd \ne \n" gets 1x2 cells)
  This currently causes problems and wierd layouts.
* Use the seed to generate randomized layouts
* allow user to specify on an edge:
    direction: (up|down|left|right|north|south|west|east|0|90|180|270|360);
    flow: (up|down|left|right|north|south|west|east|0|90|180|270|360);
  to force or suggest direction of edges leaving a node
* the A* algorithm needs fine-tuning to generate less bendy paths

Rendering/Layout:

* allow user to specifiy "align: left, top;" or "align: center, middle" to
  specify alignment of labels. (left|right|center|middle|top|bottom)
* add margin/padding attributes (especially usefull for HTML output)
* add a orientation attribute, to rotate node shapes (left-pointing triangle etc)

Optimizer:

* write an optimizer for already laid out graphs to optimize layout
* less memory: store border and edge styles as ints instead of "solid" etc
* use AUTOLOAD for accessors in Node.pm: most are never used by normal code
* edges_to() is the new hot-spot. It could be faster if we keep track of
  edges per node indexed by their target, too.

Manual:

* finish the POD to HTML conversion (Graph::Easy::Pod2HTML)

