The L_SvgRenderOptions structure provides options for rendering an SVG document to a target device.
struct L_SvgRenderOptions
{
L_UINT StructSize;
L_BOOL UseBackgroundColor; // Use the background color.
L_COLORREF BackgroundColor; // Color to fill the background of the SVG. Only used when UseBackgroundColor is true and Bounds is not empty or has zero width or height
L_RECTD Bounds; // Bounds of the SVG. Only used when UseBackgroundColor is true. Use the same value from L_SvgGetBounds
L_RECTD ClipBounds;
L_MATRIX Transform;
L_SvgRenderFlags RenderFlags;
};
typedef struct L_SvgRenderOptions L_SvgRenderOptions;
Size of this structure. Use sizeof (L_SvgRenderOptions).
TRUE to use BackgroundColor color to fill the background of the transformed destination rectangle; otherwise, FALSE.
The color used to the fill the background of the transformed destination rectangle. Default value is "white".
SVG document do not have a background color. Use this property to fill Bounds (final transformation applied) with a color.
Will only be used if UseBackgroundColor is TRUE.
The background rectangle. Default value is 0, 0. Transform will be applied to this rectangle.
The clipping rectangle in pixel coordinates. Default value is 0, 0.
The engine will apply this clipping into Bounds to exclude all or parts of the objects that do not fit.
The transformation set in Transform will not be applied to this rectangle.
If this value has 0 width and height then the whole document will be rendered and no clipping performed.
The transformation to be applied when rendering the document. Default value is Identity.
This is an L_MATRIX structure that you can use to apply zooming, translation and rotation to the final document.
The value of Transform will be applied to Bounds to calculate the final destination rectangle in pixels.
Extra render options. Possible values are listed in table below.
Value | Meaning |
---|---|
(0x0000) L_SvgRenderFlags_Default | Default rendering. |
(0x0001) L_SvgRenderFlags_EnhanceThinLines | Enhances the strokes thickness if the transformation causes lines to have size less than 1 pixel. |
Options for rendering an SVG document to a target device.
For more information on rendering SVG documents, refer to SVG Rendering.