⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime
This deprecated feature is only supported in the Legacy Runtime, not the New Runtime.
DEPRECATION NOTICE: This entire page documents the legacy Text
manipulation system. For new projects: Use Data Binding instead. For existing projects: Plan to
migrate from direct text run manipulation to Data Binding as soon as possible.
For more information on designing and animating Text, please refer to the editor’s text section:
⚠️ LEGACY CONTENT WARNING: The following sections document the deprecated
Text manipulation system. This content is provided for legacy support
only. New implementations should use Data Binding.
If you intend to update a text run at runtime it’s important to manually enter a unique name for the run in the editor:And then export the name: right-click and select Export nameYou can identify an exported component if it’s surrounded by square brackets. This makes it possible for the run to be “discoverable” at runtime by its name. For more information, see Exporting for Runtime.
If the name is not set manually in the editor the name will not be part of
the exported .riv (to reduce file size).
To set a given text run value at any given time, reference the .setTextRunValue() API on the RiveViewModel:
open func setTextRunValue(_ textRunName: String, textValue: String) throws
Supply the text run name and a second parameter, textValue, with a String value that you want to set the new text value for.
If the supplied textRunName Rive text run cannot be queried on the active artboard, Rive will throw a RiveError.textValueRunError that you may need to catch and handle gracefully in your application.
⚠️ DEPRECATED FEATURE: Nested Text Runs are part of the legacy Text
manipulation system. Use Data Binding instead for controlling component
text properties at runtime.
It’s possible to set nested text runs at runtime—text that is not on the main artboard but on a Component. To set a nested text run, you’ll need to take note of the path where the input exists at an artboard level.For example, to get/set the text run named button_text on the Button artboard, you need to provide the correct path.Setting Nested Text RunsThe artboard names here are:
Main -> NestedArtboard -> Button
However, the path is determined based on the names set in the hierarchy:
ArtboardWithUniqueName -> ButtonWithUniqueName
The path is then: ArtboardWithUniqueName/ButtonWithUniqueName
Be sure to mark the components and text runs as exported. Export
component name
Do not use ”/” in the name for your components, as that will break the search
functionality at runtime.
Additionally, similar to setting text within a parent artboard, you can read the value of a text run within a component instance using the following API:
open func setTextRunValue(_ textRunName: String, textValue: String, path: String) throws
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Rive","colors":{"primary":"#ffa41c","light":"#ffa41c","dark":"#ffa41c"},"logo":{"light":"https://mintcdn.com/rive/tBktbqSaEr9ZwywZ/logo/rive_top_logo_black.svg?fit=max\u0026auto=format\u0026n=tBktbqSaEr9ZwywZ\u0026q=85\u0026s=e09b8659935986a837947ae7c3b104e0","dark":"https://mintcdn.com/rive/tBktbqSaEr9ZwywZ/logo/rive_top_logo_white.svg?fit=max\u0026auto=format\u0026n=tBktbqSaEr9ZwywZ\u0026q=85\u0026s=d2ccc2c4dec459d584f578475de89248","href":"https://rive.app?utm_source=docs\u0026utm_medium=header_nav"},"favicon":"https://mintcdn.com/rive/IGEy4oJSivuQmjey/favicon_black.png?fit=max\u0026auto=format\u0026n=IGEy4oJSivuQmjey\u0026q=85\u0026s=986c81e5b82e1138420d773296030a3a","appearance":{"default":"dark"},"background":{"decoration":"grid"},"navbar":{"links":[{"href":"/tutorials/learn-rive","label":"Learn"},{"href":"/community/support","label":"Support"}],"primary":{"type":"button","label":"Get Rive","href":"https://rive.app/downloads?utm_source=docs\u0026utm_medium=header_nav"}},"footer":{"socials":{"youtube":"https://www.youtube.com/channel/UCPal2R1FxwRTPylhP_7ofEg","x":"https://twitter.com/rive_app","instagram":"https://www.instagram.com/rive.app","github":"https://github.com/rive-app","discord":"https://discord.gg/rive-app"},"links":[{"header":"Resources","items":[{"label":"Community","href":"https://community.rive.app?utm_source=docs\u0026utm_medium=footer_nav"},{"label":"Blog","href":"https://rive.app/blog?utm_source=docs\u0026utm_medium=footer_nav"},{"label":"Case Studies","href":"https://rive.app/blog/case-studies?utm_source=docs\u0026utm_medium=footer_nav"},{"label":"Marketplace","href":"https://rive.app/marketplace?utm_source=docs\u0026utm_medium=footer_nav"},{"label":"Feature Requests","href":"https://community.rive.app/c/feature-requests"}]},{"header":"Company","items":[{"label":"Careers","href":"https://rive.app/careers?utm_source=docs\u0026utm_medium=footer_nav"},{"label":"Terms of Service","href":"/docs/legal/terms-of-service"},{"label":"Acceptable Use Policy","href":"/docs/legal/acceptable-use-policy"},{"label":"Privacy Policy","href":"/docs/legal/privacy-policy"},{"label":"Your Privacy Choices","href":"https://rive.app/?cookie-settings"}]}]},"fonts":{"heading":{"family":"Tomorrow Placeholder","weight":500,"source":"https://framerusercontent.com/assets/nCpxWS6DaPlPe0lHzStXAPCo3lw.woff2","format":"woff2"}},"integrations":{"amplitude":{"apiKey":"38803036884a752b104ee4bf501e0945"},"cookies":{"key":"rive_analytics","value":"granted"}},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"variables":{"runtimeCurrentNameApple":"New Runtime","runtimeLegacyNameApple":"Legacy Runtime","monthlyCreditsVoyager":"$20","monthlyCreditsEnterprise":"$40","pricingCadetMonthly":"$17","pricingCadetYearly":"$108","pricingVoyagerMonthly":"$49","pricingVoyagerYearly":"$384","pricingEnterpriseYearly":"$1,440","cliAllowanceFree":"50","cliAllowanceCadet":"500","cliAllowanceVoyager":"5,000","versionWeb":"2.40.1","versionReact":"4.33.0","versionApple":"6.24.0","versionAndroid":"11.9.2","versionReactNative":"0.5.5","versionFlutter":"0.14.11","versionDevFlutter":"0.15.0-dev.4","versionUnity":"0.4.5","versionUnreal":"0.4.25","supportForm":"https://forms.rive.app/support?utm_medium=support_page","supportFormEducational":"https://forms.rive.app/education?utm_medium=support_page"},"styling":{"latex":false},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"rive","hasAudioNarration":false,"actualSubdomain":"rive","customDomains":["rive.app"],"gitSource":{"type":"github","owner":"rive-app","repo":"rive-docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"feedback":{"edits":true,"issues":true,"thumbs":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"REMOVE_BRANDING":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6af2942236353e262b4c0307","clientVersion":"0.0.4094","searchFilterCounts":[{"language":"default","tag":"Runtimes","count":283},{"language":"default","tag":"Scripting","count":188},{"language":"default","tag":"Scripting API","count":167},{"language":"default","tag":"Editor","count":103},{"language":"default","tag":"Fundamentals","count":89},{"language":"default","tag":"GPU","count":45},{"language":"default","tag":"Design","count":37},{"language":"default","tag":"Artboards","count":25},{"language":"default","tag":"Interfaces","count":24},{"language":"default","tag":"React Native","count":20}]},"assistantConfig":{},"basePath":"/docs","hasChatPermissions":false,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-metadata","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"custom.css","content":"p{font-size:14px}ul li{font-size:14px}ol li{font-size:14px}.signature .code-block{border:none}.signature .code-block [data-floating-buttons=\"true\"]{display:none}.signature .code-block [data-component-part=\"code-block-root\"]{background:none;padding:0}.dark .card{background-color:var(--background-dark)!important;border-color:rgb(255 255 255 / 0.1)!important}.dark .card:hover{border-color:var(--primary-light)!important}"}],"page":{"pagePath":"runtimes/apple/text","slug":"/runtimes/apple/text","pageMetadata":{"title":"Text","description":"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime","noindex":true,"href":"/runtimes/apple/text"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,em:`em`,li:`li`,p:`p`,path:`path`,pre:`pre`,span:`span`,strong:`strong`,svg:`svg`,ul:`ul`,..._provideComponents(),...props.components},{Card,CardGroup,CodeBlock,Heading,Link,Note,OptimizedImage,Warning}=_components;if(!Card)_missingMdxReference(`Card`,true);if(!CardGroup)_missingMdxReference(`CardGroup`,true);if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Link)_missingMdxReference(`Link`,true);if(!Note)_missingMdxReference(`Note`,true);if(!OptimizedImage)_missingMdxReference(`OptimizedImage`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsx(Warning,{children:_jsx(_components.p,{children:`This deprecated feature is only supported in the Legacy Runtime, not the New Runtime.`})}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`DEPRECATION NOTICE:`}),` This entire page documents the legacy Text\nmanipulation system. `,_jsx(_components.strong,{children:`For new projects:`}),` Use `,_jsx(Link,{href:`data-binding`,children:`Data Binding`}),` instead. `,_jsx(_components.strong,{children:`For existing projects:`}),` Plan to\nmigrate from direct text run manipulation to Data Binding as soon as possible.`]})}),`\n`,_jsx(_components.p,{children:`For more information on designing and animating Text, please refer to the editor’s text section:`}),`\n`,_jsx(CardGroup,{cols:2,children:_jsx(Card,{title:`Text`,href:`/editor/text/text-overview`,icon:_jsxs(_components.svg,{xmlns:`http://www.w3.org/2000/svg`,height:`100%`,fill:`none`,viewBox:`0 0 16 16`,className:`size-4 text-gray-500/80 dark:text-gray-400`,\"aria-hidden\":`true`,children:[_jsx(_components.path,{fill:`currentColor`,d:`M7.31 7.111 2.406 5.15l4.61-1.844.328-.126a2.3 2.3 0 0 1 1.647 0l.33.126L13.93 5.15 9.024 7.112c-.55.22-1.163.22-1.712 0`}),_jsx(_components.path,{stroke:`currentColor`,\"stroke-linecap\":`round`,\"stroke-linejoin\":`round`,d:`m2.405 10.911 4.906 1.963c.55.22 1.162.22 1.712 0l4.906-1.963M2.405 8.031 7.31 9.992c.55.22 1.162.22 1.712 0l4.906-1.963M2.405 5.15 7.31 7.111c.55.22 1.162.22 1.712 0l4.906-1.962-4.61-1.844-.329-.126a2.3 2.3 0 0 0-1.647 0l-.329.126z`})]}),children:_jsx(_components.p,{children:`Information on designing and animating Text`})})}),`\n`,_jsx(Heading,{level:`2`,id:`read/update-text-runs-at-runtime`,children:`Read/update Text Runs at runtime`}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`⚠️ LEGACY CONTENT WARNING:`}),` The following sections document the deprecated\nText manipulation system. `,_jsx(_components.strong,{children:`This content is provided for legacy support\nonly.`}),` New implementations should use `,_jsx(Link,{href:`data-binding`,children:`Data Binding`}),`.`]})}),`\n`,_jsxs(_components.p,{children:[`If you intend to update a `,_jsx(_components.strong,{children:`text run`}),` at runtime it’s important to manually enter a `,_jsx(_components.em,{children:`unique name`}),` for the run in the editor:`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=c709aa18d8170cb3481bb5f87d658c47`,alt:`Hierarchy panel showing a text run renamed to MyRun`,\"data-og-width\":`578`,width:`578`,\"data-og-height\":`298`,height:`298`,\"data-path\":`images/runtimes/text-run-unique-name-hierarchy.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=280\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=f75b6c086677990d9f3e359d7390b36b 280w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=560\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=f7656a4a57134494252e964fca761c0f 560w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=840\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=6fe359fbc8e860af23499f4b193e5440 840w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=fbaaecb46d1c30ac69a69adcf97d3ecb 1100w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=842c193e67e6930d130fec276183c600 1650w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-unique-name-hierarchy.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=e161647f1a6d65f4d832af0f2a8dbd8d 2500w`}),`\n`,_jsxs(_components.p,{children:[`And then export the name: `,_jsx(_components.strong,{children:`right-click`}),` and select `,_jsx(_components.strong,{children:`Export name`})]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=28d376e4bfa110247c2572ba42d9b809`,alt:`Right-click menu on the MyRun text run with Export name checked`,\"data-og-width\":`391`,width:`391`,\"data-og-height\":`481`,height:`481`,\"data-path\":`images/runtimes/text-run-export-name-menu.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=280\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=fe8dbc028ff8b0c6849032acc83480f0 280w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=560\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=4c9d399298ac8cf215eceb2900ec4870 560w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=840\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=f76cffe2a979ae40bb2e171a50c61660 840w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=3519ea6302d35d01100493e0894d7a5d 1100w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=f75d0e1124362affa448b879d1bd6e05 1650w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/text-run-export-name-menu.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=12a483916ca9079748076c8e54889eb2 2500w`}),`\n`,_jsxs(_components.p,{children:[`You can identify an exported component if it’s surrounded by square brackets. This makes it possible for the run to be “discoverable” at runtime by its name. For more information, see `,_jsx(_components.a,{href:`/editor/exporting/exporting-for-runtime`,children:`Exporting for Runtime`}),`.`]}),`\n`,_jsx(Warning,{children:_jsx(_components.p,{children:_jsxs(_components.strong,{children:[`If the name is not set manually in the editor the name will not be part of\nthe exported `,_jsx(_components.em,{children:`.riv`}),` (to reduce file size).`]})})}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`Text runs can also be updated on components at runtime, see `,_jsx(_components.a,{href:`#read-update-nested-text-runs-at-runtime`,children:`Read/Update\nNested Text Runs at Runtime`}),` below.`]})}),`\n`,_jsx(Heading,{level:`4`,id:`reading-text`,children:`Reading text`}),`\n`,_jsxs(_components.p,{children:[`To read a given text run text value at any given time, reference the `,_jsx(_components.code,{children:`.getTextRunValue()`}),` API on the `,_jsx(_components.code,{children:`RiveViewModel`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`open`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` getTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`_`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` textRunName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` String`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`?`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Supply the text run name and you’ll have the Rive text run value returned, or `,_jsx(_components.code,{children:`nil`}),` if the text run could not be queried.`]}),`\n`,_jsx(Heading,{level:`4`,id:`setting-text`,children:`Setting text`}),`\n`,_jsxs(_components.p,{children:[`To set a given text run value at any given time, reference the `,_jsx(_components.code,{children:`.setTextRunValue()`}),` API on the `,_jsx(_components.code,{children:`RiveViewModel`}),`:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`open`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` setTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`_`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` textRunName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`textValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`throws`})]}),`\n`]})})}),`\n`,_jsxs(_components.p,{children:[`Supply the text run name and a second parameter, `,_jsx(_components.code,{children:`textValue`}),`, with a String value that you want to set the new text value for.`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[`If the supplied `,_jsx(_components.code,{children:`textRunName`}),` Rive text run cannot be queried on the active artboard, Rive will throw a `,_jsx(_components.code,{children:`RiveError.textValueRunError`}),` that you may need to catch and handle gracefully in your application.`]})}),`\n`,_jsx(Heading,{level:`4`,id:`example-usage`,children:`Example usage`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`18`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`@State`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` private`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` userInput: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`@State`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` private`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` RiveViewModel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`fileName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my-rive-file\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` body: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`some`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` View {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` VStack`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`spacing`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`20`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` Text`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Enter text:\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`font`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`headline`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` TextField`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Enter text...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`text`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: $userInput)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`textFieldStyle`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`RoundedBorderTextFieldStyle`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`())`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`padding`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`onChange`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`of`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: userInput, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`perform`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { newValue `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`in`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`newValue.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`isEmpty`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` try`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`setTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"MyTextRunName\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`textValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: userInput)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` })`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`view`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`read/update-nested-text-runs-at-runtime`,children:`Read/update nested Text Runs at runtime`}),`\n`,_jsx(Warning,{children:_jsxs(_components.p,{children:[_jsx(_components.strong,{children:`⚠️ DEPRECATED FEATURE:`}),` Nested Text Runs are part of the legacy Text\nmanipulation system. `,_jsx(_components.strong,{children:`Use Data Binding instead`}),` for controlling component\ntext properties at runtime.`]})}),`\n`,_jsxs(_components.p,{children:[`It’s possible to set nested text runs at runtime—text that is not on the main artboard but on a `,_jsx(_components.a,{href:`/editor/fundamentals/components`,children:`Component`}),`. To set a nested text run, you’ll need to take note of the path where the input exists at an artboard level.`]}),`\n`,_jsxs(_components.p,{children:[`For example, to get/set the text run named `,_jsx(_components.strong,{children:`button_text`}),` on the `,_jsx(_components.strong,{children:`Button`}),` artboard, you need to provide the correct path.`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=5400cc520c083df3a750b9056dae38d0`,alt:`Button artboard hierarchy with the exported button_text run selected, alongside the Main, NestedArtboard, and Button artboards`,\"data-og-width\":`3022`,width:`3022`,\"data-og-height\":`1546`,height:`1546`,\"data-path\":`images/runtimes/nested-text-run-button-artboard-hierarchy.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=280\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=bc23f6e779c3b11be68216d53b891793 280w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=560\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=bab4bde6b57c11fc26d124aea0f422fd 560w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=840\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=18020e77657e0a2bcc5410a12701e83f 840w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=e9bd369af68902605e130ae66269a5fe 1100w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=e92e93f16a149f4001c3d1b100897fe4 1650w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-text-run-button-artboard-hierarchy.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=a4e742eecb4e0ff250d50fff583ff90e 2500w`}),`\n`,_jsx(_components.p,{children:_jsx(_components.em,{children:`Setting Nested Text Runs`})}),`\n`,_jsx(_components.p,{children:`The artboard names here are:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`Main`}),` -> `,_jsx(_components.strong,{children:`NestedArtboard`}),` -> `,_jsx(_components.strong,{children:`Button`})]}),`\n`]}),`\n`,_jsx(OptimizedImage,{src:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=4ce9e04af5de392c0ab796a1137c84b9`,alt:`Main artboard hierarchy showing the nested artboard instance named ArtboardWithUniqueName`,\"data-og-width\":`1580`,width:`1580`,\"data-og-height\":`1082`,height:`1082`,\"data-path\":`images/runtimes/nested-artboard-unique-name-hierarchy.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=280\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=33e8c579fa0fdbe332c8ef355e591e98 280w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=560\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=985bce3f5629638a054fb07bf5b006a8 560w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=840\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=810f2b19c9068613a780b126b69220d8 840w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=34149eb9d57c28bac3847f1ac24ea32e 1100w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=d29c150da64fb04d0757dd776b83d720 1650w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-unique-name-hierarchy.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=91e73b04a69accd336b81a8d87a7012f 2500w`}),`\n`,_jsx(_components.p,{children:`However, the path is determined based on the names set in the hierarchy:`}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.strong,{children:`ArtboardWithUniqueName`}),` -> `,_jsx(_components.strong,{children:`ButtonWithUniqueName`})]}),`\n`]}),`\n`,_jsxs(_components.p,{children:[`The path is then: `,_jsx(_components.code,{children:`ArtboardWithUniqueName/ButtonWithUniqueName`})]}),`\n`,_jsxs(Warning,{children:[_jsx(_components.p,{children:`Be sure to mark the components and text runs as exported.`}),_jsx(`br`,{}),_jsxs(_components.p,{children:[_jsx(OptimizedImage,{src:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=ea5e24e6ad2752cf91a5802c20a03f16`,alt:`Right-click menu on the ButtonWithUniqueName nested artboard with Export name checked`,\"data-og-width\":`1892`,width:`1892`,\"data-og-height\":`1010`,height:`1010`,\"data-path\":`images/runtimes/nested-artboard-export-component-name.webp`,\"data-optimize\":`true`,\"data-opv\":`3`,srcset:`https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=280\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=6660321f19d55c4ea34416bcceeccdcb 280w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=560\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=7dc63bb2d5914231b730e75cba8d922d 560w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=840\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=ab276a7975cb35d6e962682fab4884a7 840w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=1100\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=2b6bb877da980f5c5fe7812b3ccab660 1100w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=1650\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=d277498ea91c53d965ab831fb8edc906 1650w, https://mintcdn.com/rive/KLBMS5i_x1PtC-ot/images/runtimes/nested-artboard-export-component-name.webp?w=2500\u0026fit=max\u0026auto=format\u0026n=KLBMS5i_x1PtC-ot\u0026q=85\u0026s=a962e01755e4ddd1c12a205df9705954 2500w`}),` `,_jsx(_components.em,{children:`Export\ncomponent name`})]})]}),`\n`,_jsx(Warning,{children:_jsx(_components.p,{children:`Do not use ”/” in the name for your components, as that will break the search\nfunctionality at runtime.`})}),`\n`,_jsx(Heading,{level:`3`,id:`reading-text-2`,children:`Reading text`}),`\n`,_jsxs(_components.p,{children:[`Similar to `,_jsx(_components.a,{href:`#reading-text`,children:`reading text from a text run within a parent artboard`}),`, you can set the value of a text run within a component instance using the following API:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`open`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` getTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`_`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` textRunName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`path`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`->`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:` String`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`?`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`setting-text-2`,children:`Setting text`}),`\n`,_jsxs(_components.p,{children:[`Additionally, similar to `,_jsx(_components.a,{href:`#setting-text`,children:`setting text within a parent artboard`}),`, you can read the value of a text run within a component instance using the following API:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`open`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` func`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:` setTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`_`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:` textRunName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`textValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#8250DF`,\"--shiki-dark\":`#DCDCAA`},children:`path`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`throws`})]}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`example`,children:`Example:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`18`,language:`swift`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`swift`,children:_jsxs(_components.code,{language:`swift`,numberOfLines:`18`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`@State`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` private`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` userInput: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#4EC9B0`},children:`String`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:` =`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"\"`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`@State`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` private`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:` var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`=`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` RiveViewModel`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`fileName`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"my-rive-file\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#569CD6`},children:`var`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` body: `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`some`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` View {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` VStack`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`spacing`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`20`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` Text`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Enter text:\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`font`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(.`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`headline`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:` TextField`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Enter text...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`text`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: $userInput)`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`textFieldStyle`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`RoundedBorderTextFieldStyle`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`())`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`padding`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` .`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`onChange`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`of`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: userInput, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`perform`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: { newValue `}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`in`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` if`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` (`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`newValue.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`isEmpty`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`) {`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:` try`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`!`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`setTextRunValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`(`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"MyTextRunName\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`textValue`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: userInput, `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#DCDCAA`},children:`path`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"Artboard/NestedArtboard\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`)`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` })`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` rvm.`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#9CDCFE`},children:`view`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`()`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` }`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`3`,id:`semantics-for-accessibility`,children:`Semantics for accessibility`}),`\n`,_jsx(_components.p,{children:`Rive now supports screen readers through semantics.`}),`\n`,_jsxs(_components.p,{children:[`See the `,_jsx(_components.a,{href:`/editor/accessibility/semantics`,children:`Semantics`}),` documentation for current guidance.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Text","description":"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime","noindex":true,"href":"/runtimes/apple/text"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Read/update Text Runs at runtime","slug":"read/update-text-runs-at-runtime","depth":2,"children":[{"title":"Reading text","slug":"reading-text","depth":4,"children":[]},{"title":"Setting text","slug":"setting-text","depth":4,"children":[]},{"title":"Example usage","slug":"example-usage","depth":4,"children":[]}]},{"title":"Read/update nested Text Runs at runtime","slug":"read/update-nested-text-runs-at-runtime","depth":2,"children":[{"title":"Reading text","slug":"reading-text-2","depth":3,"children":[]},{"title":"Setting text","slug":"setting-text-2","depth":3,"children":[]},{"title":"Example:","slug":"example","depth":3,"children":[]},{"title":"Semantics for accessibility","slug":"semantics-for-accessibility","depth":3,"children":[]}]}],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/rive/6157a238f0df2356/rive-init.js","/docs/_mintlify/custom/rive/f98a4b1fb6965efa/rive-consent.js"],"subdomain":"rive","siteName":"Rive","title":"Text - Rive","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-09T21:27:23.483Z","originalFileLocation":"runtimes/apple/text.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"dark\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime\">\u003cmeta data-mint-head name=\"application-name\" content=\"Rive\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"noindex\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Text - Rive\">\u003cmeta data-mint-head property=\"og:description\" content=\"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Rive\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://rive.app/docs/runtimes/apple/text\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://rive.mintlify.site/docs/_mintlify/api/og/v2?division=Legacy+Features\u0026amp;title=Text\u0026amp;description=%E2%9A%A0%EF%B8%8F+DEPRECATED%3A+Use+Data+Binding+instead+of+direct+text+run+manipulation+at+runtime\u0026amp;theme=2e225578d6f0bf137ea455bc\u0026amp;signature=6f6c1d2d7e329c20ffe853adb5a5bc177f16cfa72620be034b11a4a05a863dd9\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Text - Rive\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"⚠️ DEPRECATED: Use Data Binding instead of direct text run manipulation at runtime\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://rive.mintlify.site/docs/_mintlify/api/og/v2?division=Legacy+Features\u0026amp;title=Text\u0026amp;description=%E2%9A%A0%EF%B8%8F+DEPRECATED%3A+Use+Data+Binding+instead+of+direct+text+run+manipulation+at+runtime\u0026amp;theme=2e225578d6f0bf137ea455bc\u0026amp;signature=6f6c1d2d7e329c20ffe853adb5a5bc177f16cfa72620be034b11a4a05a863dd9\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/rive/QOppeg00QlFTw5Bu/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Rive\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#ffa41c\">\u003clink data-mint-head rel=\"canonical\" href=\"https://rive.app/docs/runtimes/apple/text\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/runtimes/apple/text.md\">","siteName":"Rive","nav":{"global":null,"tabs":[{"tab":"Home","pages":[{"title":"Home","href":"/getting-started/introduction"}]},{"tab":"Editor","pages":[{"title":"Editor","href":"/editor/get-rive"}]},{"tab":"Scripting","pages":[{"title":"Scripting","href":"/scripting/getting-started"}]},{"tab":"Runtimes","groups":[{"group":" ","pages":[{"title":"Getting Started with the Rive Runtimes","sidebarTitle":"Getting Started","href":"/runtimes/getting-started"},{"title":"Rive Runtime Demos \u0026 Starters","sidebarTitle":"Demos","mode":"wide","href":"/runtimes/demos"},{"title":"Feature Support","href":"/feature-support"},{"title":"Runtime Sizes","href":"/runtimes/runtime-sizes"},{"title":"Choosing a Renderer","href":"/runtimes/choose-a-renderer/overview"},{"group":"File formats","pages":[{"title":".riv File Format","href":"/runtimes/advanced-topic/format"},{"title":"Rive Markup Language (RML)","sidebarTitle":"RML","href":"/runtimes/advanced-topic/rml"}]}]},{"group":"Runtimes","pages":[{"group":"Web (JS)","pages":[{"title":"Getting Started","href":"/runtimes/web/web-js"},{"title":"Canvas vs WebGL2","href":"/runtimes/web/canvas-vs-webgl"},{"title":"Rive Parameters","href":"/runtimes/web/rive-parameters"},{"title":"Artboards","href":"/runtimes/web/artboards"},{"title":"Layout","href":"/runtimes/web/layouts"},{"title":"State Machine Playback","href":"/runtimes/web/state-machines"},{"title":"Data Binding","href":"/runtimes/web/data-binding"},{"title":"Loading Assets","href":"/runtimes/web/loading-assets"},{"title":"Fonts","href":"/runtimes/web/fonts"},{"title":"Semantics","href":"/runtimes/web/semantics"},{"title":"Focus","href":"/runtimes/web/focus"},{"title":"Text and key input","sidebarTitle":"Text and Key Input","href":"/runtimes/web/text-and-key-input"},{"title":"GPU Canvas","href":"/runtimes/web/gpu-canvas"},{"title":"Preloading WASM","href":"/runtimes/web/preloading-wasm"},{"title":"Caching a Rive File","href":"/runtimes/web/caching-a-rive-file"},{"title":"Playing Audio","href":"/runtimes/web/playing-audio"},{"title":"Low-level API Usage","href":"/runtimes/web/low-level-api-usage"},{"group":"Legacy Features","pages":[{"title":"Animation Playback","href":"/runtimes/web/animation-playback"},{"title":"Inputs","href":"/runtimes/web/inputs"},{"title":"Text","href":"/runtimes/web/text"},{"title":"Rive Events","href":"/runtimes/web/rive-events"}]},{"title":"Migration Guides","href":"/runtimes/web/migration-guides"},{"title":"FAQ","href":"/runtimes/web/faq"}]},{"group":"React","pages":[{"title":"React","sidebarTitle":"Getting Started","href":"/runtimes/react/react"},{"title":"Parameters and Return Values","href":"/runtimes/react/parameters-and-return-values"},{"title":"Artboards","href":"/runtimes/react/artboards"},{"title":"Layout","href":"/runtimes/react/layouts"},{"title":"State Machine Playback","href":"/runtimes/react/state-machines"},{"title":"Data Binding","href":"/runtimes/react/data-binding"},{"title":"Loading Assets","href":"/runtimes/react/loading-assets"},{"title":"Fonts","href":"/runtimes/react/fonts"},{"title":"Semantics","href":"/runtimes/react/semantics"},{"title":"Focus","href":"/runtimes/react/focus"},{"title":"Text and key input","sidebarTitle":"Text and Key Input","href":"/runtimes/react/text-and-key-input"},{"title":"GPU Canvas","href":"/runtimes/react/gpu-canvas"},{"title":"Preloading WASM","href":"/runtimes/react/preloading-wasm"},{"title":"Caching a Rive File","href":"/runtimes/react/caching-a-rive-file"},{"title":"Playing Audio","href":"/runtimes/react/playing-audio"},{"title":"Rendering to a Bitmap","href":"/runtimes/react/rendering-to-a-bitmap"},{"title":"Best Practices","href":"/runtimes/react/best-practices"},{"group":"Legacy Features","pages":[{"title":"Animation Playback","href":"/runtimes/react/animation-playback"},{"title":"Inputs","href":"/runtimes/react/inputs"},{"title":"Text","href":"/runtimes/react/text"},{"title":"Rive Events","href":"/runtimes/react/rive-events"}]},{"title":"Migration Guides","href":"/runtimes/react/migration-guides"}]},{"group":"React Native","pages":[{"title":"React Native","href":"/runtimes/react-native/react-native"},{"title":"GPU Canvas","href":"/runtimes/react-native/gpu-canvas"},{"title":"Loading Rive Files","href":"/runtimes/react-native/loading-rive-files"},{"title":"Props","href":"/runtimes/react-native/props"},{"title":"Rive Ref Methods","href":"/runtimes/react-native/rive-ref-methods"},{"title":"Error Handling","href":"/runtimes/react-native/error-handling"},{"title":"Adding Rive to Expo","href":"/runtimes/react-native/adding-rive-to-expo"},{"title":"Native SDK Version Customization","sidebarTitle":"Custom SDK Version","href":"/runtimes/react-native/native-version-customization"},{"title":"Artboards","href":"/runtimes/react-native/artboards"},{"title":"Layout","href":"/runtimes/react-native/layouts"},{"title":"State Machine Playback","href":"/runtimes/react-native/state-machines"},{"title":"Data Binding","href":"/runtimes/react-native/data-binding"},{"title":"TypeScript Schemas","href":"/runtimes/react-native/typescript-schemas"},{"title":"Loading Assets","href":"/runtimes/react-native/loading-assets"},{"title":"Fonts","href":"/runtimes/react-native/fonts"},{"title":"Caching a Rive File","href":"/runtimes/react-native/caching-a-rive-file"},{"title":"Semantics","href":"/runtimes/react-native/semantics"},{"title":"Playing Audio","href":"/runtimes/react-native/playing-audio"},{"title":"Logging","href":"/runtimes/react-native/logging"},{"group":"Legacy Features","pages":[{"title":"Animation Playback","href":"/runtimes/react-native/animation-playback"},{"title":"Inputs","href":"/runtimes/react-native/inputs"},{"title":"Text","href":"/runtimes/react-native/text"},{"title":"Rive Events","href":"/runtimes/react-native/rive-events"}]},{"title":"Migration Guide","href":"/runtimes/react-native/migration-guide"}]},{"group":"Flutter","pages":[{"title":"Flutter","href":"/runtimes/flutter/flutter"},{"title":"Rive Native for Flutter","href":"/runtimes/flutter/rive-native"},{"title":"Artboards","href":"/runtimes/flutter/artboards"},{"title":"Layout","href":"/runtimes/flutter/layouts"},{"title":"State Machine Playback","href":"/runtimes/flutter/state-machines"},{"title":"Data Binding","href":"/runtimes/flutter/data-binding"},{"title":"Loading Assets","href":"/runtimes/flutter/loading-assets"},{"title":"Fonts","href":"/runtimes/flutter/fonts"},{"title":"Semantics","href":"/runtimes/flutter/semantics"},{"title":"Caching a Rive File","href":"/runtimes/flutter/caching-a-rive-file"},{"title":"Playing Audio","href":"/runtimes/flutter/playing-audio"},{"group":"Legacy Features","pages":[{"title":"Animation Playback","href":"/runtimes/flutter/animation-playback"},{"title":"Inputs","href":"/runtimes/flutter/inputs"},{"title":"Text","href":"/runtimes/flutter/text"},{"title":"Rive Events","href":"/runtimes/flutter/rive-events"}]},{"title":"Migration Guide","href":"/runtimes/flutter/migration-guide"},{"title":"FAQ","href":"/runtimes/flutter/faq"},{"title":"Flutter API Reference","sidebarTitle":"API Reference","href":"/runtimes/flutter/api-reference"}]},{"group":"Apple","pages":[{"title":"Apple","href":"/runtimes/apple/apple"},{"title":"GPU Canvas","href":"/runtimes/apple/gpu-canvas"},{"title":"FAQ","href":"/runtimes/apple/faq"},{"title":"Resource Usage","href":"/runtimes/apple/resource-usage"},{"title":"Artboards","href":"/runtimes/apple/artboards"},{"title":"Layout","href":"/runtimes/apple/layouts"},{"title":"State Machine Playback","href":"/runtimes/apple/state-machines"},{"title":"Data Binding","href":"/runtimes/apple/data-binding"},{"title":"Loading Assets","href":"/runtimes/apple/loading-assets"},{"title":"Fonts","href":"/runtimes/apple/fonts"},{"title":"Caching a Rive File","href":"/runtimes/apple/caching-a-rive-file"},{"title":"Semantics","href":"/runtimes/apple/semantics"},{"title":"Playing Audio","href":"/runtimes/apple/playing-audio"},{"title":"Logging","href":"/runtimes/apple/logging"},{"group":"Legacy Features","pages":[{"title":"Animation Playback","href":"/runtimes/apple/animation-playback"},{"title":"Inputs","description":"⚠️ DEPRECATED: Use Data Binding instead of Inputs for controlling Rive animations","href":"/runtimes/apple/inputs"},{"title":"Text","href":"/runtimes/apple/text"},{"title":"Rive Events","description":"⚠️ DEPRECATED: Use Data Binding instead of Events","href":"/runtimes/apple/rive-events"}]},{"title":"Migration Guides","href":"/runtimes/apple/migration-guides"},{"title":"Migrating from the Legacy Rive Apple Runtime","sidebarTitle":"Migrating from Legacy","href":"/runtimes/apple/migrating-from-legacy"}]},{"group":"Android","pages":[{"title":"Android","href":"/runtimes/android/android"},{"title":"Artboards","href":"/runtimes/android/artboards"},{"title":"Layout","href":"/runtimes/android/layouts"},{"title":"State Machine Playback","href":"/runtimes/android/state-machines"},{"title":"Data Binding","href":"/runtimes/android/data-binding"},{"title":"Loading Assets","href":"/runtimes/android/loading-assets"},{"title":"Fonts","href":"/runtimes/android/fonts"},{"title":"Caching a Rive File","href":"/runtimes/android/caching-a-rive-file"},{"title":"Playing Audio","href":"/runtimes/android/playing-audio"},{"title":"Logging","href":"/runtimes/android/logging"},{"title":"Handling a lost render context","sidebarTitle":"Render Context Loss","href":"/runtimes/android/handling-render-context-loss"},{"title":"Rendering to a Bitmap","href":"/runtimes/android/rendering-to-a-bitmap"},{"group":"Legacy Features","pages":[{"title":"Getting Started (Legacy API)","href":"/runtimes/android/legacy-getting-started"},{"title":"Animation Playback","href":"/runtimes/android/animation-playback"},{"title":"Inputs","href":"/runtimes/android/inputs"},{"title":"Text","href":"/runtimes/android/text"},{"title":"Rive Events","href":"/runtimes/android/rive-events"}]},{"title":"Migrating from the Legacy Rive Android Runtime","sidebarTitle":"Migrating from Legacy","href":"/runtimes/android/migrating-from-legacy"},{"title":"API Reference","url":"https://api-docs.rive.app/android/latest/","href":"/runtimes/android/api-reference"}]},{"group":"Unity","pages":[{"title":"Unity","href":"/game-runtimes/unity/unity"},{"title":"Getting Started","href":"/game-runtimes/unity/getting-started"},{"title":"Fundamentals","href":"/game-runtimes/unity/fundamentals"},{"title":"Components","href":"/game-runtimes/unity/components"},{"title":"Best Practices","href":"/game-runtimes/unity/best-practices"},{"title":"Layouts","href":"/game-runtimes/unity/layouts"},{"title":"Listeners","href":"/game-runtimes/unity/listeners"},{"title":"State Machines","href":"/game-runtimes/unity/state-machines"},{"title":"Data Binding","href":"/game-runtimes/unity/data-binding"},{"title":"Loading Assets","href":"/game-runtimes/unity/loading-assets"},{"title":"Audio","href":"/game-runtimes/unity/audio"},{"group":"Tutorials","pages":[{"title":"Control a health bar with data binding in Unity","href":"/game-runtimes/unity/tutorials/health-bar"}]},{"title":"Procedural Rendering","href":"/game-runtimes/unity/procedural-rendering"},{"title":"Runtime Asset Swapping","href":"/game-runtimes/unity/runtime-asset-swapping"},{"title":"FAQ","href":"/game-runtimes/unity/faq"},{"group":"Legacy Features","pages":[{"title":"Inputs","href":"/game-runtimes/unity/inputs"},{"title":"Text","href":"/game-runtimes/unity/text"},{"title":"Rive Events","href":"/game-runtimes/unity/rive-events"}]}]},{"group":"Unreal","pages":[{"title":"Unreal Engine","href":"/game-runtimes/unreal/unreal"},{"title":"Getting Started","href":"/game-runtimes/unreal/getting-started"},{"title":"Observing ViewModel Changes","href":"/game-runtimes/unreal/observing-viewmodel-changes"},{"title":"Using Triggers","href":"/game-runtimes/unreal/using-triggers"},{"title":"Runtime Asset Swapping","href":"/game-runtimes/unreal/runtime-asset-swapping"},{"title":"World-Space RenderTargets","href":"/game-runtimes/unreal/in-world-textures"}]},{"group":"C++","pages":[{"title":"C++ Runtime","sidebarTitle":"Overview","href":"/runtimes/cpp/overview"},{"title":"Getting Started","href":"/runtimes/cpp/getting-started"},{"title":"File \u0026 Artboard","href":"/runtimes/cpp/file-and-artboard"},{"title":"State Machines","href":"/runtimes/cpp/state-machines"},{"title":"Data Binding","href":"/runtimes/cpp/data-binding"},{"title":"Asset Loading","href":"/runtimes/cpp/asset-loading"},{"title":"Rendering Loop","href":"/runtimes/cpp/rendering-loop"},{"title":"Command Queue","href":"/runtimes/cpp/command-queue"},{"title":"Renderers","href":"/runtimes/cpp/renderers"},{"title":"External Renderer","href":"/runtimes/cpp/external-renderer"}]},{"title":"Defold","href":"/game-runtimes/defold"},{"group":"Community Runtimes","pages":[{"title":"Angular","href":"/runtimes/community-runtimes/angular"},{"title":"C# (UWP)","href":"/runtimes/community-runtimes/c-sharp"},{"title":"Qt / QtQuick","href":"/runtimes/community-runtimes/qt-quick"},{"title":"RiveCMP","href":"/runtimes/community-runtimes/rive-cmp"}]}]},{"group":"Integrations","pages":[{"title":"3rd Party Integrations","href":"/integrations/overview"},{"title":"HTML Embed","href":"/integrations/html-embed"}]}]},{"tab":"CLI","pages":[{"title":"CLI","href":"/cli/overview"}]},{"tab":" ","pages":[{"title":" ","href":"/tutorials/learn-rive"}]},{"tab":" ","pages":[{"title":" ","href":"/community/support"}]}]},"basePath":"","title":"Text - Rive","buildId":"dpl_3pZeXn3XukjzFRgAX73A7GNDfRJ1","deploymentId":"dpl_3pZeXn3XukjzFRgAX73A7GNDfRJ1","dynamics":["a74be98ba7"],"chunks":["zoom-image-lightbox-g3ZzIKzc.js","lightbox-handle-r17bVUz3.js"]}