Northwoods.Go Assembly > Northwoods.Go Namespace : GoTextNode Class |
'Declaration <SerializableAttribute()> Public Class GoTextNode Inherits GoNode Implements IGoCollection, IGoGraphPart, IGoIdentifiablePart, IGoLabeledNode, IGoLabeledPart, IGoNode
[SerializableAttribute()] public class GoTextNode : GoNode, IGoCollection, IGoGraphPart, IGoIdentifiablePart, IGoLabeledNode, IGoLabeledPart, IGoNode
If you don't need all four ports, you can remove ones you don't want by setting the corresponding property to null.
You can change the background from a light-gray rectangle by setting the Background property to be some other object. In order for the text to fit nicely within the shape, you may need to set the TopLeftMargin and BottomRightMargin properties to larger values. This is particularly true if the new shape is a GoEllipse or a polygon that has a small rectangular area in it.
When AutoResizes is false, the Label is sized to fit inside the bounds of the Background, minus the margins. The label (a GoText) is automatically wrapped and clipped.
To make it easier to initialize or modify the shape's brush and/or pen, the Shape property casts the Background to a GoShape. If you make the background a group of various kind of objects, you may want to override the Shape property to return the particular shape inside the group that you consider to be the most prominent.
The text string is normally multiline and not editable, but you can change those and other properties by setting the Label's properties.
Setting the Shadowed property for this node actually sets that property on the Background object. Although the Background object is normally a GoRectangle, it could be any kind of GoObject.
System.Object
Northwoods.Go.GoObject
Northwoods.Go.GoGroup
Northwoods.Go.GoNode
Northwoods.Go.GoTextNode
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2