XAML Powertoys Now with Silverlight 2.0 Support
Karl on WPF has just released an update of XAML Powertoys, with new (RC0) Silverlight 2.0 support. Now if he'd just provide this as an Expression Blend add-in as well (smile). Anyway check this out..
From the Karl on WPF Blog:
"Introduction
XAML Power Toys is a Visual Studio 2008 SP1 Multi-AppDomain Add-In that empowers WPF & Silverlight developers while working in the XAML editor. Its Line of Business form generation tools, Grid tools, DataGrid and ListView generation really shorten the XAML page layout time.
It’s accessed through commands in the XAML editor context menu and the Solution Explorer item context menu.
XAML Power Toys generates .NET 3.5 SP1 WPF compliant XAML and Silverlight RC0 compliant XAML.
The day that Silverlight 2 goes RTM, I will update XAML Power Toys as required. (Currently I’m having an issue with the Silverlight ComboBox in a Silverlight Data Grid Template Column. This has nothing to do with XAML Power Toys, I just had difficulty testing the XAML spit for this usage scenario.)
Requirements
- Visual Studio 2008 with SP1
- For Silverlight Development Silverlight 2 RC0 (if your not doing Silverlight development, this is not required)
- Windows XP, Vista, Server 2003 or Server 2008
Goal
The primary goal of XAML Power Toys is to deliver tools that enable developers to quickly layout and maintain Line of Business Application forms using the UI controls that ship with Visual Studio.
You’ll notice that the below features are business form focused. This does not limit the use of the software, I’m just providing the current target project type.
Feature Set
- Create WPF or Silverlight DataGrid For Class - quickly create a WPF DataGrid complete with bindings that are easily associated with properties on the source class
- Create WPF ListView For Class - quickly create a ListView complete with bindings that are easily associated with properties on the source class
- Create Business Form For Class - quickly create a form complete with bindings that are easily associated with properties on the source class
- Create Business Form - quickly create a form complete with bindings if desired
- Show Fields List For Class - display a list of class fields similar to Microsoft Access. Allows dragging of fields to create controls
- Group Into - allows selecting one or more controls and group them inside a new parent control
- Chainsaw - Minimize Cider Designer XAML - allows selecting of one or more controls and will remove all MinWidth, MinHeight, x:Name, Name, Margin properties and will set all row and column definitions to Auto.
- Remove Margins - allows selecting one or more controls and removes the Margin property from them
- Edit Grid Column and Rows - allows selecting a grid and then add or remove rows and columns
- Set Defaults For Created Controls - allows customizing the initial properties that are set when the software creates a new control
- About Box - see the version of XAML Power Toys installed on your system
Screen Shots
Solution Explorer Content Menu
Solution Explorer Content Menu
XAML Editor Content Menu
Create Business Form For A Class
This form has drag and drop enabled. Also features a contracted view of fields.
Allows setting required properties. Data binding validation and other properties are determined from your default control settings.
StringFormat Selector
Makes selecting a StringFormat very easy. Displays the format string and example side by side.
Create Business Form
This was a version one feature. Allows creating a form when not class is available. Great for roughing out Grids and populating with controls.
Control Defaults
XAML Power Toys allows developers to determine how controls are created by the software. The developer can describe how each platforms controls are rendered. Developers can determine which data binding validation properties are set automatically and exactly which properties are set when the control is created. In the below example, I have set the WPF TextBox to have the HorizontalAlignment and VerticalAlignment properties set.
Version 3.1
- Added full support for Silverlight 2 RC0
- Changed the settings file location to the installation directory of XAML Power Toys.
- Spent many hours of testing and correcting minor issues. Want to thank Pete O’Hanlon for helping me test both XAML Power Toys and the setup program.
Videos
I’m begging every developer in the strongest possible terms, please view the below videos. They will get you up and running and productive in a very short time.
The video links require Microsoft Silverlight 1.0. If you do not have it, you will be prompted to install it when you click one of the links. After the short installation is completed, close the browser window that you did the install in and re-click the video you want to watch. You can also download it here. Windows XP or Vista required.
XAML Power Toys Installation and Setup MUST VIEW
XAML Power Toys Business Form Creation
XAML Power Toys Create Business Form For Class
XAML Power Toys New Accessories
XAML Power Toys New Create Form, DataGrid and ListView
New XAML Power Toys For Silverlight!
Overview
If you’re reading this and have not watched the above videos, please do so now, especially the Installation and Setup video. (thank you!) I won’t be repeating the content of the videos below. They are short and to the point. You’ll be up and running, saving lots of time in just a few minutes.
I’m supplying the source code for those who have authored Visual Studio Add-In’s or who want to look under the covers. Visual Studio Add-In’s are not the difficult to write, but there is a new programming API to learn.
The XAML Power Toys UI is WPF which made the coding very easy. There is one hurtle I had to get past. The XAML Power Toys Add-In does not program against any object model, it is really just manipulating text. There is no object model available in Visual Studio Add-In’s to program against which is why the Add-In has the developer selecting text in the XAML editor. The add-in then processes that selected text. The Grid Row and Column Editor does some pretty slick stuff, all without any real object model to program against. This was my first crack and working with the XMLDocument so any feedback on better techniques will be well received.
Creating Business Forms
I want to emphasize a requirement when creating a business form for a class. You must ensure that the project that contains the class has been built. If you make any changes to the source class that you want to make a form for, you must rebuild the project so that the add-in can property reflect the properties of the source class.
Cider Designer Goodness
The other day I was speaking with Mark Boulter, a Microsoft Program Manager and Technical Lead on the Cider Team about the Cider Designer and why it was programmed the way it is. He explained to me that one of the primary goals was to give developers the ability to lay a WPF form out using x,y coordinate layout and then quickly convert that layout to a table or grid layout. This conversation helped me to use the designer rather than fight it.
In the above XAML Power Toys Accessories video, I demonstrate using the Cider Designer to quickly lay a form out using control drag and drop and then use XAML Power Toys to convert the layout to a flow layout. In the video, you’ll see just how easy and fast you can lay a form out using the Cider Designer.
Installation
Ensure that you have installed Visual Studio 2008 SP1.
For Silverlight development, please install Silverlight 2 RC0. (if your not doing Silverlight development, this is not required)
Upgrading from Version 1 or 2 to 3.x? Please use Control Panel and remove XAML Power Toys before installing the package.
Upgrading from Version 3.0 to 3.x? Just run the install package.
First Time Use
The first time you use XAML Power Toys please edit and save your Control Default Settings. If you do not do this, and you access a feature that needs them, default settings will be created, saved and a dialog box will display, informing you of the action just taken. By editing and saving your Control Default Settings before using XAML Power Toys, you’ll not only avoid this intrusive dialog box, but you’ll know and can control how controls are created by XAML Power Toys.
Control Default Settings are now being saved in the installation directory so that you’ll never lose your settings again. This file is not replaced during a re-installation or during a Control Panel removal. You can also easily backup your settings.
Add-In Macro Security
In order for Visual Studio to discover XAML Power Toys, the XAMLPowerToys.Addin file must be in a path in the below dialog box. Additionally the .Addin file contains a path to the actual Add-In.
We are all developers, and I really don’t want someone changing my system registry or security settings without my knowledge and consent.
So, I have added this additional installation step that is fully explained in the above Installation and Setup video. All that is required, is that you add the path the XAML Power Toys to your Visual Studio Add-In and Macro Security settings. Now you are in full control of allowing or not allowing the Add-In to load or even be known by Visual Studio.
Downloads
After downloading the below package you must rename the extension from .DOC to .zip. This is a requirement of WordPress.com.
Download XAML Power Toys v3.1.0.2 Release Installer (944 KB)
Download XAML Power Toys v3.1.0.2 Source Code not required (471 KB)
"



