An abstract base class that makes it possible to easily implement a custom IPortStyle.

Namespace: yWorks.yFiles.UI.Drawing
Assembly: yWorks.yFilesNET.Viewer (in yWorks.yFilesNET.Viewer.dll) Version: 4.1.0.1 (4.1.0.1)

Syntax

C#
public abstract class SimpleAbstractPortStyle : IPortStyle, 
	IVisualStyle<IPort>, IModelItemInstaller<IPort>, ICloneable
Visual Basic
Public MustInherit Class SimpleAbstractPortStyle _
	Implements IPortStyle, IVisualStyle(Of IPort),  _
	IModelItemInstaller(Of IPort), ICloneable

Remarks

Only Paint(IPort, Graphics, IRenderContext) and GetBounds(IPort, ICanvasContext) need to be implemented by subclasses.

This implementation differs from the straightforward IPortStyle implementation in that there is no visible separation between the IVisualStyle<(Of <(<'TModelItem>)>)> and its IStyleRenderer<(Of <(<'TModelItem, TStyle>)>)>. Instead the renderer used by the base class is fixed and delegates all calls back to the style instance.

Related Demo Applications

The following programming samples are available: Also see the yFiles.NET tutorials for step by step introductions.

Especially see the following tutorial steps:

Inheritance Hierarchy

System..::..Object
  yWorks.yFiles.UI.Drawing..::..SimpleAbstractPortStyle

See Also