A complex IInputMode that can be used in a CanvasControl or GraphControl to edit an IGraph instance.

Namespace: yWorks.yFiles.UI.Input
Assembly: yWorks.yFilesSilverlight.Viewer (in yWorks.yFilesSilverlight.Viewer.dll) Version: 2.4.0.0

Syntax

C#
public class GraphEditorInputMode : MainInputMode
Visual Basic
Public Class GraphEditorInputMode _ Inherits MainInputMode

Remarks

This class delegates most of the work to minor IInputMode implementations. However it contains a number of properties that influence the general behavior, too.

Also this instance can be instructed to automatically adjust the content rectangle of the CanvasControl whenever the graph is changed using gestures.
This class contains a number of public methods that can be used to programmatically perform the corresponding actions, too.
Setting the NodeCreator to another instance or nullNothingnullptra null reference (Nothing in Visual Basic) changes the way nodes are created. Also the various minor IInputMode instances can be disabled, to change the behavior, too.

To enable single selection mode, disable MarqueeSelectionInputMode and set MultiSelectionRecognizer to EventRecognizers.Create(EventRecognizers.Never). Remove SelectAll and ToggleItemSelectionCommand from AvailableCommands and ExtendSelectionLeft, ExtendSelectionRight, ExtendSelectionUp, ExtendSelectionDown, SelectToPageUp and SelectToPageDown from NavigationInputMode.AvailableCommands. An example can be found in Demo.yFiles.Graph.Input.SingleSelection.

Related Reading in the Developer's Guide

An overview of this input mode is given in the section User Interaction. Additionally, specific support for graph hierarchies is discussed in Chapter 3, Graph Hierarchies.

Related Demo Applications

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

Especially see the following tutorial steps:

Inheritance Hierarchy

System..::..Object
  yWorks.Canvas.Input..::..AbstractInputMode
    yWorks.Canvas.Input..::..AbstractConcurrentInputMode
      yWorks.Canvas.Input..::..MultiplexingInputMode
        yWorks.Canvas.Input..::..MainInputMode
          yWorks.yFiles.UI.Input..::..GraphEditorInputMode

See Also