[]
        
(Showing Draft Content)

GrapeCity.Documents.Svg.GcSvgDocument.Measure

Measure Method

Measure(PointF, float)

Calculates the content bounds of an SVG document when its viewport is drawn at a specified point.

Declaration
public RectangleF Measure(PointF viewportPosition, float graphicsResolution = 96)
Public Function Measure(viewportPosition As PointF, Optional graphicsResolution As Single = 96) As RectangleF
Parameters
Type Name Description
PointF viewportPosition

The coordinates for the top-left corner of the SVG viewport.

float graphicsResolution

The graphics resolution (pixels per inch).

Returns
Type Description
RectangleF

The content bounds of the resulting image.

Measure(RectangleF)

Calculates the content bounds of an SVG document, resizing the SVG viewport to fit into a specified rectangle.

Declaration
public RectangleF Measure(RectangleF viewportRect)
Public Function Measure(viewportRect As RectangleF) As RectangleF
Parameters
Type Name Description
RectangleF viewportRect

The target rectangle for the SVG viewport.

Returns
Type Description
RectangleF

The content bounds of the resulting image.