• Topic
  • Discussion
  • OATWikiWeb.OATDOCgraphsvg(Last) -- Owiki? , 2016-08-19 14:58:51 Edit owiki 2016-08-19 14:58:51

    graphsvg.js

    SVG-based RDF Graph viewer.

    Objects

    OAT.GraphSVG(div, vertices, edges, optionsObject)

    Creates the Graph Viewer inside div.

    vertices is an array of vertex objects:
    { name: "node_label", type: 0/1 } // type: URI/non-URI; 
    

    edges is an array of edge objects:

    { vertex1: vertex_object, vertex2: vertex_objects, name: "edge_label" }. 
    

    optionsObject holds available options:

    • imagePath - path with images for tree in sidebar
    • vertexColor - string
    • edgeColor - string
    • backgroundColor - string
    • vertexSize - int
    • vertexPadding - int
    • padding - int
    • edgeSize - int
    • type - int; 0 - all nodes at once, 1 - equal distances
    • placement - int; 0 - random, 1 - circle
    • distance - int; 0 - close, 1 - medium, 2 - far
    • projection - int; 0 - planar, 1 - spherical
    • labels - int; 0 - only element, 1-4 - distances
    • show - int; 0 - all, 1-4 - distances

    CSS Classes

    .rdf_sidebar

    CSS class of the sidebar div containing trees with RDF resources, classes and predicates.


    Referenced by...