Class SvgOptions
- Namespace
- Aspose.CAD.ImageOptions
- Assembly
- Aspose.CAD.dll
The SVG file format creation options.
public class SvgOptions : ImageOptionsBase, ITextAsShapesOptions
- Inheritance
-
SvgOptions
- Implements
- Inherited Members
Examples
//Renders loaded file and saves it to SVG using (var img = Image.Load(file)) { CadRasterizationOptions cadRasterizationOptions = new CadRasterizationOptions(); SvgOptions opt = new SvgOptions();
opt.VectorRasterizationOptions = cadRasterizationOptions;
cadRasterizationOptions.DrawType = CadDrawTypeMode.UseObjectColor;
img.Save(outSvg, opt);
}
Constructors
Properties
- Callback
Gets or sets the callback that can be used to store image and font binary data as user needs
- MinimumAbsoluteNonscaledLinewidth
Lines with width in pixels less than this will be rescaled if absolute rescaling treshold
- MinimumLinewidth
Minumum width of the line relative to minimum non-rescaled linewidth. A line with width of 0 would be drawn with this width if rescaling is used ( as it is by default), lines thicker than that will be drawn thicker until they reach rescaling treshold, lines thicker than that won't be rescaled.
- MinimumRelativeLinewidthRatio
Lines with width less than image's size\minimumRelativeLinewidthRatio will be rescaled if relative rescaling treshold is used. A smaller dimension is picked as image size.
- RescaleSubpixelLinewidths
Whether sub-pixel linewidths should be rescaled. If set to true, lines thinner than a width specified by other options will be drawn thicker, asymptotically approaching the minimum width
- TextAsShapes
Gets or sets a value indicating whether text must be converted as shapes. By default text will be converted to shapes, so it won't be selectable.
- UseAbsoluteRescaling
Wether minimum non-rescaled line widh should be defined relative to whole image size (if false) or in pixels (if true). If false, use MinimumRelativeLinewidthRatio to specify maximum rate of image size to line width when line won't be rescaled up yet. If true, use MinimumAbsoluteNonscaledLinewidth to specify minimum unscaled width in pixels