Skip to content

ATF Tree List Editor Sample

Gary edited this page Mar 17, 2015 · 3 revisions

Table of Contents

Description

TreeListEditor is a sample editor that shows how to use various tree lists.

To learn about the programming of this sample, see Tree List Editor Programming Discussion.

ATF Features Demonstrated by TreeListEditor

  • Use of Managed Extensibility Framework (MEF) to put applications together and to extend a tree list view.
  • Use of the application shell framework, including CommandService, SettingsService, ControlHostService and WindowLayoutService.
  • Use of TreeListView and TreeListViewEditor to display a list, a checked list, a virtual list and a tree list on the main dialog's tabs.
  • Use of the ITreeListView, IItemView, and ISelectionContext interfaces to contain and select generated list items.
  • Use of the IComparer interface to sort column lists.

Run TreeListEditor

  1. Double-click the TreeListEditor.exe in \bin\wws_atf\Release.
  2. A dialog appears with a tab for every list type demonstrated.

Menu Options

  • File: choose Exit to exit TreeListEditor.
  • Edit:
    • Copy: Automatically added by ATF; does nothing in this sample.
    • Select All: Automatically added by ATF; does nothing in this sample
    • Keyboard Shortcuts: use the Customize Keyboard Shortcuts window to set up keyboard shortcuts.
    • Load or Save Settings: use the Load and Save Settings window to save current TreeListEditor application settings or load application settings from a file.
    • Preferences: set application preferences, such as command icon size.
  • Window:
    • Layouts:
      • Save Layout As...: associate the current layout with a name.
      • Manage Layouts...: show a list of layouts and manage the list.
    • Tile Horizontal: tile the list type tabs horizontally.
    • Tile Vertical: tile the list type tabs vertically.
    • Tile Overlapping: overlap the list type tabs horizontally.
    • List of checked menu items; check to display the corresponding control.

How to Use TreeListEditor

Click on the tab of the list you want to try out. The four list tabs each have a set of buttons to randomly generate flat lists of items. In addition, the Tree List tab has a button to add a hierarchical list. The Raw TreeListView Usage tab allows you to select folders to display their file hierarchy. You can remove a selected item from the Tree List and Raw TreeListView Usage tabs.

TreeListEditor Modules

Modules perform these functions:

  • Program.cs: Contains the Main program. It creates a TypeCatalog listing the ATF and internal classes used.
  • Editors.cs: Sets up the user interface elements on the List, Checked List, Virtual List and Tree List tabs.
  • RawUsage.cs: Sets up the user interface elements on the Raw TreeListView Usage tab.
  • DataGenerator.cs: Generates data for the tabs. Handles all button click events. Sets up sorting for column entries. Sets up the Property Editor.

Topics in this section

Clone this wiki locally