Property ActiveTextStyle
- Namespace
- VectorDraw.Professional.vdObjects
- Assembly
- VectorDraw.Professional.dll
ActiveTextStyle
Get/Set the active vdTextstyle of the document. vdText, vdMText, vdAttrib , vdAttribDef objects assign this style as default when the setDocumentDefaults() method is called.
public vdTextstyle ActiveTextStyle { get; set; }
Property Value
Examples
Changes the ActiveTextStyle and create a new vdText that reference to this style.
//create a new text style with name "MyNewTextStyle" and make it as active.
vdTextstyle texttyle = doc.TextStyles.Add("MyNewTextStyle");
doc.ActiveTextStyle = texttyle;
//create a new text entitity
vdText txt = new vdText();
//select the document that the text is reference to.
txt.SetUnRegisterDocument(doc);
//select the default active properties of the document object for the entity
txt.setDocumentDefaults();
Console.WriteLine(txt.Style.Name);//the output will be "MyNewTextStyle"
Remarks
This property is used when setDocumentDefaults() is called.
Default value: Standard
Raizes the OnBeforeModifyObject event and the OnAfterModifyObject event.