Skip to content

Commit b13e3f4

Browse files
committed
Merge pull request #115 from clue/remove-graphviz
Split off GraphViz
2 parents 015849b + b736f01 commit b13e3f4

File tree

8 files changed

+20
-744
lines changed

8 files changed

+20
-744
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,11 @@ The recommended way to install this library is [through composer](http://getcomp
8585
```
8686

8787
Optional recommendation:
88+
8889
In order to be able to use the [graph drawing feature](#graph-drawing) you'll have to
89-
install GraphViz (`dot` executable). Users of Debian/Ubuntu-based distributions may simply
90-
invoke `sudo apt-get install graphviz`, Windows users have to
91-
[download GraphViZ for Windows](http://www.graphviz.org/Download_windows.php) and remaining
92-
users should install from [GraphViz homepage](http://www.graphviz.org/Download.php).
90+
install the [graphp/graphviz](https://github.com/graphp/graphviz) package and GraphViz itself (`dot` executable).
91+
92+
See [graphp/graphviz](https://github.com/graphp/graphviz) for details.
9393

9494
## Tests
9595

composer.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "clue/graph",
33
"type": "library",
44
"description": "A mathematical graph/network library written in PHP",
5-
"keywords": ["graph", "network", "mathematical", "graphviz", "vertex", "edge", "shortest path", "dijkstra", "moore-bellman-ford", "minimum spanning tree", "kruskal", "prim"],
5+
"keywords": ["graph", "network", "mathematical", "vertex", "edge", "shortest path", "dijkstra", "moore-bellman-ford", "minimum spanning tree", "kruskal", "prim"],
66
"homepage": "https://github.com/clue/graph",
77
"license": "MIT",
88
"autoload": {
@@ -13,5 +13,8 @@
1313
},
1414
"require-dev": {
1515
"phpunit/phpunit": "3.7.* | ~4.0"
16+
},
17+
"suggest": {
18+
"graphp/graphviz": "GraphViz graph drawing / DOT output"
1619
}
1720
}

composer.lock

Lines changed: 9 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/Fhaculty/Graph/Exporter/Dot.php

Lines changed: 0 additions & 15 deletions
This file was deleted.

lib/Fhaculty/Graph/Exporter/Image.php

Lines changed: 0 additions & 31 deletions
This file was deleted.

lib/Fhaculty/Graph/Graph.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
namespace Fhaculty\Graph;
44

55
use Fhaculty\Graph\Exporter\ExporterInterface;
6-
use Fhaculty\Graph\Exporter\Dot;
6+
use Fhaculty\Graph\Exporter\TrivialGraphFormat;
77
use Fhaculty\Graph\Exception\BadMethodCallException;
88
use Fhaculty\Graph\Exception\UnexpectedValueException;
99
use Fhaculty\Graph\Exception\InvalidArgumentException;
@@ -476,14 +476,14 @@ public function setExporter(ExporterInterface $exporter)
476476
* get current exporter to use to export graph to its output format
477477
*
478478
* If no other exporter has been set previously, this will lazy-load
479-
* the (current default) Dot exporter.
479+
* the (current default) TrivialGraphFormat exporter.
480480
*
481481
* @return ExporterInterface
482482
*/
483483
public function getExporter()
484484
{
485485
if ($this->exporter === null) {
486-
$this->exporter = new Dot();
486+
$this->exporter = new TrivialGraphFormat();
487487
}
488488
return $this->exporter;
489489
}

0 commit comments

Comments
 (0)