0

I am making a dependency graph of a rust project, whose documentation is emitted as pure html. I am wondering if there is a simple way to modify the html to insert an svg image in an interactive window with panning and zooming, the way it works on doxygen.

This is the html:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="generator" content="rustdoc">
    <title>NeverEngine</title>

    
    
</head>
<body class="rustdoc">
    <!--[if lte IE 8]>
    <div class="warning">
        This old browser is unsupported and will most likely display funky
        things.
    </div>
    <![endif]-->

    
    <h1 class="title">NeverEngine</h1>
    <nav id="TOC"><ul></ul></nav><p><img src="./dep-graph.svg" alt="Dep graph" /></p>
<p><a href="TODO.html">TODOs</a></p>

    
</body>
</html>

And the idea is to grab <nav id="TOC"><ul></ul></nav><p><img src="./dep-graph.svg" alt="Dep graph" /></p> and embed it into an element that allows me to zoom and pan.

Makogan
  • 8,208
  • 7
  • 44
  • 112

0 Answers0