Aspose::Page::EPS::Device::PdfDevice class

PdfDevice class

This class encapsulates rendering of document to PDF.

class PdfDevice : public Aspose::Page::Device,
                  public Aspose::Page::IMultiPageDevice,
                  public Aspose::Page::IStreamable

Methods

MethodDescription
static AUTHOR()“Author” property value.
static BACKGROUND()“Background” property key.
static BACKGROUND_COLOR()“Background color” property key.
virtual Clip(System::SharedPtr<System::Drawing::Drawing2D::GraphicsPath>)Clips using given shape. Dispatches to writeClip(Rectangle), writeClip(RectangleF) or writeClip(Shape).
virtual ClipRect(float, float, float, float)Clips rectangle. Calls clip(Rectangle2D).
ClosePage() overrideMakes necessary preparation of the device after page has been rendered.
CloseStream()
static COMPRESS()“Compress” property key.
virtual Copy()
Create() overrideCreates a copy of this device.
virtual Create(float, float, float, float)
CreatePdfCanvas()
Dispose() overrideDisposes the graphics context. If on creation restoreOnDispose was true, writeGraphicsRestore() will be called.
Draw(System::SharedPtr<System::Drawing::Drawing2D::GraphicsPath>) overrideDraws a path.
DrawBitmapGlyph(System::SharedPtr<System::Object>, System::String, System::SharedPtr<System::Drawing::Bitmap>, System::SharedPtr<System::Drawing::Drawing2D::Matrix>) override
DrawImage(System::SharedPtr<System::Drawing::Bitmap>, System::SharedPtr<System::Drawing::Drawing2D::Matrix>, System::Drawing::Color) overrideDraws an image with assigned transform and background.
DrawString(System::String, double, double) overrideDraws a string at given point.
static EMBED_FONTS()“Embed font in document” property key.
static EMBED_FONTS_AS()“What font type is used for embedding” property key.
static EMIT_ERRORS()“Emit errors” property value.
static EMIT_WARNINGS()“Emit warnings” property value.
EndDocument() overrideMakes necessary preparation of device after the document has been rendered.
Fill(System::SharedPtr<System::Drawing::Drawing2D::GraphicsPath>) overrideFills a path.
FillLastClip()
static FIT_TO_PAGE()“Fit content to page” property key.
get_CurrentPageNumber() overrideCurrent page number.
get_LastWrittenPaint() constDraws frame and banner around a string. The method calculates and returns the point to which the text curser should be set before drawing the string.
get_OutputStream() overrideSpecifies or returns an output stream.
get_WarningMessage()
GetFinalWrittenLength() override
GetTransform() overrideGets current transform.
InitClip() overrideInitializes clip of the device.
InitPageNumbers() overrideInitializes numbers of pages to output.
static KEYWORDS()“Keywords” property value.
OpenPage(System::String) overrideMakes necessary preparation of the device before page rendering.
OpenPage(float, float) overrideMakes necessary preparation of the device before each page rendering.
static ORIENTATION()“Orientation” property key.
static PAGE_MARGINS()“Page margins” property key.
PdfDevice(System::SharedPtr<System::IO::Stream>)Initializes new instance of PdfDevice with output stream.
PdfDevice(System::SharedPtr<System::IO::Stream>, System::Drawing::Size)Initializes new instance of PdfDevice with output stream and specified size of a page.
PdfDevice(System::SharedPtr<PdfDevice>, bool)Clone constructor. Initializes new instance of PdfDevice with existing device.
ReNew() overrideReset device to initial state for whole document. Used for reseting output stream.
ReNewForMerge(bool) overrideReset device to initial state for whole document while merging several documents. Used for reseting output stream.
Reset() overrideIf page device parameters will be set this method allows to return writing stream back the begining of page.
Reset(bool) override
virtual ResetClip(System::Drawing::Rectangle)
Rotate(double) overrideRotate the current transform over the Z-axis. Calls writeTransform(Transform). Rotating with a positive angle theta rotates points on the positive x axis toward the positive y axis.
virtual SavePageTransform()
Scale(double, double) overrideScales the current transformation matrix. Calls writeTransform(Transform).
set_Font(System::SharedPtr<BaseTrFont>) overrideSpecifies current font.
set_OutputStream(System::SharedPtr<System::IO::Stream>) overrideSpecifies or returns an output stream.
set_Paint(System::SharedPtr<System::Drawing::Brush>) overrideReturns or specifies current paint.
set_Stroke(System::SharedPtr<System::Drawing::Pen>) overrideReturns or specifies current stroke.
SetClip(System::SharedPtr<System::Drawing::Drawing2D::GraphicsPath>) overrideSpecifies the clip of the device.
virtual SetFooter(System::SharedPtr<Aspose::Page::EPS::Postscript::TrFont>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, int32_t)
virtual SetHeader(System::SharedPtr<Aspose::Page::EPS::Postscript::TrFont>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, System::SharedPtr<Aspose::Page::EPS::Graphics2d::TagString>, int32_t)
SetSaveFromPatternCreate()
SetTransform(System::SharedPtr<System::Drawing::Drawing2D::Matrix>) overrideSpecifies the current transform. Since most output formats do not implement this functionality, the inverse transform of the currentTransform is calculated and multiplied by the transform to be set.The result is then forwarded by a call to writeTransform(Transform).
Shear(double, double) overrideShears the current transformation matrix. Calls writeTransform(Transform).
StartDocument() overrideMakes necessary preparation of device before start rendering of document.
static SUBJECT()“Subject” property value.
static TITLE()“Title” property value.
ToString() const overrideReturns the name of device type.
Transform(System::SharedPtr<System::Drawing::Drawing2D::Matrix>) overrideTransforms the current transformation matrix. Calls writeTransform(Transform)
Translate(double, double) overrideTranslates the current transformation matrix. Calls writeTransform(Transform).
static TRANSPARENT()“Transparent” property key.
UpdatePageParameters(System::SharedPtr<IMultiPageDevice>) overrideUpdates page parameters from other multi-paged device.
static WRITE_IMAGES_AS()“Format of images” property key.
WriteBackground() overrideWrites out current background.
WriteCap(System::Drawing::Drawing2D::LineCap) overrideWrites out the cap of the stroke.
virtual WriteClip(System::Drawing::RectangleF)
virtual WriteClip(System::SharedPtr<System::Drawing::Drawing2D::GraphicsPath>)
WriteComment(System::String) overrideWrites a comment.
WriteDash(System::ArrayPtr<double>, double, System::Drawing::Drawing2D::DashCap, float) overrideWrites out the dash of the stroke.
virtual WriteGraphicsRestore()
virtual WriteGraphicsSave()
WriteHeader()Writes the catalog, docinfo, preferences, and (as we use only single page output the page tree.
WriteJoin(System::Drawing::Drawing2D::LineJoin) overrideWrites out the join of the stroke.
WriteLastWrittenPaint()Writes out last written paint. It is useful in cases when after writing paint graphics restore (“Q”) was performed.
WriteMiterLimit(float) overrideWrites out the miter limit of the stroke.
WritePaint(System::SharedPtr<System::Drawing::SolidBrush>) overrideWrites out paint as the given color.
WritePaint(System::SharedPtr<System::Drawing::Drawing2D::LinearGradientBrush>) overrideWrites out paint as the given gradient.
WritePaint(System::SharedPtr<System::Drawing::TextureBrush>) overrideWrites out paint as the given texture.
WritePaint(System::SharedPtr<System::Drawing::Brush>) overrideWrites out paint.
WriteString(System::SharedPtr<BaseTrFont>, System::String) overrideWrites out string with specified font.
WriteTrailer()Writes out trailer of PDF document.
virtual WriteTransform(System::SharedPtr<System::Drawing::Drawing2D::Matrix>)Write the given transformation matrix to the file.
WriteWarning(System::String) overrideWrites out a warning, by default to System.err.
WriteWidth(float) overrideWrites out the width of the stroke.

Fields

FieldDescription
static PAGE_SIZE_“Page size” property key.
static VERSION“Version” property key.
static VERSION5“Version of Adobe Acrobat Reader” property value.

Deprecated

PdfDevice class is deprecated beginning from 24.3. Please use SaveAsPdf method in PsDocument class instead. In 24.6 this class will be entirely hidden False

See Also