DesignSurfaceManager DesignSurfaceManager DesignSurfaceManager DesignSurfaceManager Class


Manages a collection of DesignSurface objects.

public ref class DesignSurfaceManager : IDisposable, IServiceProvider
public class DesignSurfaceManager : IDisposable, IServiceProvider
type DesignSurfaceManager = class
    interface IServiceProvider
    interface IDisposable
Public Class DesignSurfaceManager
Implements IDisposable, IServiceProvider


The DesignSurfaceManager class is designed to be a container of DesignSurface objects. It provides common services that handle event routing between designers, property windows, and other global objects. Using DesignSurfaceManager is optional, but it is recommended if you intend to have several designer windows.

The DesignSurfaceManager class provides several design-time services automatically. You can override each of these services by replacing them in the protected ServiceContainer property. To replace a service, override the constructor, call base, and make any changes through the protected ServiceContainer property. All services added to the service container that implement the IDisposable interface are disposed when the design surface manager is disposed. The DesignSurfaceManager class provides the IDesignerEventService interface as the default service. IDesignerEventService provides a global eventing mechanism for designer events. With this mechanism, an application is informed when a designer becomes active. The service provides a collection of designers and a single place where global objects, such as the Properties window, can monitor selection change events.


DesignSurfaceManager() DesignSurfaceManager() DesignSurfaceManager() DesignSurfaceManager()

Initializes a new instance of the DesignSurfaceManager class.

DesignSurfaceManager(IServiceProvider) DesignSurfaceManager(IServiceProvider) DesignSurfaceManager(IServiceProvider) DesignSurfaceManager(IServiceProvider)

Initializes a new instance of the DesignSurfaceManager class.


ActiveDesignSurface ActiveDesignSurface ActiveDesignSurface ActiveDesignSurface

Gets or sets the active designer.

DesignSurfaces DesignSurfaces DesignSurfaces DesignSurfaces

Gets a collection of design surfaces.

ServiceContainer ServiceContainer ServiceContainer ServiceContainer

Gets the design surface manager's ServiceContainer.


CreateDesignSurface() CreateDesignSurface() CreateDesignSurface() CreateDesignSurface()

Creates an instance of a design surface.

CreateDesignSurface(IServiceProvider) CreateDesignSurface(IServiceProvider) CreateDesignSurface(IServiceProvider) CreateDesignSurface(IServiceProvider)

Creates an instance of a design surface.

CreateDesignSurfaceCore(IServiceProvider) CreateDesignSurfaceCore(IServiceProvider) CreateDesignSurfaceCore(IServiceProvider) CreateDesignSurfaceCore(IServiceProvider)

Implementation that creates the design surface.

Dispose() Dispose() Dispose() Dispose()

Releases the resources used by the DesignSurfaceManager.

Dispose(Boolean) Dispose(Boolean) Dispose(Boolean) Dispose(Boolean)

Releases the unmanaged resources used by the DesignSurfaceManager and optionally releases the managed resources.

Equals(Object) Equals(Object) Equals(Object) Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode() GetHashCode() GetHashCode() GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetService(Type) GetService(Type) GetService(Type) GetService(Type)

Gets a service in the design surface manager's service container.

GetType() GetType() GetType() GetType()

Gets the Type of the current instance.

(Inherited from Object)
MemberwiseClone() MemberwiseClone() MemberwiseClone() MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
ToString() ToString() ToString() ToString()

Returns a string that represents the current object.

(Inherited from Object)


ActiveDesignSurfaceChanged ActiveDesignSurfaceChanged ActiveDesignSurfaceChanged ActiveDesignSurfaceChanged

Occurs when the currently active designer changes.

DesignSurfaceCreated DesignSurfaceCreated DesignSurfaceCreated DesignSurfaceCreated

Occurs when a designer is created.

DesignSurfaceDisposed DesignSurfaceDisposed DesignSurfaceDisposed DesignSurfaceDisposed

Occurs when a designer is disposed.

SelectionChanged SelectionChanged SelectionChanged SelectionChanged

Occurs when the global selection changes.


for full access to system resources. Demand values: LinkDemand, InheritanceDemand. Associated state:

Applies to

See also