textDraw

Utility for drawing diagram in unicode with a json file format
git clone https://noulin.net/git/textDraw.git
Log | Files | Refs

computer.json (1514B)


      1 [
      2  {type: 'box',
      3      x: 0,
      4      y: 0,
      5      xx: 32,
      6      yy: 14,
      7      style: 'double',
      8      color: 'black',
      9      bgColor: '#cccccc',
     10     },
     11  {type: 'text',
     12   text: "Computer",
     13      x: 1,
     14      y: 1,
     15   color:   'black',
     16  },
     17  {type: 'box',
     18      x: 3,
     19      y: 2,
     20      xx: 30,
     21      yy: 13,
     22      style: 'single',
     23      color: 'black',
     24      arcCorner: true
     25     },
     26  {type: 'text',
     27   text: "Components",
     28      x: 4,
     29      y: 3,
     30   color:   'black',
     31  },
     32  {type: 'box',
     33      x: 6,
     34      y: 4,
     35      xx: 28,
     36      yy: 12,
     37      style: 'dash',
     38      color: 'black',
     39     },
     40  {type: 'text',
     41   text: "Input devices",
     42      x: 7,
     43      y: 5,
     44   color:   'black',
     45  },
     46  {type: 'box',
     47      x: 9,
     48      y: 6,
     49      xx: 26,
     50      yy: 11,
     51      style: 'quadrupledash',
     52      color: 'black',
     53      arcCorner: true
     54     },
     55  {type: 'text',
     56   text: "Pointing devices",
     57      x: 10,
     58      y: 7,
     59   color:   'black',
     60  },
     61  {type: 'box',
     62      x: 12,
     63      y: 8,
     64      xx: 24,
     65      yy: 10,
     66      style: 'space',
     67      color: 'black',
     68      bgColor: '#ffffff',
     69     },
     70  {type: 'text',
     71   text: "Touchscreen",
     72      x: 13,
     73      y: 9,
     74   color:   '#770000',
     75  },
     76  {type: 'box',
     77      x: 34,
     78      y: 8,
     79      xx: 51,
     80      yy: 10,
     81      style: 'heavyDash',
     82      color: 'Yellow',
     83      bgColor: 'green',
     84      arcCorner: false
     85     },
     86  {type: 'text',
     87   text: "Human",
     88      x: 40,
     89      y: 9,
     90   color:   '#000099',
     91  },
     92  {type: 'horizontalLine',
     93     at:   9,
     94   start: 39,
     95   stop:  25,
     96   stopEdge:  '◀', // when missing use style (straight line)
     97   style: 'heavy'
     98   color:   '#ffffff',
     99  },
    100 ]
    101