chevron_right Demos chevron_right WebGL Selection Styles
Related demos
Book a live Demo

Live Demo — yFiles in Action

30–45 min | Online | No install required

For Developers, Product Mangers & Executives

  • Interactive graph visualization in real time
  • Integration example
  • Live Q&A and next step recommendations

30–45 minutes | 1:1 or team session | Online (Zoom / Teams)

No install required | We show live code

Book a free live demo

Live Demo — yFiles in Action

30–45 min | Online | No install required

For Developers, Product Mangers & Executives

30–45 minutes | 1:1 or team session | Online (Zoom / Teams)

No install required | We show live code

Book a free live demo

Style Properties

Style Pattern

The style pattern defines the basic rendering of the selection visualization.

Color Scheme

There are two configurable colors for a WebGL selection: primary and secondary.
The primary color is used for solid strokes, dash patterns, and as the inner stroke for border patterns.
The secondary stroke is used as the background for dashed patterns and as the outer stroke for border patterns.

Thickness and Margins

Transition and Animation

If transition is activated, the selection is activated and deactivated in a smooth manner.
Dash animation activates a "marching ants" animation for dashed or striped styles.
Easing configures the course of an animation.

Zoom Policy

The zoom policy determines in which coordinate system the selection visualizations are rendered.
Mixed applies a heuristic in which world coordinates are used at large zoom levels and view coordinates are used at small zoom levels.

WebGL Selection Styles Demo

This demo shows the available selection styles for nodes, edges, and labels in WebGL rendering.

In WebGL, selections can be configured in various ways: There are multiple patterns to choose from, and colors, thickness, and margins are configurable. Additionally, selections can be activated and deactivated using animated transitions, and for the appropriate selection styles, a "marching ants" animation is available, too.

Things to Try

In this demo, the same selection style is used for all graph elements. This is only a configuration in the demo, since with the API the styles for the different element types can be configured individually. See the updateSelectionStyles function in the demo source code.