Developing Dashboards, Views, and Apps for Splunk Web

 


Tooltip properties

This documentation does not apply to the most recent version of Splunk. Click here for the latest version.

Tooltip properties

This topic covers the properties for the tooltip element.


Tooltip

Usage: charting.tooltip.content.*

Tooltips are the visual elements that appear during chart mouse over, displaying information about different aspects of the chart. For example, in a bar chart, tooltips appear when you roll your mouse pointer over a specific bar. The tooltip presents information about the data represented by that bar, such as the period of time it spans or the number of events counted in it, along with a color swatch. Similarly, a tooltip for a pie chart wedge displays the field value and the percentage of the whole that the wedge represents, along with a color swatch.

Example

This changes the maximum width of a chart tooltip to 500 pixels:

<option name="charting.tooltip.maximumWidth">500</option>

The maximumWidth property is inherited from the layoutSprite object.

Meanwhile, these properties configure the manner in which the tooltip content displays, from its internal margins to the font and style of the text:

<option name="charting.tooltip.content.margin">(5,5,2,2)</option>
<option name="charting.tooltip.content.swatchStyle.margin">(0,5,0,0)</option>
<option name="charting.tooltip.content.swatchStyle.height">10</option>
<option name="charting.tooltip.content.fieldStyle.defaultTextFormat">{font:@fontFace,size:@fontSize,color:0xCCCCCC}</option>
<option name="charting.tooltip.content.fieldStyle.margin">(0,5,0,0)</option>
<option name="charting.tooltip.content.valueStyle.defaultTextFormat">{font:@fontFace,size:@fontSize,color:0xFFFFFF}</option>

@fontFace and @fontSize are references to defaultTextFormat properties that have been previously defined.

Properties

Tool tip properties

The tooltip element is an interactive control that displays content such as field names, values, and percentages--as well as a swatch--that correspond to the chart data sprite underneath the mouse pointer. Inherits properties from layoutSprite.

Property name Value type Definition Default
backgroundBrush brush Indicates the brush to use for painting the tooltip background. Use the @ symbol to reference an prexisting brush, like so: @myBackgroundBrush No brush assigned. See the brush section for properties and defaults.
content.swatchStyle style<layoutSprite> The properties to apply to the swatch sprite. See the layoutSprite section for properties and defaults.
content.fieldStyle style<textBlock> Affects the appearance of the field label text. See the textBlock for properties and defaults.
content.valueStyle style<textBlock> Affects the appearance of the value label text. See the textBlock section for properties and defaults.

This documentation applies to the following versions of Splunk: 4.1 , 4.1.1 , 4.1.2 , 4.1.3 , 4.1.4 , 4.1.5 , 4.1.6 , 4.1.7 , 4.1.8 View the Article History for its revisions.


You must be logged into splunk.com in order to post comments. Log in now.

Was this documentation topic helpful?

If you'd like to hear back from us, please provide your email address:

We'd love to hear what you think about this topic or the documentation as a whole. Feedback you enter here will be delivered to the documentation team.

Feedback submitted, thanks!