Skip to content

ControlToolTip Class

Mauricio Jorquera edited this page Nov 14, 2023 · 16 revisions

Namespace: SCADtools.Revit.UI

This class implements the standard tooltip.

Example

The following example creates a ControlToolTip within a Button.

C#

//Initialize button
SCADtools.Revit.UI.Button button = new SCADtools.Revit.UI.Button()
{
    Label = "...",
    MarginLeft = 6,
    ControlToolTip = new ControlToolTip()
    {
        Title = "Rebar Shape Browser",
        Content = "Launch/Close Rebar Shape Browser."
    }
};
//Create click event
button.ButtonControl.Click += ButtonControl_Click;

Constructors

Name Description
ControlToolTip() Initializes a new instance of the ControlToolTip class.

Properties

Name Description
Title Gets or sets the description title that appears as a ToolTip for the item.
Content Gets or sets the content string displayed in the tooltip.
ExpandedContent Gets or sets the second-level content for the tooltip.
ExpandedImage Gets or sets the image to be displayed below the second-level content.

Syntax

C#

public ControlToolTip ControlToolTip { get; set; }

Remarks

This is a simple data class to store the tooltip information. The default value is null.