String Handling

Siag has string support. Strings can be entered as string constants (text surrounded by quotation marks) or as expressions that evaluate to strings.

The following Scheme functions can be used for strings:

(string-append s1 s2...)
Append the string arguments and return the resulting string.
(substring str start end)
Returns the part of str between start and end.
(string-search token str)
Returns the index of token in str.
(string-trim str)
Removes whitespace from both ends of str.
(string-trim-left str)
Removes whitespace from the beginning of str.
(string-trim-right str)
Removes whitespace from the end of str.
(string-upcase str)
Converts all characters in str to upper case.
(string-downcase str)
Converts all characters in str to lower case.
(get-cell row col)
Returns the value of the cell in (row,col), which may or may not be a string.
(x-get-cell row col buffer)
The same as get-cell, but returns a value from another buffer by specifying the buffer name. The buffer must be loaded.
(get-string row col)
Returns the value of the cell in (row,col) in the form of a string, no matter what is in the cell.
(x-get-string row col buffer)
The same as get-string, but returns a string from another buffer by specifying the buffer name.

Ulric Eriksson - October 1997 - ulric@siag.nu