| Category | Path painting |
|---|---|
| Note | has a real precondition, unlike pdfClosePath (see Remarks) |
Purpose — Stroke the current manually-built path (S operator).
Declarations
BOOL32 __stdcall pdfStrokePath(PPDF IPDF);
function pdfStrokePath(const IPDF: PPDF): LongBool; stdcall; external 'LumasPdf.dll';
Return value — TRUE on success; FALSE if no path has been started (pdfMoveTo/pdfRectangle/etc. never called since the page opened) — stroking with no current path is treated as an error, matching LumasPDF behavior.
Remarks — Note the asymmetry with pdfClosePath, which has no such precondition check — pdfClosePath will happily emit a paint operator even with no path started (producing a no-op paint on an empty path), while pdfStrokePath explicitly refuses.
C# (P/Invoke)
[return: MarshalAs(UnmanagedType.Bool)]
Core
pdfStrokePath
The …A form takes UTF-8, …W
takes UTF-16; a bare name aliases the ANSI form.
Worked examples — complete programs in ten languages.