Products | Support | Email a link to this topic. | Send comments on this topic. | Back to Introduction - All Topics | Help Version 19.0.6.22
|
Leadtools.Svg Assembly > Leadtools.Svg Namespace > SvgDocument Class : BeginUpdate Method |
public void BeginUpdate()
'Declaration
Public Sub BeginUpdate()
'Usage
Dim instance As SvgDocument instance.BeginUpdate()
- (void)beginUpdate
public void beginUpdate()
public: void BeginUpdate();
The user can modify the elements of an SVG document using EnumerateElements and update the node's elements or attributes.
After modifying the values of an SVG document using SvgNodeHandle, it may be necessary to re-calculate the document flat, render optimization and bounding rectangles (refer to SVG Size, Bounds and Flat more information). Therefore, it is best to call BeginUpdate before making any updates to the document and to call EndUpdate when finished. The engine will check during EndUpdate whether any internal state values need to be re-calculated and updated as necessary.
BeginUpdate increments an internal counter and EndUpdate decrements it. When the counter reaches 0 again, the document is updated. Therefore, the user can chain calls to BeginUpdate / EndUpdate pair and the update will only occur once at the end.