WireSkin

References
public sealed class WireSkin : IStorable
The look of one kind of wire: colours and strokes. Colours are shared between kinds by WiresSkin; this is the resolved view for a single kind.

Constructors

WireSkin

#
public WireSkin(
Color
normal,
Colour of a wire with no selected end.
Color
selected,
Colour of a wire with both ends selected.
Color
glow,
Glow behind a wire with both ends selected.
outer,
Main wire stroke.
inner = null
Optional core stroke.
)

WireSkin

#
Deserialisation constructor. Older files also carry an unselected colour, which is ignored.
public WireSkin(
reader
)

WireSkin

#
public WireSkin(
colours,
Color
glow,
edges
)

Properties

Colours

#
public WireColours Colours { get; }

Edges

#
public WireEdges Edges { get; }

HalfSelected

#
Gets the colour at the unselected end of a wire whose other end is selected. This is a fixed blend of the normal and selected colours, not a skin setting.
public Color HalfSelected { get; }

Inner

#
Gets the description for the inner edge.
public EdgeDescription Inner { get; }

Normal

#
Gets the normal wire colour, used when both ends are unselected.
public Color Normal { get; }

Outer

#
Gets the description for the outer edge.
public EdgeDescription Outer { get; }

Selected

#
Gets the colour of a wire with both ends selected, and of the selected end of a wire with one.
public Color Selected { get; }

SelectedGlow

#
Gets the glow colour for selected wires.
public Color SelectedGlow { get; }

Methods

Fade

#
Fade the wire.
public WireSkin Fade(
factor
Fading factor.
)
Faded wire.
Explicit

IStorable.Store

#
void IStorable.Store(
writer
)
Store

Interpolate

#
Interpolate wire properties.
public WireSkin Interpolate(
other,
factor
)

Modify

#
Modify some wire skin settings. This method has been designed to support named arguments.
public WireSkin Modify(
Color?
normal = null,
Color?
selected = null,
Color?
selectedGlow = null,
outerEdge = null,
innerEdge = null
)
Modified skin.

ResolveColours

#
Resolve the appropriate colours for a wire with specific selected states at both ends.
public void ResolveColours(
sourceSelected,
Source selection state.
targetSelected,
Target selection state.
out Color
sourceColour,
Resolved source colour.
out Color
targetColour
Resolved target colour.
)