API referenceText

pdfSetExtGStatePrepress

Configure the prepress-related fields (/TR transfer, /BG

CategoryExtended graphics state (prepress)

Purpose — Configure the prepress-related fields (/TR transfer, /BG black-generation, /UCR undercolor-removal, /HT halftone) on an already-created ExtGState resource.

Description — resource-level configuration, not an immediate operator. Unlike pdfSetExtGState, this call does not write anything to the content stream — it mutates the stored ExtGState resource identified by Handle (must already exist via pdfCreateExtGState), which only takes effect on the page once pdfSetExtGState(Handle) is called to apply that resource. Each *Kind parameter follows the same 3-way convention: 0=unset (omit the key), 1=Identity, 2=Default. For a fully custom (not Identity/Default) transfer or black-generation function, see the separate pdfSetTransferFunction/pdfSetBlackGenFunction (install a real sampled /TR2//BG2 function — not part of this chapter).

Declarations

C
BOOL32 __stdcall pdfSetExtGStatePrepress(PPDF IPDF, int32_t Handle, int32_t TransferKind, int32_t BGKind, int32_t UCRKind, int32_t HTKind);
Delphi
function pdfSetExtGStatePrepress(const IPDF: PPDF; Handle, TransferKind, BGKind, UCRKind, HTKind: Integer): LongBool; stdcall; external 'LumasPdf.dll';

Parameters

ParameterTypeDescription
IPDFPPDFInstance handle.
HandleIntegerAn existing ExtGState resource handle from pdfCreateExtGState.
TransferKindInteger/TR: 0=unset, 1=Identity, 2=Default.
BGKindInteger/BG: same 3-way convention.
UCRKindInteger/UCR: same 3-way convention.
HTKindInteger/HT: same 3-way convention.

Return valueTRUE if Handle resolves to an existing ExtGState resource; FALSE otherwise.

See alsopdfSetExtGState, pdfSetTransferFunction, pdfSetBlackGenFunction

C# (P/Invoke)

wrappers/dotnet/LumasPdf.cs
[return: MarshalAs(UnmanagedType.Bool)]
Area
Text
Category

Setters

Exported names

pdfSetExtGStatePrepress

String variants

The …A form takes UTF-8, …W takes UTF-16; a bare name aliases the ANSI form.

See working code

Worked examples — complete programs in ten languages.