GoDiagram Win Reference
LayoutIcon Method

Resize the Icon so that it meets the MinimumIconSize requirement.
Syntax
'Declaration
 
Protected Overridable Sub LayoutIcon() 
protected virtual void LayoutIcon()
Remarks
This only happens when GoObject.AutoRescales is true for the Icon. MinimumIconSize is computed to be large enough to hold all of the ports. If you want the Icon to automatically shrink in size when ports are removed, override this method as follows: protected override void LayoutIcon() { GoObject icon = this.Icon; if (icon != null && icon.AutoRescales) { SizeF minIconSize = this.MinimumIconSize; float newW = minIconSize.Width; float newH = minIconSize.Height; icon.Bounds = new RectangleF(icon.Left - (newW - icon.Width)/2, icon.Top - (newH - icon.Height)/2, newW, newH); } }
Requirements

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

See Also

Reference

GoGeneralNode Class
GoGeneralNode Members

 

 


© 2015. Northwoods Software Corporation. All Rights Reserved.

Send Feedback