PDF4Java Reference Documentation
com.o2sol.pdf4java.graphics Package / PDFContentStream Class
Collapse All Expand All Members Options: Show All Members Options: Filtered
Include Inherited Members
Include Protected Members
In This Topic

PDFContentStream Class Methods
In This Topic

For a list of all members of this type, see PDFContentStream members.

Public Methods

| Name | Description
--- | --- | ---
| addOperator | Adds the given operator to the content stream.
| beginCompatibilitySection | Begins a compatibility section. Operator: BX.
| beginInlineImage | Begins an inline image. Operator: BI.
| beginInlineImageData | Begins the data section of an inline image. Operator: ID.
| beginMarkedContent | Begins a marked-content sequence.
| beginMarkedContentWithPropertyList | Begins a marked-content sequence with an associated property list.
| beginText | Begins a text section. Operator: BT.
| cCurveTo | Append a cubic Bézier curve to the current path. Operator: c
| clear | Clears the entire content stream.
| closeAndStrokePath | Closes and strokes the current path. Operator: s.
| closeFillNonZeroStroke | Closes the current path, fills the path using the fillMode and then strokes the path. Operator: b for PDFFillMode.NonZeroWinding or b* for PDFFillMode.EvenOdd.
| closeSubpath | Closes the current path. Operator: h.
| concatenateMatrix | Concatenates the given matrix with the current transformation matrix. Operator: cm
| defineMarkedContentPoint | Defines a marked-content point.
| defineMarkedContentPointWithPropertyList | Defines a marked-content point with an associated property list.
| endCompatibilitySection | Ends a compatibility section. Operator: EX.
| endInlineImage | Ends an inline image. Operator: EI.
| endMarkedContent | Ends a marked content section. Operator: EMC.
| endPath | Ends the current path. Operator: n.
| endText | Ends a text section. Operator: ET.
| fillNonZeroStroke | Fills the current path using the fillMode and then strokes the path. Operator: B for PDFFillMode.NonZeroWinding or B* for PDFFillMode.EvenOdd.
| fillPath | Fills the current path using the fillMode. Operator: f for PDFFillMode.NonZeroWinding or f* for PDFFillMode.EvenOdd.
| lineTo | Appends a line segment to current path from current point to (x, y). Operator: l
| moveTextPosition | Moves the text position. Operator: Td
| moveTextPositionAndSetLeading | Moves the text position. Operator: TD
| moveTo | Begins a new subpath at (x, y). Operator: m
| moveToStartOfNextTextLine | Moves to the start of the next line. Operator: T*
| rectangle | Appends a rectangle to current path. Operator: re
| resetPDFCoordinateSystem | Resets the coordinate system to default PDF coordinate system.
| restoreGraphicsState | Restores the current graphics state. Operator: Q.
| restoreVisualCoordinateSystem | Restores the coordinate system as it has been setup initially by class.
| saveGraphicsState | Saves the current graphics state. Operator: q.
| setCharacterSpacing | Sets the character spacing. Operator: Tc
| setClipPath | Sets the current path as clipping path. Operator: W for PDFFillMode.NonZeroWinding or W* for PDFFillMode.EvenOdd.
| setCmykFillColor | Sets the current colorspace for fill operations to DeviceCMYK and sets the current CMYK color. Operator: k
| setCmykStrokeColor | Sets the current colorspace for stroke operations to DeviceCMYK and sets the current CMYK color. Operator: K
| setExtendedGraphicsState | Sets the current graphics state in the content stream. Operator: gs
| setFillColor | Sets the current fill color. Operator: sc
| setFillColorN | Overloaded. Sets the current fill color. Operator: scn
| setFillColorSpace | Sets the fill colorspace. Operator: cs
| setFlatnessTolerance | Set the flatness tolerance in the graphics state. Operator: i
| setGrayFillColor | Sets the current colorspace for fill operations to DeviceGray and sets the gray level. Operator: g
| setGrayStrokeColor | Sets the current colorspace for stroke operations to DeviceGray and sets the gray level. Operator: g
| setLineCap | Set the line cap style in the graphics state. Operator: J
| setLineDashPattern | Sets the dash offset and pattern for stroke operations. Operator: d
| setLineJoin | Set the line join style in the graphics state. Operator: j
| setLineWidth | Sets the line width in the graphics state.
| setMiterLimit | Set the miter limit in the graphics state. Operator: M
| setRgbFillColor | Sets the current colorspace for fill operations to DeviceRGB and sets the current RGB color. Operator: rg
| setRgbStrokeColor | Sets the current colorspace for stroke operations to DeviceRGB and sets the current RGB color. Operator: RG
| setStrokeColor | Sets the current stroke color. Operator: SC
| setStrokeColorN | Overloaded. Sets the current stroke color. Operator: SCN
| setStrokeColorSpace | Sets the stroke colorspace. Operator: CS
| setTextFontAndSize | Sets the current font and size for text show operators. Operator: Tf
| setTextHorizontalScaling | Sets the text horizontal scaling. Operator: Tz
| setTextLeading | Sets the text leading. Operator: TL
| setTextMatrix | Sets the current text matrix and text line matrix. Operator: Tm
| setTextRendering | Sets the text rendering mode. Operator: Tr
| setTextRise | Sets the text rise. Operator: Ts
| setWordSpacing | Sets the word spacing. Operator: Tw
| showFormXObject | Shows a form XObject on the page. Operator: Do
| showImage | Shows an image on the page. Operator: Do
| showShading | Shows a shading on the page. Operator: sh
| showText | Shows the specified text on the page. Operator: Tj
| showTextArray | Shows one or more text strings, allowing individual glyph positioning.
| strokePath | Strokes the current path. Operator: S.
| vCurveTo | Append a cubic Bézier curve to the current path. Operator: v
| writeByte | Writes the specified byte to the content stream.
| writeBytes | Overloaded. Writes the specified bytes to the content stream.
| yCurveTo | Append a cubic Bézier curve to the current path. Operator: y

Top
See Also

#### Reference

PDFContentStream Class
com.o2sol.pdf4java.graphics Package

© 2025 O2 Solutions All Rights Reserved.

Send comments on this topic.