Previous Page
Next Page

16.1. Strings

return

"\r"

"\r"

Macintosh line-break character. There does not seem to be any conflict with the keyword return (see "Returned Value" in Chapter 9). The only place where a conflict could occur is when return is the first word of a line. The rule in that situation seems to be that if return is followed by an operator, it can't be the keyword, so it must be this property.

Example

"This is a line." & return & "This is another line."

tab

"\t"

"\t"

Tab character.

Example

"an item" & tab & "another item"

quote

"\""

"\""

Quote character. (This is new in Tiger.)

Example

quote & "This is cool," & quote & " said Tom frigidly."

space

" "

" "

Space character.

Example

"word" & space & "otherWord"

text item delimiters

"" (the empty string)

"" (the empty string)

The text item delimiters global property has two uses: it is used to split a string into its text item elements (see "String" in Chapter 13), and it is used to join list items when a list is coerced to a string (see "List Coercions" in Chapter 14). In theory it is a list of strings, but in fact it can be set to a string, and if it is a list, only the first item of the list matters.

Example

set text item delimiters to ":"
text item 1 of (path to system folder as string)


Previous Page
Next Page