GeometrySettings Class |
Namespace: Ab2d.Common.ReaderSvg
public class GeometrySettings : IResourceXamlWriterSettings, INotifyPropertyChanged
The GeometrySettings type exposes the following members.
Name | Description | |
---|---|---|
GeometrySettings |
Constructor
|
Name | Description | |
---|---|---|
AdvancedOptimization |
Gets GeometrySettings with advanced optimization - many objects are combines.
Note that it is possible that because of optimization it is possible that some anomalies appear on image.
| |
BasicOptimization |
Gets GeometrySettings with some basic optimization - same objects are combines in a safe matter so there should be no anomalies.
| |
CombineAllSameIntoOneGeometry |
If true than all elements with same pen or brush are combined into one geometry regardless of the elements position.
For example we have 3 elements: A, B, C. If A and C have the same pen and brush, and CombineAllSameIntoOneGeometry is true,
than A and C are combined, regardless of the B element. If CombineAllSameIntoOneGeometry is false, than the A and C are not combined.
Set this CombineAllSameIntoOneGeometry to true if elements are not overlapping.
NOTE: CombineAllSameIntoOneGeometry is used only when CombineGeometries is set to true.
| |
CombineElementWithPenAndBrush |
By default CombineElementWithPenAndBrush is false and this means that only elements that have only pen or only brush set are defined.
If an element had both pen and brush defined it is not combined. This prevents problems when elements are overlapping - elements in front can cover some part of background elements.
If CombineElementWithPenAndBrush is set to true, than such elements are combined which leads to better performance, but can produce some anomalies if elements are overlapping.
NOTE: CombinePreserveElementsOrder is used only when CombineGeometries is set to true.
| |
CombineGeometries |
If true the geometries with the same pen and brush are combined into one geometry. This can improve the performance significantly. For fine tuning which geometries are combined see also CombineElementWithPenAndBrush and CombineAllSameIntoOneGeometry.
| |
ConvertToStreamGeometry |
If true all geometry objects are converted to StreamGeometry for better performance.
Note the if CombineGeometries is true, geometries are always converted into StreamGeometry regardless of ConvertToStreamGeometry.
| |
ForceCounterClockWisePointsOrder |
In some cases the polylines are defined in clock wise direction and this can produce a holes in the geometry. Setting this property to true prevents such problems.
| |
FullOptimization |
Gets GeometrySettings for best performance - many objects are combines.
Note that it is possible that because of optimization it is possible that some anomalies appear on image.
| |
GeometryTextExport |
Gets or sets an enum that specifies how text is exported into geometry objects (default value is GlyphRun).
| |
IgnoreRootElementSize |
Gets or sets a Boolean that specifies if the size specified with root element is not used to create geometry objects. Default value is false.
| |
IsFrozen |
If true Freeze = True is added to the geometry. This improves performance but makes objects unchangeable.
| |
NoOptimization |
Gets GeometrySettings for best flexibility (no optimization) - all the objects can be changed and also each no pens and brushes are shared between geometries so they can be changed individually.
| |
ResolveResourceKey |
Callback to customize the resource key names used in GetXaml when ResourcesCountLimit is bigger than 0.
| |
ResourcesBrushStartIndex |
Start index used with ResourcesSolidColorBrushKeyFormatString.
| |
ResourcesCountLimit |
Defines if the pens and brushed are written into resources./>
If ResourcesCountLimit is equal or less than 0 than resources are not used.
If ResourcesCountLimit is 1 than all pens and brushes are written to resources.
If ResourcesCountLimit is 2 (or higher) than all pens and brushes that are used 2 (or more) times are written to resources.
| |
ResourcesPenKeyFormatString |
Format string used to format the Pen resource keys.
Default value is "Pen{0}"
| |
ResourcesPenStartIndex |
Start index used with ResourcesPenKeyFormatString | |
ResourcesSolidColorBrushKeyFormatString |
Format string used to format the SolidColorBrush resource keys.
Default value is "Brush{0}"
|
Name | Description | |
---|---|---|
FromOptimizationPercentage |
Gets GeometrySettings from percentage (0 - means fully usable and changeable, 100 - means best performance).
Note: For values above 50 it is possible that there are some anomalies on the image because of have geometry optimization - please check the image before exporting
| |
OnPropertyChanged |
OnPropertyChanged
| |
SetDefault |
Sets default values - no optimization
| |
SetOptimizationPercentage |
Gets GeometrySettings from percentage (0 - means fully usable and changeable, 100 - means best performance).
Note: For values above 50 it is possible that there are some anomalies on the image because of have geometry optimization - please check the image before exporting.
|
Name | Description | |
---|---|---|
PropertyChanged |
Occurs when a property value changes
|