SyntaxEditor Navigable Symbol Selector Part 1

by Avatar Bill Henning (Actipro)
Monday, July 9, 2012 at 1:09pm

BlogPostBanner

Our next 2012.1 builds of SyntaxEditor for WPF and Silverlight will be adding a new ancillary control to the SyntaxEditor product:  NavigableSymbolSelector.

Navigable Symbols

Navigable symbols are symbols declared within a document to which the end user may wish to move their caret.  For instance in a language such as C#, navigable symbols would be things like type and member declarations.

A new language service has been added that can optionally be implemented.  Its only task is to return navigable symbols for a document that uses the language.  It's implemented in such a way that a multi-level hierarchy of navigable symbols can be created.

This sort of feature can be used to help drive the UI of external controls such as a type/member drop-down or even a document outline treeview.  These sort of external controls can help the end user visualize a document's structure, and the content for each item in the controls can fully utilize rich markup (images, colors, etc.).

NavigableSymbolSelector Control

The new NavigableSymbolSelector control is our implementation of a control similar to Visual Studio's type/member drop-downs.  It attaches to a SyntaxEditor instance and checks to see if the language supports the new INavigableSymbolProvider service.  If so, it uses that service to populate its drop-down(s).

A "Simple" Language Sample

Let's see how this looks in our "Simple" language sample.  We've updated one of our Getting Started series samples to implement this new service and show drop-down UI (via NavigableSymbolSelector) within a toolbar:

NavigableSymbolSelectorSimple

For our "Simple" language, we've told the NavigableSymbolSelector to show a single drop-down, which will render the list of functions declared in the editor.

Run-Time Functionality

Basically if we do these simple tasks:

  • Add a NavigableSymbolSelector control to the UI.
  • Bind it to a SyntaxEditor instance.
  • Implement the INavigableSymbolProvider language service on the current language.

We get all this functionality for free from the NavigableSymbolSelector control:

  • Automatic display of all symbols defined in the current document, that updates as document changes occur.
  • Symbols are sorted alphabetically within the drop-down.
  • As the editor caret moves, the selected symbol in the drop-down is automatically updated to be the closest enclosing or nearby symbol.
  • When the end user clicks on a different symbol in the drop-down, the caret navigates to that symbol declaration.
  • When the caret is not directly within a symbol's declaration but is near one, it will appear grayed out.  This helps the end user visualize whether they are actually in a valid symbol declaration or not.  (WPF only)

We've designed this control to work directly with the new INavigableSymbolProvider language service.  This allows any custom language to fully support the control.

Summary

These new features will be in the next 2012.1 builds of our WPF and Silverlight controls.

By default the control displays two drop-downs, and we'll show this in our next blog post, where we demonstrate the implementation of the INavigableSymbolProvider language service and usage of the new NavigableSymbolSelector control with our .NET Languages Add-on's languages.

TaskDownload TaskLiveDemo TaskBuyNow

Actipro Blog 2012 Q2 Posting Summary

by Avatar Bill Henning (Actipro)
Monday, July 2, 2012 at 10:07am

PostBannerBlogPostSummary

What We Accomplished

In this quarter we released the 2012.1 version of our WPF and Silverlight controls.  This version updated our WPF products to target .NET 4.0 or later, and updated our Docking/MDI's Prism integration add-on to work with the latest Prism v4.1. 

The 2012.1 versions introduced a new Micro Charts product that is a set of charts that visualize quantitative data and are designed to render clearly in compact spaces.  They are extremely useful for data display within dashboards, reports, and grids.

SyntaxEditor also saw a lot of updates including highlighting style borders, IntelliPrompt code snippet support, current line highlight enhancements, .NET Languages Add-on automated LINQ IntelliPrompt, and overall memory usage reductions.

What’s Coming Next

SyntaxEditor has a new control being added soon that allows you to easily add VS type/member drop-down functionality for your own languages, with built-in support for our .NET Languages Add-on.  Micro Charts has a new control being added for heat map generation.  We'll detail both of these in upcoming posts.

We will be continuing to work on development of our Micro Charts product for the WinRT (Windows 8 "Metro" style) platform, and have some other new features and controls for all platforms in the works as well.

Blog Post List

Here is a quick categorized list of useful blog postings made in this quarter.

Product Development

Micro Charts Series

Product Releases and Purchase Options

Micro Charts Part 15 - Series Visibility

by Avatar Bill Henning (Actipro)
Monday, June 25, 2012 at 8:02am

BlogPostBanner

In the previous post for our new Micro Charts product (currently available for WPF and Silverlight), we talked about live data display, such as for stock tickers.  In today's post, we'll look at how the series visibility can be used to have show or hide a series on a chart.

The visibility of a series is visible by default, but it can be set so that the series is not rendered on the chart. This property can be bound so that the series can be hidden or shown by user input. This feature can be very useful when displaying a chart that contains several different series. The series can then be shown or hidden in order to avoid a cluttered look and more closely compare specific series.

SeriesVisibility

Above is an example of a navy blue bar series with its visibility property bound to a checkbox.  It is displayed in the left screenshot and hidden in the right.

This concludes our introduction to our new Micro Charts product.  Please visit the first post to see the full blog post index of this series.