Technology Preview--Windows Forms Technology Preview March 2004

来源:互联网 发布:麦可思数据公司地址 编辑:程序博客网 时间:2024/05/19 20:47

Overview

Over the next several months, Microsoft will release more frequent builds of Visual Studio for our customers. These "Technology Previews" are intended to help customers plan for future projects, evaluate Microsoft's development tools, and provide feedback to Microsoft throughout the development process. They are not "alpha" or "beta" quality – they are truly interim builds and as such, minimal effort is made to ensure their stability and quality. In some cases, features may simply work, while in others they may be quite unstable.

The document provides information on Windows Forms features in the Technology Preview that were not in the alpha build.

Data Binding

DataConnector and DataNavigator

These controls replace the DataContainer control. The DataConnector is a component that replaces the binding indirection and the DataNavigator is a control which offers the VCR controls from the DataContainer. The reason that the container model was dropped for binding indirection is that users often create their UI and then decide to bind it to data. Encapsulating the indirection code in a container required users to re-layout a Form when all to bind to data.

fig. 1

fig. 2

BindingList<T>

This is a generic implementation of the IBindingList interface which allows users to create a bindable list of any object type with just one line of code.

New Data Binding Design Experience

The editors for DataSource and DataMember properties have been redesigned. The DataSource editor now allows users to add new project data sources and it also allows binding to anything in the project data sources window.

fig. 3

DataGridView Control

The DataGridView control replaces the GridView control that was in the alpha build.

New DataGridView Design Experience

A new set of smart tag items have been added to the DataGridView. This allows select properties to be quickly set, including the DataSource, and also allows the column editor dialog to be launched.

fig. 4

The column editing experience has been simplified and streamlined since the alpha.

fig. 5

 

fig. 6

Advanced Row-Level Customization

Row template support has been added to allow for advanced customization scenarios like the inbox list in Outlook 2003. This is exposed through the DataGridView.RowTemplate property.

Clipboard Copy Support

Automatic support for copy operations has been added to the DataGridView. Selecting a row and hitting ctrl+c will copy the row to the clipboard. This can be customized using the ClipboardCopyMode property on DataGridView.

LinkLabel Columns / Cells

A new link cell / column type has been added to the DataGridView. This is very similar to a button cell, except that it is rendered like an HTML hyperlink. This new column type can be added through the "Edit Columns" or "Add Column" dialogs.

ToolTip Support

Default tooltip support has been added to the DataGridView. Each cell has a string ToolTipText property. Automatic tooltips can be disabled using the DataGridView.ShowCellTooptips property if more advanced tooltip support is desired.

Scrolling Improvements

Support for automatic horizontal and / or vertical scrolling during drag selections has been added.

ToolStrip, MenuStrip and StatusStrip Controls

These controls replace the WinBarXXX controls that were in the alpha build.

Professional Look and Feel

ToolStrip, MenuStrip and StatusStrip all support a new professional look and feel. This is in addition to the system look and feel. Using the new RenderMode property, the look and feel of ToolStrips, MenuStrips and StatusStrips can be quickly changed.

fig. 5

New Design Experience

The design experience for ToolStrip, MenuStrip and StatusStip has been overhauled since the alpha build. The new design is similar to the menu editor from Visual Studio .net 2003. Other improvements include item type morphing (changing a button item to a combobox item) and smart tag support for common actions and properties.

fig. 6

Rafting and Drag Docking

ToolStrips, MenuStrips and StatusStrips have added support for rafting (relocating a toolbar while still docked to the same side of a container) and drag docking. Rafting behavior can be modified using the Raft property.

fig. 7

Menu Merging

Automatic menu merging support has been added for MDI scenarios. Because of this, MenuStrips can act as full replacements to the MainMenu control when using MDI.

MaskedTextBox Control

This control is new since the alpha build. The control supports a mask language which is similar to Access and the VB6 MaskEd control. Support for TypeValidation is also included. This allows users to set the desired output data Type for the control and the control will try and parse the input text as that type.

fig. 9

MaskedTextBox Mask Picker

In a visual designer, the MaskedTextBox Mask property editor launches a dialog which contains a list of pre-defined masks and the ability to test each mask. This list is also customizable by users.

fig. 10

Layout

AutoRelocate Property

This property was called Pinned in the alpha build. It specifies whether a control should relocate on the Form if adjacent controls resize due to content changes. This is very helpful for localization scenarios.

TableLayoutPanel Design Experience

The design experience for the TableLayoutPanel has been overhauled. Support for dragging controls to individual cells and resizing rows and columns has been added. Also, a smart tag has been added to help manage the rows and columns on a TableLayoutPanel.

fig. 11

Client Application Settings (Config)

Client configuration is a new feature for storing application and user settings.

Config Designtime

The design experience for config is similar to the dynamic properties design from Visual Studio .net 2003. Using this dialog will automatically generate a class that inherits from ApplicationSettingsBase with property definitions. This can be accessed through the "(ApplicationSettings)" property on each control.

fig. 12

Designer Features

Smart Tags

The smart tag infrastructure has been overhauled since the alpha. The look and feel for smart tags has changed and support has been added to insert properties into a smart tag panel.

fig. 13

Snaplines

Snapline support has been extended since the alpha. Text baseline and margin / padding snaplines have been added. Also, snaplines now appear when resizing a control and when dragging a control from the toolbox. Also, snaplines are accessible from the keyboard by hitting ctrl + an arrow key.

fig. 14

Document Outline

Context menu support has been added to the document outline.

fig. 15

Edit Properties Mode

Edit properties mode has been streamlined to only support string based properties. Also, the look and feel has been changed to help highlight which control is being modified.

fig. 16

StatusBar Size and Location

The size and location of the primary selected control are now displayed in the statusbar.

fig. 17

Sending Feedback to Microsoft

We would really like to know what you think about these features. If you have suggestions for adding new features or for changing existing features, we'd like to know. Such feedback is very important and very useful for us to make Windows Forms better for customers.

Thank You

原创粉丝点击