procedure AddPath;
将累积的 MoveTo/LineTo/BezierTo 路径以请求的绘制方式作为新页面对象提交
在由 CreatePath 开始、并用 MoveTo、LineTo、BezierTo 和 ClosePath 构建的路径完成后调用;描边与填充属性在 CreatePath 上配置
对当前页面的所有编辑都缓存在 PDFium 的内存表示中。调用 UpdatePage 刷新渲染缓存,调用 SaveAs 持久化更改
Pdf1.Active 必须为 True 且必须已选择页面
begin
if Pdf1.Active then
begin
Pdf1.CreatePath(100, 100, fmWinding, clYellow, $FF, True, clRed, $FF, 1.5);
Pdf1.LineTo(200, 150);
Pdf1.LineTo(200, 200);
Pdf1.ClosePath;
Pdf1.AddPath;
Pdf1.UpdatePage;
end;
end;