Select to view content in your preferred language

subscript and superscript support in Arcade Text Function

3747
9
05-17-2019 02:09 PM
Status: Already Offered
Labels (1)
JosephMcGehan
Occasional Contributor

The text function's in Arcade are great, it would be even better with Subscript and Superscript support. ie Subscript() and Superscript()

We create a lot of lithology maps that are labeled with two bits of text, the second bit of text is always subscript.  ArcGIS Pro and ArcGIS Enterprise Portal both utilize Arcade. The currently deployed formatting tags are limited to the applications and are outdated.

9 Comments
KoryKramer

Do you really mean Avenue?  Or do you mean Arcade?  https://developers.arcgis.com/arcade/

DanPatterson_Retired

I suspect Arcade... but Avenue would be just as good

JosephMcGehan

I was tired and showing my age... yes I meant Arcade.

AnzhelikaKamza1

Hello everyone,

It will be very useful if we can do labeling of geological index like in image Geological Index labeling

KaylaFlamm

You should be able to do this by using ArcGIS Pro text formatting tags in combination with Arcade. See https://pro.arcgis.com/en/pro-app/help/mapping/text/text-formatting-tags.htm 

For example, something like $feature.field1 + " " + "<bol>" + $feature.field2 + "</bol>" would give you "field1 field2" (without quotes) as your label.

JosephMcGehan

I've used formatting tags in the application since 2002, however they are not something that can be used across platform: ie in ArcGIS Pro, ArcGIS Online, Enterprise Portal, and Collector. Arcade is the future and will have cross platform support, so it makes sense to ask for heavily used functions. 

CraigWilliams
Status changed to: Already Offered

Superscript / subscript are text drawing capabilities are not script language specific. This can be achieved in Arcade, VBScript, Python, or JScript with Text Formatting tags instead: https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm

Bud
by

Here's an example of using superscript in an Arcade label:

SYSTEM_CALCULATED_AREA + " m" + "<SUP>" + "2" + "</SUP>"

https://pro.arcgis.com/en/pro-app/latest/help/mapping/text/text-formatting-tags.htm#ESRI_SECTION1_D1...

 

 

NigelBaker

You can just paste it from windows. This works for annotations anyway