ivanceras / svgbob

Convert your ascii diagram scribbles into happy little SVG
http://ivanceras.github.io/svgbob-editor/
Apache License 2.0
3.82k stars 108 forks source link

Online demo preview and SVG output don't match #106

Open ianjevans opened 10 months ago

ianjevans commented 10 months ago

I was using the online demo to make some simple diagrams, and used the following text:


 Cutover phase

                    .--------------.
                    |              |
        .-------->  |  CockroachDB |
       |            | {t}          |
       |            '--------------'
       |                   !
       |                   !
       |                   V
+-------------+       .----------.
|             |      /            \
| Application |     (  replication )
|{a}          |      \            /
+-------------+       '----------' 
                           |
                           V
                    .--------------.
                    |              |
                    |  Source DB   |
                    | {s}          |
                    '--------------'

# Legend:
t = {
    stroke: #6933ff;
    fill: #b59cf9;
}
s = {
    stroke: green;
    fill: lightgreen;
}
a = {
    fill: lightblue;
}
crdb = {
    fill: #6933ff;
    color: white;
}

The preview looks good:

Screenshot 2023-10-06 at 9 38 09 AM

But the output SVG from clicking Download SVG has spacing issues: bob

ivanceras commented 10 months ago

@ianjevans This seems to be a font issue, the demo is using Iosevka fonts which I found to fit well with svgbob. The downloaded svg will use your default monospace font if Iosevka is not installed in your system. You can try to install Iosevka in your system.