"dim" - mkraska/meclib GitHub Wiki

[ "dim", "name", [x1, y1], [x2,y2], off ]

Linear dimension with label

  • "name" label text, typeset in MathJax math mode (stars * are replaced by small spaces \;)
  • [x1, y1], [x2,y2] reference points
  • off offset of the actual annotation from the baseline defined by the reference points. Offset counts positive to the left side seen from point 1 to point 2. If zero, short end lines are drawn.

image

[
  [ "grid", "x","y", -5,5,-4,5, 50, [1,1], [0,0] ],
  [ "dim", "name", [1, 2], [3,2], -1 ],
  [ "point", "1", [1,2] ],
  [ "point", "2", [3,2] ]
]

image

[
  [ "grid", "x","y", -1,9,-4,5, 50, [1,1], [0,0] ],
  [ "dim", "2*a", [1, 2], [3,2], -0.5 ],
  [ "dim", "2*b", [1, 2], [3,2], 0.5 ],
  [ "point", "1", [1,2] ],
  [ "point", "2", [3,2] ],
  [ "dim", "c", [5, 2], [4,2], -0.5 ],
  [ "dim", "d", [5, 2], [4,2], 0.5 ],
  [ "point", "1", [5,2] ],
  [ "point", "2", [4,2] ],
  [ "dim", "\\ell", [6, 2], [7,2], 0 ],
  [ "dim", "\\ell", [6, 1.5], [7,1.5], 0 ],
  [ "point", "1", [6,2] ],
  [ "point", "2", [7,2] ]
]