GoDigram for .NET Framework and .NET Core
Northwoods.Go Namespace / GoBasicNode Class / CreatePort Method
Example
In This Topic
    CreatePort Method (GoBasicNode)
    In This Topic
    Create and initialize a GoPort.
    Syntax
    protected virtual GoPort CreatePort()

    Return Value

    a GoPort that is a shape with no particular link spot for links either coming into or going out of the port
    Example
    If you override this method, you may want the definition to do some of the things that the standard definition does:
    protected virtual GoPort CreatePort() {
      GoPort p = new GoPort();
      p.Style = GoPortStyle.Ellipse;  // black circle/ellipse
      // use custom link spots for both links coming in and going out
      p.FromSpot = GoObject.NoSpot;
      p.ToSpot = GoObject.NoSpot;
      p.Size = new SizeF(7, 7);
      return p;
    }
    See Also