PdfSharp.Xps  1.1.15
PdfSharp.Xps.Rendering.PdfContentWriter Class Reference

Provides the funtionality to write a PDF content stream for a PdfPage or an XForm. More...

Public Member Functions

void WriteLiteral (string value)
 Writes a string literally to the content stream. More...
 
void WriteLiteral (string format, params object[] args)
 Writes a formatted string literally to the content stream. More...
 
void WriteRgb (Color color, string op)
 
void WriteMatrix (XMatrix matrix)
 
void WriteGraphicsState (PdfExtGState extGState)
 
void WriteForm (XForm form)
 
 PdfContentWriter (DocumentRenderingContext context, PdfPage page)
 Initializes a new instance of the PdfContentWriter class for creating a content stream of the specified page. More...
 
 PdfContentWriter (DocumentRenderingContext context, XForm form, RenderMode renderMode)
 Initializes a new instance of the PdfContentWriter class for creating a content stream of the specified form. More...
 
 PdfContentWriter (DocumentRenderingContext context, PdfDictionary contentDictionary)
 
void WriteElements (XpsElementCollection elements)
 Writes all elements of the collection to the content stream. More...
 
void WriteElement (XpsElement element)
 Writes the specified element to the content stream. More...
 
void BeginContent (bool hacks4softmask)
 Initializes the default view transformation, i.e. the transformation from the user page space to the PDF page space. More...
 
void BeginContentRaw ()
 Just save current state. More...
 
void EndContent ()
 
void WriteRenderTransform (XMatrix matrix)
 Writes the specified transformation matrix to the content stream. More...
 
void WriteTextTransform (XMatrix matrix)
 Writes the specified text transformation matrix to the content stream. More...
 
void WriteClip (XRect rect)
 Writes the specified rectangle as intersection with the current clip path to the content stream. More...
 
void WriteClip (PathGeometry geo)
 Writes the specified PathGeometry as intersection with the current clip path to the content stream. More...
 
void WriteOpacityMask (Brush brush)
 
XMatrix MultiplyTransform (XMatrix matrix)
 Muliplies the spcified transformation with the current transformation and returns the new value; More...
 
double MultiplyOpacity (double opacity)
 Muliplies the spcified opacity with the current opacity and returns the new value; More...
 
void RealizeFill (Brush brush, ref XForm xform, ref XImage ximage)
 Makes the specified brush to the current graphics object. More...
 
void RealizeFillOpacity (double opacity)
 Realizes the opacity for non-stroke operations. More...
 
void RealizeStroke (Path path)
 Makes the specified pen to the current graphics object. More...
 
void RealizeStrokeOpacity (double opacity)
 Realizes the opacity for stroke operations. More...
 
void RealizeExtGState (PdfExtGState xgState)
 Realizes the specified graphic state. More...
 
void WriteSaveState (string traceMessage, string elementName)
 Saves the current graphical state and writes a push state operator to the content stream. More...
 
void WriteRestoreState (string traceMessage, string elementName)
 Restores the previous graphical state and writes a pop state operator to the content stream. More...
 

Properties

DocumentRenderingContext Context [get]
 Gets the document rendering context this PDF contentwriter belongs to. More...
 
XMatrix DefaultPageTransform [get]
 Gets the default page transformation. More...
 
XMatrix Transform [get]
 Gets the current transformation. More...
 
double Opacity [get]
 Gets the current opacity value. More...
 

Detailed Description

Provides the funtionality to write a PDF content stream for a PdfPage or an XForm.

Constructor & Destructor Documentation

◆ PdfContentWriter() [1/3]

PdfSharp.Xps.Rendering.PdfContentWriter.PdfContentWriter ( DocumentRenderingContext  context,
PdfPage  page 
)

Initializes a new instance of the PdfContentWriter class for creating a content stream of the specified page.

◆ PdfContentWriter() [2/3]

PdfSharp.Xps.Rendering.PdfContentWriter.PdfContentWriter ( DocumentRenderingContext  context,
XForm  form,
RenderMode  renderMode 
)

Initializes a new instance of the PdfContentWriter class for creating a content stream of the specified form.

◆ PdfContentWriter() [3/3]

PdfSharp.Xps.Rendering.PdfContentWriter.PdfContentWriter ( DocumentRenderingContext  context,
PdfDictionary  contentDictionary 
)

Member Function Documentation

◆ BeginContent()

void PdfSharp.Xps.Rendering.PdfContentWriter.BeginContent ( bool  hacks4softmask)

Initializes the default view transformation, i.e. the transformation from the user page space to the PDF page space.

◆ BeginContentRaw()

void PdfSharp.Xps.Rendering.PdfContentWriter.BeginContentRaw ( )

Just save current state.

◆ EndContent()

void PdfSharp.Xps.Rendering.PdfContentWriter.EndContent ( )

◆ MultiplyOpacity()

double PdfSharp.Xps.Rendering.PdfContentWriter.MultiplyOpacity ( double  opacity)

Muliplies the spcified opacity with the current opacity and returns the new value;

◆ MultiplyTransform()

XMatrix PdfSharp.Xps.Rendering.PdfContentWriter.MultiplyTransform ( XMatrix  matrix)

Muliplies the spcified transformation with the current transformation and returns the new value;

◆ RealizeExtGState()

void PdfSharp.Xps.Rendering.PdfContentWriter.RealizeExtGState ( PdfExtGState  xgState)

Realizes the specified graphic state.

◆ RealizeFill()

void PdfSharp.Xps.Rendering.PdfContentWriter.RealizeFill ( Brush  brush,
ref XForm  xform,
ref XImage  ximage 
)

Makes the specified brush to the current graphics object.

◆ RealizeFillOpacity()

void PdfSharp.Xps.Rendering.PdfContentWriter.RealizeFillOpacity ( double  opacity)

Realizes the opacity for non-stroke operations.

◆ RealizeStroke()

void PdfSharp.Xps.Rendering.PdfContentWriter.RealizeStroke ( Path  path)

Makes the specified pen to the current graphics object.

◆ RealizeStrokeOpacity()

void PdfSharp.Xps.Rendering.PdfContentWriter.RealizeStrokeOpacity ( double  opacity)

Realizes the opacity for stroke operations.

◆ WriteClip() [1/2]

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteClip ( PathGeometry  geo)

Writes the specified PathGeometry as intersection with the current clip path to the content stream.

◆ WriteClip() [2/2]

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteClip ( XRect  rect)

Writes the specified rectangle as intersection with the current clip path to the content stream.

◆ WriteElement()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteElement ( XpsElement  element)

Writes the specified element to the content stream.

◆ WriteElements()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteElements ( XpsElementCollection  elements)

Writes all elements of the collection to the content stream.

◆ WriteForm()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteForm ( XForm  form)

◆ WriteGraphicsState()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteGraphicsState ( PdfExtGState  extGState)

◆ WriteLiteral() [1/2]

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteLiteral ( string  format,
params object[]  args 
)

Writes a formatted string literally to the content stream.

◆ WriteLiteral() [2/2]

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteLiteral ( string  value)

Writes a string literally to the content stream.

◆ WriteMatrix()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteMatrix ( XMatrix  matrix)

◆ WriteOpacityMask()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteOpacityMask ( Brush  brush)

◆ WriteRenderTransform()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteRenderTransform ( XMatrix  matrix)

Writes the specified transformation matrix to the content stream.

◆ WriteRestoreState()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteRestoreState ( string  traceMessage,
string  elementName 
)

Restores the previous graphical state and writes a pop state operator to the content stream.

◆ WriteRgb()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteRgb ( Color  color,
string  op 
)

◆ WriteSaveState()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteSaveState ( string  traceMessage,
string  elementName 
)

Saves the current graphical state and writes a push state operator to the content stream.

◆ WriteTextTransform()

void PdfSharp.Xps.Rendering.PdfContentWriter.WriteTextTransform ( XMatrix  matrix)

Writes the specified text transformation matrix to the content stream.

Property Documentation

◆ Context

DocumentRenderingContext PdfSharp.Xps.Rendering.PdfContentWriter.Context
get

Gets the document rendering context this PDF contentwriter belongs to.

◆ DefaultPageTransform

XMatrix PdfSharp.Xps.Rendering.PdfContentWriter.DefaultPageTransform
get

Gets the default page transformation.

◆ Opacity

double PdfSharp.Xps.Rendering.PdfContentWriter.Opacity
get

Gets the current opacity value.

◆ Transform

XMatrix PdfSharp.Xps.Rendering.PdfContentWriter.Transform
get

Gets the current transformation.


The documentation for this class was generated from the following files: