DrawParams Class Documentation

class DrawParams

Namespace:datalogics_interface

Detailed Description

Settings for rendering PDF pages as images.

This is used for rendering PDF pages to images, such as PNG or JPG files, to export to separate files or to send to a printer.

Constructor & Destructor Documentation

DrawParams

DrawParams()

Construct default DrawParams.

Initializes with DeviceRGB color space, relative colorimetric render intent, no smoothing, no draw flags, and no cancel or progress callbacks.

~DrawParams

~DrawParams()

Member Function Documentation

get_bypass_copy_perm

bool get_bypass_copy_perm()

Returns:

bool

Bypass copy permissions. Only used when drawing to a bitmap.

get_dest_rect

Rect get_dest_rect()

Returns:

Rect

The rectangle of the bitmap in device space coordinates.

Only used when drawing to a bitmap.

get_enable_black_point_compensation

bool get_enable_black_point_compensation()

Returns:

bool

Enable/disable black point compensation.

get_enable_thin_line_heuristics

bool get_enable_thin_line_heuristics()

Returns:

bool

Enable/disable thin line adjustments when drawing rectangles.

get_icc_profile

ColorProfile get_icc_profile()

Returns:

ColorProfile

The ICC Profile of the colorspace to be used for rendering, from a known value.

NOTE: The ICCProfileCustomPath must not be set for this property to be used. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.

get_icc_profile_custom_path

std::string get_icc_profile_custom_path()

Returns:

std::string

The ICC Profile of the colorspace to be used for rendering, from a custom file path.

NOTE: The ICCProfile is ignored when this property is a non-empty string. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.

get_matrix

Matrix get_matrix()

Returns:

Matrix

The matrix to concatenate onto the default page matrix.

Useful for converting from page to window coordinates and for scaling.

get_render_intent

RenderIntent get_render_intent()

Returns:

RenderIntent

Default rendering intent is RelColorimetric (relative colorimetric). Only used when drawing to a bitmap.

get_smooth_flags

SmoothFlags get_smooth_flags()

Returns:

SmoothFlags

Smoothing flags. Only used when drawing to a bitmap.

get_update_rect

Rect get_update_rect()

Returns:

Rect

The rectangle specifying the area to draw.

A rectangle represented by the coordinates of its four sides. If unset (degenerate), the page's CropBox is used instead.

set_bypass_copy_perm

void set_bypass_copy_perm(bool value)

Parameters

value: bool

Returns:

void

Bypass copy permissions. Only used when drawing to a bitmap.

set_color_space

void set_color_space(ColorSpace & color_space)

Parameters

color_space: ColorSpace &

the color space in which the bitmap data is represented

Returns:

void

The color space in which the bitmap data is represented.

Must be one of DeviceGray, DeviceRGB, DeviceRGBA, DeviceCMYK, Lab, or LabA. Only used when drawing to a bitmap.

set_dest_rect

void set_dest_rect(const Rect & rect)

Parameters

Returns:

void

The rectangle of the bitmap in device space coordinates.

Only used when drawing to a bitmap.

set_enable_black_point_compensation

void set_enable_black_point_compensation(bool value)

Parameters

value: bool

Returns:

void

Enable/disable black point compensation.

set_enable_thin_line_heuristics

void set_enable_thin_line_heuristics(bool value)

Parameters

value: bool

Returns:

void

Enable/disable thin line adjustments when drawing rectangles.

set_flags

void set_flags(DrawFlags flags)

Parameters

flags: DrawFlags

Returns:

void

Drawing flags.

set_icc_profile

void set_icc_profile(ColorProfile profile)

Parameters

profile: ColorProfile

Returns:

void

The ICC Profile of the colorspace to be used for rendering, from a known value.

NOTE: The ICCProfileCustomPath must not be set for this property to be used. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.

set_icc_profile_custom_path

void set_icc_profile_custom_path(const std::string & path)

Parameters

path: const std::string &

Returns:

void

The ICC Profile of the colorspace to be used for rendering, from a custom file path.

NOTE: The ICCProfile is ignored when this property is a non-empty string. The profile must be compatible with the ColorSpace property value, which can't be set to ICCBased either.

set_matrix

void set_matrix(const Matrix & matrix)

Parameters

Returns:

void

The matrix to concatenate onto the default page matrix.

Useful for converting from page to window coordinates and for scaling.

set_optional_content_context

void set_optional_content_context(OptionalContentContext & context)

Parameters

context: OptionalContentContext &

The optional content context, or NULL for the default.

Returns:

void

The optional-content context to use for visibility state information.

Set to NULL to use the document's current states in the default context.

set_render_intent

void set_render_intent(RenderIntent intent)

Parameters

intent: RenderIntent

Returns:

void

Default rendering intent is RelColorimetric (relative colorimetric). Only used when drawing to a bitmap.

set_smooth_flags

void set_smooth_flags(SmoothFlags flags)

Parameters

Returns:

void

Smoothing flags. Only used when drawing to a bitmap.

set_update_rect

void set_update_rect(const Rect & rect)

Parameters

Returns:

void

The rectangle specifying the area to draw.

A rectangle represented by the coordinates of its four sides. If unset (degenerate), the page's CropBox is used instead.