How to get Document in class GoTextNode

When I derived the CopyObject method of GoTextNode. I found that this.Document contained a GoTextNode node.

Actually it had many other nodes.

public override GoObject CopyObject(GoCopyDictionary env)

{

//The code in here

return base.CopyObject(env);

}



Yes, GoObject.Document returns the GoDocument that the object belongs to, if it is part of a document, either as a top-level object in a document layer, or as part of a GoGroup that belongs to a document.