-
Notifications
You must be signed in to change notification settings - Fork 259
ControlInfo and ControlDef Classes
Gary edited this page Aug 27, 2014
·
1 revision
The ControlInfo and ControlDef classes describe a control's appearance and location in the UI. WinForms uses ControlInfo; WPF uses ControlDef. Both have similar information. Information in these classes is needed to register a control.
ControlInfo offers a variety of constructors with varying information. This one has all the options:
public ControlInfo(string name, string description, StandardControlGroup group, Image image)
{
m_name = name;
m_description = description;
m_group = group;
m_image = image;
}These parameters are:
-
name: Control name, which may be displayed as the title of a hosting control or form. -
description: Control description, which may be displayed as a tooltip. -
group:StandardControlGroupfor initial control hosting group. For details, see ATF Control Groups. -
image: Optional control image, which can be displayed on a hosting control tab or form.
ControlDef does not provide a constructor with parameters, but has the following gettable and settable properties:
-
Name: Control's name, which may be displayed as the title of a hosting control tab or form. -
Description: Description, which may be displayed as a tooltip. -
Group:StandardControlGroupindicating where controls are initially docked. For details, see ATF Control Groups. -
ImageSourceKey: Optional control image, which may be displayed on a hosting control or form. -
Id: Unique ID for control.
ControlInfo except for the additional ID.
This line, from the ATF Model Viewer Sample, shows instantiating a ControlInfo for a 3D rendering control:
ControlInfo cinfo = new ControlInfo("3D View", "3d viewer", StandardControlGroup.CenterPermanent);This example, from the IControlHostService interface for WPF, shows instantiating a ControlDef:
var def = new ControlDef() { Name = name, Description = description, Group = group, Id = id,
ImageSourceKey = imageSourceKey };- Using Controls in ATF: Overview of using controls in ATF.
-
ControlInfo and ControlDef Classes: Description of the
ControlInfo(WinForms) andControlDef(WPF) classes that describe a control's appearance and location in the UI. - ATF Control Groups: About control groups, which provide an initial position for a top-level control.
-
Registering Controls: How to register controls with the
ControlHostServicecomponent. - Creating Control Clients: Creating a control client that specifies the control's behavior, if any, when the control gains or loses focus, or is closed.
- Using WinForms Controls in WPF: How to use WinForms-based component controls and dialogs in a WPF based application.
-
Adaptable Controls: Discussion of the
AdaptableControlclass, which provides a control with adapters. - ATF Custom Controls: Overview of the custom controls ATF provides.
- ATF Custom Dialogs: Overview of the standard dialogs in ATF.
- Home
- Getting Started
- Features & Benefits
- Requirements & Dependencies
- Gallery
- Technology & Samples
- Adoption
- News
- Release Notes
- ATF Community
- Searching Documentation
- Using Documentation
- Videos
- Tutorials
- How To
- Programmer's Guide
- Reference
- Code Samples
- Documentation Files
© 2014-2015, Sony Computer Entertainment America LLC