summaryrefslogtreecommitdiffstats
path: root/svgbob/examples/circuits.rs
blob: 907112697a1113c839d89897598172b41c8c8cba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
extern crate svgbob;
extern crate svg;

use svgbob::Grid;
use svgbob::Settings;


fn main() {
    let file = "examples/circuits.svg";
    let arg = include_str!("circuits.bob");
    let g = Grid::from_str(arg, &Settings::compact());
    let svg = g.get_svg();
    svg::save(file, &svg).unwrap();
    println!("Saved to {}",file);
}