Enregistrement THPDFContentToken

Représente un token de flux de contenu, opérateur ou opérande, avec sa plage d'octets source et sa charge utile d'image inline

Déclaration

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

Champs

ChampObjectif
KindClasse du token : ctOperator, ctOperandString, ctOperandHex, ctOperandName, ctOperandNumber ou ctOperandArray
OpTexte de l'opérateur pour les tokens ctOperator, ou littéral du nom pour les opérandes nom
StrBytesOctets bruts d'un opérande chaîne ou hexadécimal, délimiteurs inclus dans la plage source
IsHexTrue quand l'opérande chaîne a été écrit comme chaîne hexadécimale
NumValueValeur de l'opérande numérique, ajustements de crénage TJ compris
ItemsCharge utile de tableau pour les tokens ctOperandArray
StartOfsDécalage d'octet du token tel qu'écrit dans le flux de contenu source
EndOfsDécalage d'octet juste après le token
InlineBytesDonnées d'image brutes entre ID et EI ; seul le token opérateur BI les porte
InlineKeysEnsemble clé/valeur BI normalisé ; vide pour tout token autre que BI

Notes d'utilisation

API associées