ArcGIS Pro 3.7 API Reference Guide
ArcGIS.Core.CIM Namespace / CIMBalloonCallout Class
Members Example

In This Topic
    CIMBalloonCallout Class
    In This Topic
    Represents a balloon callout. Balloon callouts are a filled background that is placed behind text. They may or may not have a leader line connecting the callout to an anchor point.
    Object Model
    CIMBalloonCallout ClassCIMPolygonSymbol ClassCIMBalloonCallout ClassCIMPolygonSymbol ClassCIMBalloonCallout ClassCIMTextMargin Class
    Syntax
    Example
    Snippet Creates a balloon callout text symbol
    /// <summary>
    /// Creates a black banner balloon callout text symbol. The [CIMBalloonCallout](https://pro.arcgis.com/en/pro-app/sdk/api-reference/#topic487.html) created is a rectangular polygon with rounded corners.
    /// ![lineCallOut](https://ArcGIS.github.io/arcgis-pro-sdk/images/Labeling/banner-callout.png)
    /// </summary>
    {
      //create a text symbol
      //Note: Run this code inside a QueuedTask
      var textSymbolBalloonCallout = SymbolFactory.Instance.ConstructTextSymbol(ColorFactory.Instance.WhiteRGB, 11, "Corbel", "Regular");
      //A balloon callout
      var balloonCallout = new CIMBalloonCallout();
      //set the callout's style
      balloonCallout.BalloonStyle = BalloonCalloutStyle.RoundedRectangle;
      //Create a solid fill polygon symbol for the callout.
      var polySymbol = SymbolFactory.Instance.ConstructPolygonSymbol(ColorFactory.Instance.BlackRGB, SimpleFillStyle.Solid);
      //Set the callout's background to be the black polygon symbol
      balloonCallout.BackgroundSymbol = polySymbol;
      //margin inside the callout to place the text
      balloonCallout.Margin = new CIMTextMargin
      {
        Left = 5,
        Right = 5,
        Bottom = 5,
        Top = 5
      };
      //assign the callout to the text symbol's callout property
      textSymbolBalloonCallout.Callout = balloonCallout;
      //Refer to the snippet "How to apply a Text Symbol to labels of a layer" below to see how to apply this text symbol to a label class
    }
    Inheritance Hierarchy

    System.Object
       ArcGIS.Core.CIM.CIMObject
          ArcGIS.Core.CIM.CIMCallout
             ArcGIS.Core.CIM.CIMBalloonCallout

    Requirements

    Target Platforms: Windows 11 Home, Pro, Enterprise (64 bit)

    ArcGIS Pro version: 3.0 or higher.
    See Also