The elements Cx not distributed evenly, what's proper way to make it distribute evenly?
import schemdraw
from schemdraw.flow import *
import math
pngname = "./demo.png"
def d2r(degree):
return degree*math.pi/180
with schemdraw.Drawing() as d:
u = d.unit
w = u/4
h = u/4
dx = d.unit/3
dy = d.unit/8
d += Box(w=w,h=h).label("A")
d += Arrow().right(dx)
d += (P := Box(w=w,h=h).label("B"))
d += Arrow().theta(45).length(dx/math.cos(d2r(45)))
d += Box(w=w,h=h).label("C1")
d += Arrow().at(P.E).theta(15).length(dx/math.cos(d2r(15)))
d += Box(w=w,h=h).label("C2")
d += Arrow().at(P.E).theta(-15).length(dx/math.cos(d2r(15)))
d += Box(w=w,h=h).label("C3")
d += Arrow().at(P.E).theta(-45).length(dx/math.cos(d2r(45)))
d += Box(w=w,h=h).label("C4")
d.save(pngname, transparent=False,dpi = 150)
print("[[%s]]"%pngname)