The Text element has the following optional attributes:
align
Determines the text's alignment within its parent element:
START: left- or top-aligned (right-aligned when the current language
uses an RTL text direction)
CENTER: center-aligned
END: right- or bottom-aligned (left-aligned when the current language
uses an RTL text direction)
The default value is CENTER.
ellipsis
A boolean value that indicates whether to show an ellipsis if the text is too
long to fit in the parent element. The default is FALSE.
maxLines
A non-zero integer that indicates the maximum number of lines that the parent
element can use to display the text. If this value is less than 0, the watch
face arranges the text in the optimal number of lines for taking up the parent
element's height.
isAutoSize
Downscales the font size to fit the bounds of the containing
PartText, with a minimum font size of 12px. If used in conjunction with
ellipsis, first the text is scaled down, then if the text still exceeds the
bounds, the ellipsis is applied.
Inner elements
The Text element can contain any number of the following inner elements:
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-05-20 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-05-20 UTC."],[],[],null,["# Text\n\nWatch Face Format version Version 4 Version 3 Version 2 Version 1\n\n*** ** * ** ***\n\nSpecifies a plain-text configuration.\n\nIntroduced in Wear OS 4.\n\nSyntax\n------\n\n```xml\n\u003cText align=\"START | CENTER | END\" ellipsis=\"boolean\"\n maxLines=\"integer\" isAutoSize=\"boolean\"\u003e\n \u003c!-- Possible inner elements. The PartText element syntax shows a\n more complete example. --\u003e\n \u003cFont ... /\u003e\n \u003cBitmapFont ... /\u003e\n\u003c/Text\u003e\n```\n\nAttributes\n----------\n\nThe `Text` element has the following optional attributes:\n\n`align`\n\n: Determines the text's alignment within its parent element:\n\n - `START`: left- or top-aligned (right-aligned when the current language uses an RTL text direction)\n - `CENTER`: center-aligned\n - `END`: right- or bottom-aligned (left-aligned when the current language uses an RTL text direction)\n\n The default value is `CENTER`.\n\n`ellipsis`\n\n: A boolean value that indicates whether to show an ellipsis if the text is too\n long to fit in the parent element. The default is `FALSE`.\n\n`maxLines`\n\n: A non-zero integer that indicates the maximum number of lines that the parent\n element can use to display the text. If this value is less than `0`, the watch\n face arranges the text in the optimal number of lines for taking up the parent\n element's height.\n\n`isAutoSize`\n\n: Downscales the font size to fit the bounds of the containing\n `PartText`, with a minimum font size of 12px. If used in conjunction with\n `ellipsis`, first the text is scaled down, then if the text still exceeds the\n bounds, the ellipsis is applied.\n\nInner elements\n--------------\n\nThe `Text` element can contain any number of the following inner elements:\n\n- [`Font`](/reference/wear-os/wff/group/part/text/bitmap-font)\n- [`BitmapFont`](/reference/wear-os/wff/group/part/text/font)\n\nRecommended for you\n-------------------\n\n- Note: link text is displayed when JavaScript is off\n- [Text](/reference/wear-os/wff/group/part/text/text)\n- [TextCircular](/reference/wear-os/wff/group/part/text/text-circular)\n- [TextCircular](/reference/wear-os/group/part/text/text-circular)"]]