是否有任何选项可以自定义Stroke_bounds? (铁轨虾)

发布于 2024-09-28 02:37:19 字数 137 浏览 1 评论 0原文

我想为 PDF 中的所有页面绘制边框。但是在使用 lines_bounds 时,我只能单独绘制单个暗线边框。我无法定制任何东西?

有人知道如何更改我的 lines_bounds 边框的样式吗?

I want to draw borders for all the pages in my PDF. But while using stroke_bounds, I can only draw single dark lined borders alone. I couldn't customize anything?

Does anybody have any idea on how to change the style of my stroke_bounds borders?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

剧终人散尽 2024-10-05 02:37:19

在 Prawn::Graphics::Dash 中使用 dash
http://prawn.majesticeacreature.com/docs/0.11.1 /Prawn/Graphics/Dash.html

示例:

pdf.dash 10, :space => 4
pdf.stroke_bounds

Use dash in Prawn::Graphics::Dash
http://prawn.majesticseacreature.com/docs/0.11.1/Prawn/Graphics/Dash.html

example:

pdf.dash 10, :space => 4
pdf.stroke_bounds
玉环 2024-10-05 02:37:19

我也有同样的问题。我发现您可以使用“中风颜色”函数来更改此颜色。

http://prawnpdf.org/docs/0.11 .1/Prawn/Graphics/Color.html#method-i-lines_color

stroke_color "FF0000"
stroke_bounds

I had the same problem. I found out that you can use the "stroke_color" function to change this color.

http://prawnpdf.org/docs/0.11.1/Prawn/Graphics/Color.html#method-i-stroke_color

stroke_color "FF0000"
stroke_bounds
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文