diff options
| author | Sylvain Chiron <chironsylvain@orange.fr> | 2017-07-01 11:36:41 +0000 |
|---|---|---|
| committer | Sylvain Chiron <chironsylvain@orange.fr> | 2017-07-01 11:36:41 +0000 |
| commit | fd733201b82f39655488a286c89142f321ef9dc9 (patch) | |
| tree | a12c70f213414f69467f666619b1552103f6370e /src/libavoid/tests/infinity.cpp | |
| parent | Hackfest icon work: restore selected menu icons and make theming easier (diff) | |
| download | inkscape-fd733201b82f39655488a286c89142f321ef9dc9.tar.gz inkscape-fd733201b82f39655488a286c89142f321ef9dc9.zip | |
Updated libs from the Adaptagrams project: libavoid, libcola and libvspc; changed the code to match the new API
Signed-off-by: Sylvain Chiron <chironsylvain@orange.fr>
Diffstat (limited to 'src/libavoid/tests/infinity.cpp')
| -rw-r--r-- | src/libavoid/tests/infinity.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/libavoid/tests/infinity.cpp b/src/libavoid/tests/infinity.cpp new file mode 100644 index 000000000..1fbf683a3 --- /dev/null +++ b/src/libavoid/tests/infinity.cpp @@ -0,0 +1,26 @@ +#include "libavoid/libavoid.h" +using namespace Avoid; +int main(void) { + Router *router = new Router(OrthogonalRouting); + router->setRoutingPenalty(segmentPenalty, 50); + router->setRoutingParameter(idealNudgingDistance, 10); + Rectangle rect47(Point(51145, 50195), Point(51145+360, 50195+685)); + new ShapeRef(router, rect47); + Rectangle rect46(Point(51920, 49770), Point(51920+360, 49770+310)); + new ShapeRef(router, rect46); + Rectangle rect45(Point(51151, 49770), Point(51151+360, 49770+310)); + new ShapeRef(router, rect45); + ConnEnd srcPt53(Point(51150,49850), 4); + ConnEnd dstPt53(Point(51500,50350), 8); + new ConnRef(router, srcPt53, dstPt53); + ConnEnd srcPt52(Point(52275,49850), 8); + ConnEnd dstPt52(Point(51150,49925), 4); + new ConnRef(router, srcPt52, dstPt52); + ConnEnd srcPt6(Point(51150,50500), 4); + ConnEnd dstPt6(Point(51925,50000), 4); + new ConnRef(router, srcPt6, dstPt6, 6); + router->processTransaction(); + router->outputDiagram("output/infinity"); + delete router; + return 0; +}; |
