This application was made to study the Rust language and also for the discipline of algorithm design
- Tree detection
- Display adjacency between two nodes
- Get all neighbors from selected nodes
- Visit all edges
- Display selected node degree
- Export .dot file to feed graphviz framework
- Export svg graph from .dot file
Obs: Graph input not persists in memory, every click interations load txt file and free itself memory after close function call (as rust feature), except by load button that save nodes info.
Make sure to download graphviz binaries and put on root directory, this is the more important dependency to plot graph. The especific version used was 8.0.3
- Download Graphviz binaries from official page
- Paste zip file content in program root directory
The three folder will be like this:
├── /.fingerprint ├── /build ├── /deps ├── /examples └── /Graphviz └── /bin └── some_files.some_extension ├── /incremental ├── graph_project.exe └── some_files.some_extension
Fist, your graph need to stay in txt file in respective format:
- First line have "D" to digraph and "ND" to bidirectional graph
- Other line must be tuple of nodes. Brackets, braces, parentheses and letters are optional. Numbers and comma are required.
Important, if your nodes sequence starts with 1 or contains gaps in the count sequence, like [(A1,A4),(A1,A2),(A2,A4)], this nodes will be replaced to [(v0,v2),(v0,v1),(v1,v2)]. Input file examples is above:
ND
v0,v3
v1,v4
v3,v1
ND
node0,node3
node1,node4
node3,node1
ND
A0,A3
A1,A4
A3,A1
Maybe you need change gtk from crates.io to compatible version of your gtk local instalation