Browse Source

- Added support for Gephi directed edges, edge labels and titles.

webworkersNetwork
Alex de Mulder 8 years ago
parent
commit
0e6aac4634
2 changed files with 4 additions and 0 deletions
  1. +1
    -0
      HISTORY.md
  2. +3
    -0
      lib/network/gephiParser.js

+ 1
- 0
HISTORY.md View File

@ -23,6 +23,7 @@ http://visjs.org
- Made the network keep its 'view' during a change of the size of the container.
- Added improvedLayout as experimental option for greatly improved stabilization times.
- Added adaptiveTimestep as experimental option for greatly improved stabilization times.
- Added support for Gephi directed edges, edge labels and titles.
## 2015-07-27, version 4.7.0

+ 3
- 0
lib/network/gephiParser.js View File

@ -29,6 +29,9 @@ function parseGephi(gephiJSON, optionsObj) {
edge['attributes'] = gEdge.attributes;
edge['label'] = gEdge.label;
edge['title'] = gEdge.attributes !== undefined ? gEdge.attributes.title : undefined;
if (gEdge['type'] === 'Directed') {
edge['arrows'] = 'to';
}
// edge['value'] = gEdge.attributes !== undefined ? gEdge.attributes.Weight : undefined;
// edge['width'] = edge['value'] !== undefined ? undefined : edgegEdge.size;
if (gEdge.color && options.inheritColor === false) {

Loading…
Cancel
Save