* Set the border style.
(style: BorderStyle)
| 299 | * Set the border style. |
| 300 | */ |
| 301 | setBorderStyle(style: BorderStyle): void { |
| 302 | const bs = new PdfDict(); |
| 303 | |
| 304 | bs.set("W", PdfNumber.of(style.width ?? 1)); |
| 305 | bs.set("S", PdfName.of(BORDER_STYLE_REVERSE_MAP[style.style ?? "solid"])); |
| 306 | |
| 307 | if (style.dashArray && style.dashArray.length > 0) { |
| 308 | bs.set("D", new PdfArray(style.dashArray.map(n => PdfNumber.of(n)))); |
| 309 | } |
| 310 | |
| 311 | this.dict.set("BS", bs); |
| 312 | this.markModified(); |
| 313 | } |
| 314 | |
| 315 | // ───────────────────────────────────────────────────────────────────────────── |
| 316 | // Appearance Streams |
nothing calls this directly
no test coverage detected