InCanvasControlData Class

Represents a collection of data which is used by [!:Autodesk::Revit::DB::TemporaryGraphicsManager] to create and update an in-canvas control.
Inheritance Hierarchy
SystemObject
  Autodesk.Revit.DBInCanvasControlData

Namespace: Autodesk.Revit.DB
Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)
Syntax
public class InCanvasControlData : IDisposable

The InCanvasControlData type exposes the following members.

Constructors
 NameDescription
Public methodInCanvasControlData(String) Constructs an InCanvasControlData with specific values assigned.
Public methodInCanvasControlData(String, XYZ) Constructs an InCanvasControlData with specific values assigned.
Top
Properties
 NameDescription
Public propertyImagePath The path to the image file to be used. This must be an absolute path to a location on disk.
Public propertyIsValidObject Specifies whether the .NET object represents a valid Revit entity.
Public propertyPosition The position of the in-canvas control in model coordinates.
Top
Methods
 NameDescription
Public methodDisposeReleases all resources used by the InCanvasControlData
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Remarks

So far, only bitmap file is supported for ImagePath. The rendered image is the same size in pixel dimensions as the original one. To get a better result, the caller should prepare the image with proper size, for exmaple: 32x32 or 64x64 in pixels, before use. To achive a "transparent" backgound color effect over the provided bitmap, the bitmap should use color RGB(0, 128, 128) as its background and it will be cleared during rendering by Revit.

See Also