LayMesh文档
EN

Path At

path-at.lay
# Minimal complete example: path.atpage=canvas(size=(100mm,75mm),background="#ffffff")curve=page.add(path(commands=[move_to(0mm,0mm),cubic_to(0mm,0mm,0mm,35mm,50mm,35mm),cubic_to(65mm,35mm,70mm,0mm,75mm,0mm),line_to(82mm,12mm)],border_color="#0072b2",border_width=0.7mm),offset=(8mm,15mm))route=curve.path.subpaths[0]dot=ellipse(size=(2mm,2mm),fill="#e36b70")point=route.at(fraction=0.5)page.add(dot,anchor=center,target=point)

预览

背景
Path At
原始示例
合计 —
详情

尚未运行

本设备浏览器实测;不含防抖等待。

修改仅保留在本页
依赖文件
  • examples/manual/path-at.lay

复现

sh
laymesh validate examples/manual/path-at.laylaymesh render examples/manual/path-at.lay -o figure.svglaymesh render examples/manual/path-at.lay -o figure.pdflaymesh render examples/manual/path-at.lay -o figure.png --dpi 300