windowsforms-devexpress-dot-utils-dot-supertooltip-a9c6d0b3.md
Gets the collection of objects that represent regions (title, content, etc.) in a super tooltip.
Namespace : DevExpress.Utils
Assembly : DevExpress.Utils.v25.2.dll
NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core
[Browsable(false)]
public ToolTipItemCollection Items { get; }
<Browsable(False)>
Public ReadOnly Property Items As ToolTipItemCollection
| Type | Description |
|---|---|
| DevExpress.Utils.ToolTipItemCollection |
The collection of objects that represent regions (title, content, etc.) in a super tooltip.
|
A super tooltip consists of multiple regions: title, content, footer, separators. Use the Items property to access/add/remove objects that represent the regions:
Regions are displayed in the tooltip one under another in the same order as in the collection.
The following examples demonstrate two different approaches to create a super tooltip ( SuperToolTip ) and assign in to a bar item. The super tooltip includes the title, main content, separator, and footer.
using DevExpress.Utils;
private void Form1_Load(object sender, EventArgs e) {
CreateSuperTooltip(barButtonItemChart);
}
void CreateSuperTooltip(BarItem barItem) {
SuperToolTip superTip = new SuperToolTip();
ToolTipItem item = new ToolTipItem();
if(barItem.ImageOptions.SvgImage != null)
item.ImageOptions.SvgImage = barItem.ImageOptions.SvgImage;
item.Text = "Transform data to its most appropriate and readable visual representation. Insert bar charts, pie graphs, line graphs, or financial diagrams.";
ToolTipItem footer = new ToolTipItem();
superTip.AllowHtmlText = DefaultBoolean.True;
footer.Text = "<a href=\"https://www.devexpress.com\">Learn more</a>";
superTip.Items.AddTitle("Add a Chart");
superTip.Items.Add(item);
superTip.Items.AddSeparator();
superTip.Items.Add(footer);
barItem.SuperTip = superTip;
}
Imports DevExpress.Utils
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs)
CreateSuperTooltip(barButtonItemChart)
End Sub
Private Sub CreateSuperTooltip(ByVal barItem As BarItem)
Dim superTip As New SuperToolTip()
Dim item As New ToolTipItem()
If barItem.ImageOptions.SvgImage IsNot Nothing Then
item.ImageOptions.SvgImage = barItem.ImageOptions.SvgImage
End If
item.Text = "Transform data to its most appropriate and readable visual representation. Insert bar charts, pie graphs, line graphs, or financial diagrams."
Dim footer As New ToolTipItem()
superTip.AllowHtmlText = DefaultBoolean.True
footer.Text = "Learn more on www.devexpress.com"
superTip.Items.AddTitle("Add a Chart")
superTip.Items.Add(item)
superTip.Items.AddSeparator()
superTip.Items.Add(footer)
barItem.SuperTip = superTip
End Sub
Create the SuperToolTipSetupArgs object, customize its settings, and pass it to the SuperToolTip.Setup method.
using DevExpress.Utils;
private void Form1_Load(object sender, EventArgs e) {
SetupSuperTooltip(barButtonItemChart);
}
void SetupSuperTooltip(BarItem barItem) {
SuperToolTip superTip = new SuperToolTip();
SuperToolTipSetupArgs args = new SuperToolTipSetupArgs();
args.Title.Text = "Add a Chart";
args.Contents.Text = "Transform data to its most appropriate and readable visual representation. Insert bar charts, pie graphs, line graphs, or financial diagrams.";
if(barItem.ImageOptions.SvgImage != null)
args.Contents.ImageOptions.SvgImage = barItem.ImageOptions.SvgImage;
args.ShowFooterSeparator = true;
args.Footer.Text = "<a href=\"https://www.devexpress.com\">Learn more</a>";
superTip.Setup(args);
superTip.AllowHtmlText = DefaultBoolean.True;
barItem.SuperTip = superTip;
}
Imports DevExpress.Utils
Private Sub Form1_Load(ByVal sender As Object, ByVal e As EventArgs)
SetupSuperTooltip(barButtonItemChart)
End Sub
Private Sub SetupSuperTooltip(ByVal barItem As BarItem)
Dim superTip As New SuperToolTip()
Dim args As New SuperToolTipSetupArgs()
args.Title.Text = "Add a Chart"
args.Contents.Text = "Transform data to its most appropriate and readable visual representation. Insert bar charts, pie graphs, line graphs, or financial diagrams."
If barItem.ImageOptions.SvgImage IsNot Nothing Then
args.Contents.ImageOptions.SvgImage = barItem.ImageOptions.SvgImage
End If
args.ShowFooterSeparator = True
args.Footer.Text = "Learn more on www.devexpress.com"
superTip.Setup(args)
barItem.SuperTip = superTip
End Sub
See Also