GetSVGWidth
Vector graphics, SVG, Measurement
Description
Returns the intrinsic SVG width in the current measurement units without changing page content
Syntax
Delphi
Function TPDFlib.GetSVGWidth(Const SVG: WideString): Double;ActiveX
Function PDFlib::GetSVGWidth(SVG As String) As DoubleDLL
double DLGetSVGWidth(int InstanceID, const wchar_t * SVG);Parameters
| SVG | SVG source to measure |
|---|
Return values
Returns the root width, or the viewBox width when no positive intrinsic width is present, and returns 0 for invalid input
Remarks
Physical units such as pt, in, cm, and mm are converted before the current PDF Library for Delphi measurement scale is applied
Repeated measurement and drawing of the same source reuse the parsed SVG tree
The DLL DLGetSVGWidthA variant accepts text according to the configured ANSI mode