yFiles for Silverlight Developer's Guide

Legal Notice

Table of Contents

Changes From Previous Edition
Developer's Guide Enhancements
New Features of yFiles for Silverlight 2.4
1. Preface
Diagrams
Benefits and Problems
From Diagrams to Graphs
Graph-related Problems
About yFiles for Silverlight
What it is
What it's not
Application Domains
2. Introducing yFiles for Silverlight
yFiles for Silverlight Library Components
yFiles for Silverlight Algorithms
yFiles for Silverlight Viewer
Programming Samples, Tutorials, and Further yFiles for Silverlight Resources
How to Read this Developer's Guide
Where to Find Things in yFiles for Silverlight
yFiles for Silverlight Assemblies
3. Getting Started
Working with Graphs
Introduction
Nodes
What is a Node?
Creating Nodes
Default Node Properties
Reading Node Properties
Setting Node Properties
Node Labels and Ports
Removing Nodes
Edges
What is an Edge?
Creating Edges
Default Edge Properties
Reading Edge Properties
Setting Edge Properties
Edge Labels
Edge Bends
Removing Edges
Automatic Port Removal
Labels
What is a Label?
Adding Labels to Graph Elements
Label Layout
Positioning Labels
Default Label Properties
Reading Label Properties
Setting Label Properties
Removing Labels
Ports
What is a Port?
Adding Ports to Nodes
Default Port Properties
Reading Port Properties
Setting Port Properties
Removing Ports
Customizing Styles
What is a Style?
Setting Styles
Setting a Default Style
Setting a Style upon Creation
Setting a Style after Creation
Grouping
What is Grouping?
Enabling Grouping on the Graph
Retrieving the Grouped Graph
Building a Grouped Graph
Default Group Node Properties
Changing the Hierarchy
Re-parenting a Child Node
Removing a Group Node
Folding
What is Folding?
Enabling Folding
Creating the Folding Manager
Creating the Managed View
Displaying the Folded Graph
Working with Folding
Expanding and Collapsing Group Nodes
Mapping Representatives to Master Elements
Accessing the Master Graph
Dummy Elements
Editing Collapsed Nodes
Managing the View
Introduction to the View
Fitting the Bounds
Fitting the Viewport
Fitting Both Bounds and Viewport
Basic Interaction
Introduction to Interaction
Using Pre-defined Input Modes
Enabling Interactive Navigation
Enabling Interactive Editing
Undo and Clipboard
Enabling Undo Support
Enabling Clipboard Support
Customizing Undo and Clipboard Operations
Adding New Operation Types
Automatic Graph Layout
What is Layout?
Hierarchic
Organic
Orthogonal
Circular
Tree
Applying a Layout
Calling a Layout on the Graph
Calling a Layout on the Graph Control
Calling a Layout on the Layouter
Basic Input and Output
Basics of Input and Output
Enabling Input and Output for Interaction
Using Input and Output
Customizing Input and Output
4. Displaying and Editing Graphs
Model-View-Controller Paradigm
Graph Structure
Look-up Support
Working with the Graph Structure
Look-up Support
Working with DefaultGraph
Visual Representation of Graph Elements
Styles
Node Styles
Edge Styles
Port Styles
Label Styles
Working with Styles
Creating Custom Styles
Style Renderers
Node Style Renderers
Edge Style Renderers
Port Style Renderers
Label Style Renderers
Port Support
Port Location Model Parameter
Label Support
Label Model Parameter
Node Label Models
Edge Label Models
Generic Label Model
Styles-related Features
Arrows
Rendering-related Features
Bridges
View Implementations
Class GraphControl
General Features
Command Support
Scene Graph Addendum
Application-level Features
Class CanvasControl
General Features
Command Support
World and View Coordinates
Content Rectangle and Viewport
Hit-testing
Canvas Redraw
Application-level Features
Scene Graph and Canvas Objects
Class GraphOverviewControl
User Interaction
Class GraphViewerInputMode
Element States in Interactions
Interaction Events
Interaction Customization
Class GraphEditorInputMode
General Features
Element States in Interactions
Interaction Events
Interaction Customization
Interactive Editing of Orthogonal Edges
Interactive Snapping of Graph Elements
Edge-to-Edge Connections
Class GraphCommands
Class MainInputMode
Class MoveViewportInputMode
Customizing Input Modes
Customizing User Interaction Behavior
Decorating the Look-up
Tabular Data Presentation
Concepts
Table Model
Working with the Table Model
Visual Representation
Rows and Columns
User Interaction
Interaction Customization
Hit-testing
Tutorial Demo Code
Automatic Layout
Tutorial Demo Code
Printing a Canvas's Content
Scaling and Poster Printing
Animations for Graph Elements
Animation Framework
Animations
Tutorial Demo Code
Data Binding for Graph Structures
Data Binding Support Overview
Choosing a Suitable Data Binding Class
Class TreeSource
Binding Properties
Building the Graph Structure
Class GraphSource
Binding Properties
Building the Graph Structure
Class AdjacentNodesGraphSource
Binding Properties
Building the Graph Structure
Class AdjacentEdgesGraphSource
Binding Properties
Building the Graph Structure
Common Features
Hierarchical Organization of General Graphs
Tutorial Demo Code
5. Graph Hierarchies
Concepts
Grouping
Folding
Working with Graph Hierarchies
Folding Characteristics
Folding-related State Across Views
Managing Graph Hierarchies
Grouping Support in DefaultGraph
Class GroupedGraph
Look-up Modifications
Interface IHierarchy
Class FoldingManager
Look-up Modifications
Interface IFoldedGraph
Converters and Callbacks
Visual Representation of Graph Elements
View Implementations
User Interaction
Class GraphEditorInputMode
Folding Support
Class NavigationInputMode
Class GraphCommands
6. Input and Output
Graph Exchange Format GraphML
Reading and Writing Graph Structure Data Using GraphML
What GraphML Looks Like
Working with the GraphML File Format
GraphML Attributes
Reading and Writing Additional Data
Simple vs. Structured Type Support
Reading and Writing Data Using IMappers as Data Holders
General (De)Serialization Support
Custom Serialization and Deserialization
Tutorial Demo Code
Exporting the Canvas's Content
Bitmap-based Image Export
7. API Concepts
Look-up Mechanism
Benefits
Look-up Chaining
Customizing Look-up Behavior
Binding Data to Graph Elements
Mapping Data to Graph Elements
Tutorial Demo Code
User Tags
8. Using yFiles for Silverlight Algorithms Functionality
Connecting Graph Models
Class CopiedLayoutIGraph
Class YGraphAdapter
Layout Modules
Layout Morphing
Class LayoutExecutor
9. Graph Analysis
Using yFiles Graph Analysis Functionality
Analysis Algorithms
Quickly Checking for Graph Characteristics
Binding Data to Graph Elements
Breadth-First Search
Depth-First Search
Graph Connectivity
Shortest Paths
Centrality Measures
Spanning Trees
Transitivity
Trees
10. Automatic Graph Layout
Layout Algorithms
Advanced Layout Concepts
Using yFiles Layout Functionality
Layout Infrastructure
IGraph-related Adapter Mechanisms
Concepts
The Layout Stages Concept
Default Compound Layout Process
Providing Supplemental Layout Data
Abort Mechanism for Layout Calculations
Advanced Layout Concepts
Grouped Graphs
Setup for Layout
Port Constraints
Setup for Layout
Tutorial Demo Code
Port Candidates
Matching Port Candidates
Setup for Layout
Tutorial Demo Code
Modeling Enhanced Port Constraints Using Port Candidates
Setup for Routing
Edge/Port Grouping (Bus-Style Edge Routing)
Setup for Layout
Tutorial Demo Code
Partition Grid
Setup for Layout
Node Halos
Incremental Layout
Use Cases
Related Concepts
Layout Stages
Tutorial Demo Code
Class ComponentLayouter
Supplemental Layout Data
Layout Options
Advanced Layout Techniques
Tutorial Demo Code
Class GraphLayoutLineWrapper
Layout Options
Major Layout Algorithms
Circular Layout
Hierarchical Layout
Organic Layout
Orthogonal Layout
Tree Layout
Radial Layout
Domain-Specific Layout Algorithms
Family Tree Layout
Supplemental Layout Data
Layout Options
Circular Layout
Supplemental Layout Data
Layout Options
Layout Style
Returning Circle Indices
Partition Arrangement Options
Tree Arrangement Options
Label Handling
Node Label Awareness
Node Halos
Tutorial Demo Code
Configuration Hints
Compact Layout
Hierarchical Layout Style
About the Style
Terminology
Application Areas
Relevant Classes
Class IncrementalHierarchicLayouter
Layout Options
Drawing Style Options
Non-incremental Layout Mode
Layer Assignment Options
Node Order Options
Incremental Layout Mode
Use Cases
Specifying Hints
Constrained Layer Assignment
Constrained Node Sequencing
Emphasizing Critical Paths
Advanced Layout Concepts
Integrated Labeling
Node Label Awareness
Port Constraints
Port Candidates
Edge/Port Grouping (Bus-style Edge Routing)
Node Halos
Layout of Grouped Graphs
Related Classes
Class SimplexNodePlacer
Applicable Layout Stages
Swimlane Layout
Tutorial Demo Code
Supplemental Layout Data
Related Layout Algorithms
Organic Layout Style
About the Style
Application Areas
Relevant Classes
Class SmartOrganicLayouter
Drawing Style Options
Algorithm Execution Options
Incremental Layout
Layout of Grouped Graphs
Group Node Handling
Partitioned Layout
Label Handling
Node Label Awareness
Node Halos
Configuration Hints
Quality Versus Time
Compactness
Overlap Removal
Tutorial Demo Code
Supplemental Layout Data
Related Layout Algorithms
Interactive Organic Layout
General Usage
Setup
State
Polling for Results
Interaction
Supplemental Layout Data
Layout Options
Output Restrictions
Orthogonal Layout
Supplemental Layout Data
Layout Options
Orthogonal Layout of Grouped Graphs
Label Handling
Integrated Labeling
Node Label Awareness
Related Classes
Applicable Layout Stages
Tutorial Demo Code
Configuration Hints
Quality Versus Time
Orthogonal Layout of Grouped Graphs
Supplemental Layout Data
Layout Options
Label Handling
Integrated Labeling
Node Label Awareness
Related Classes
Applicable Layout Stages
Tutorial Demo Code
Directed Orthogonal Layout
Supplemental Layout Data
Layout Options
Advanced Layout Concepts
Directed Edges
Edge/Port Grouping (Bus-style Edge Routing)
Integrated Labeling
Node Label Awareness
Node Halos
Related Classes
Applicable Layout Stages
Tutorial Demo Code
Compact Orthogonal Layout
Layout Options
Applicable Layout Stages
Tutorial Demo Code
Tree Layout
Advanced Layout Concepts
Sorting Child Nodes
Enhancing the Layout Process
Tutorial Demo Code
Directed
Supplemental Layout Data
Layout Options
Advanced Layout Concepts
Node Halos
Integrated Labeling
Incremental Layout
Balloon
Supplemental Layout Data
Layout Options
Advanced Layout Concepts
Node Halos
Integrated Labeling
Incremental Layout
Horizontal/Vertical
Supplemental Layout Data
Layout Options
Compact
Supplemental Layout Data
Layout Options
Generic Tree Layout
Supplemental Layout Data
Layout Options
Node Placer Implementations
Advanced Layout Concepts
Integrated Labeling
Port Constraints
Node Halos
Incremental Layout
Grouping Support
Tutorial Demo Code
Radial Layout Style
About the Style
Terminology
Class RadialLayouter
Layout Options
Drawing Style Options
Advanced Layout Concepts
Node Halos
Supplemental Layout Data
Partial Layout
About the Concept
Class PartialLayouter
Subgraph Components
Edge Routing
Drawing Style Options
Algorithm Execution Options
Support for Grouped Graphs
Configuration Hints
Consider Node Alignment
Subgraph Component Placement
Tutorial Demo Code
Supplemental Layout Data
Multi-page Layout
About the Concept
Terminology
Relevant Classes
Class MultiPageLayouter
Setup for Layout
Layout Options
Algorithm Execution Options
Related Classes and Interfaces
Class MultiPageLayout
Interface IElementFactory
Tutorial Demo Code
Supplemental Layout Data
Edge Routing Algorithms
Organic Routing
Orthogonal Routing
Organic Edge Routing
Routing Options
Enhancing the Routing Process
Supplemental Layout Data
Tutorial Demo Code
Polyline Edge Routing
About this Algorithm
Relevant Classes
Class EdgeRouter
Routing Options
Advanced Routing Concepts
Label Awareness
Port Constraints
Port Candidates
Edge/Port Grouping (Bus-style Edge Routing)
Node Halos
Routing in Grouped Graphs
Routing in Partition Grids
Incremental Routing
Related Classes
Monotonic Edge Paths
Supplemental Layout Data
Orthogonal Edge Routing
Supplemental Layout Data
Routing Options
Monotonic Edge Paths
Advanced Routing Features
Port Constraints
Port Candidates
Incremental Routing
Label Handling
Node Label Awareness
Enhancing the Routing Process
Tutorial Demo Code
Channel Edge Routing
Supplemental Layout Data
Routing Options
Affected Edges
Advanced Routing Features
Port Constraints
Port Candidates
Incremental Routing
Related Classes
Applicable Layout Stages
Tutorial Demo Code
Orthogonal Bus-style Edge Routing
About this Algorithm
Terminology
Relevant Classes
Class BusRouter
Setup for Routing
Routing Options
Incremental Routing
Related Classes
Class BusDescriptor
Class BusRepresentations
Applicable Layout Stages
Advanced Routing Features
Port Constraints
Port Candidates
Configuration Hints
Esthetic Buses
Tutorial Demo Code
Supplemental Layout Data
Automatic Label Placement
Labeling Scenarios
Label Models
Preferred Placement of Edge Labels
Generic Labeling
Using an Alternate Label Model
Supplemental Layout Data
Integrated Labeling
Internal representation of label layout
Tutorial Demo Code
11. Underlying Graph Model of the yFiles Graph Analysis Algorithms
Basic Algorithms Graph Structure
Clear Responsibilities
Accessing Graph Elements
Storing Elements
Binding Data to Graph Elements
A Word on Subclassing Graph Elements
12. Working with the Algorithms Graph Structure
Creating Graphs and Graph Elements
Graph Structure Functionality
More About Class Graph
Graph Elements
Class Node
Class Edge
Complexity
Advanced Topics
Hiding Graph Elements
Copying a Graph
Events and Listeners
Structural Changes
Iteration Mechanisms
Language Constructs for Iteration
Cursors
Iteration and Element Removal
Alternative Iteration Techniques
Containers
High-Level Features
Low-Level Features
Binding Data to Graph Elements
Maps and Data Providers
Default Map Implementations
Creating Customized Data Accessors
Notes
13. Underlying Graph Model of the yFiles Layout Algorithms
Layout Architecture
Graph Structure Enhancements
Positional and Dimensional Information
Advanced Topics
Copying a LayoutGraph
Invoking a Layout Algorithm Using Buffered Layout
Class BufferedLayouter
Working with the Layout Graph Structure
Grouped Graph Setup for Layout
A. Obfuscation
Why Obfuscation Matters
Name Obfuscation and its Benefits
Obfuscating a yFiles for Silverlight-based Application
Obfuscation Requirements
Obfuscation Excludes
Obfuscation Tools
Using Dotfuscator
Dotfuscator Configuration File
B. License Mechanism
yFiles for Silverlight License Files
General Concept
Development vs. Distribution License Files
Pre-installed License File in Evaluation Distribution
Separate License Files for Purchased yFiles for Silverlight Packages
Including a License File
Developing with Visual Studio Designer
Programming Samples and Tutorials
Glossary