THPDFContentToken Record

Rappresenta un token del content stream, operatore o operando, con il suo span di byte nella sorgente e il payload dell'immagine inline

Dichiarazione

THPDFContentToken= record
  Kind: THPDFContentTokenKind;
  Op: AnsiString;           // operator text (ctOperator) or name literal
  StrBytes: AnsiString;     // raw bytes of string/hex operand
  IsHex: boolean;
  NumValue: Double;         // numeric operand
  Items: THPDFArrayItems;   // ctOperandArray payload
  // StartOfs/EndOfs are byte offsets into the source content stream spanning
  // the operand as written. For a string/hex operand this covers the full
  // literal including its '(' ')' or '<' '>' delimiters; operators and
  // other operands record their span too. Search/replace uses these to map
  // a matched glyph back to the bytes that produced it
  StartOfs: Integer;
  EndOfs: Integer;
  // Inline image payload (only the 'BI' operator token carries these;
  // every other token leaves them at their default zeros). InlineBytes is
  // the raw image data between ID and EI; InlineKeys is the normalised
  // BI key/value set. Both default to empty when not an inline image
  InlineBytes: SysUtils.TBytes;
  InlineKeys: THPDFInlineImgKeys;
end;

Unità

HPDFContentStream

Campi

CampoScopo
KindClasse del token: ctOperator, ctOperandString, ctOperandHex, ctOperandName, ctOperandNumber o ctOperandArray
OpTesto dell'operatore per i token ctOperator, o il letterale del name per gli operandi name
StrBytesByte grezzi di un operando stringa o hex, inclusi i delimitatori nello span di sorgente
IsHexTrue quando l'operando stringa è stato scritto come stringa hex
NumValueValore dell'operando numerico, inclusi gli aggiustamenti di crenatura TJ
ItemsPayload array per i token ctOperandArray
StartOfsOffset di byte del token come scritto nel content stream sorgente
EndOfsOffset di byte subito dopo il token
InlineBytesDati immagine grezzi tra ID e EI; lo porta solo il token operatore BI
InlineKeysInsieme chiave/valore BI normalizzato; vuoto per ogni token diverso da BI

Note sull'utilizzo

API correlate