Unlike other item object attributes, $Text is stored if/when present for the object, in the 'text' tag. The contents is unstyled UTF-8 text. Unix-style line breaks (\n, link feed), such as are found for paragraph breaks, are not XML encoded.
Basic styling, of font/bold/italic/underline, is stored separately as offset character runs in the separate styles tag.
To allow for the wider range of text styling in v5, e.g. sub-/super-script, strikethrough, highlighting etc., Tinderbox $Text is also stored as encoded RTF text in the 'rtf' tag (but only if the text is added via the objects text window). $Text created via drag/drop import or action code is saved as unstyled text with a 'styles' tag but not 'rtf' tag.
Thus adding $Text, created text & styles tag but the rtf tag is only created if working on $Text via a text window.
Re-editing $Text without an rtf tag via a text window will cause it to add a saved rtf tag. Conversely, editing rich text $Text via action code will make it unstyled (or partially styled) text and the rtf tag will be removed.
Deleting all text deletes all the text/styles/rtf tags.
Embedded images in $Text are stored as JPEGs, in Base 64 form.