img
4.2. VALUE
21
of two formats: fixed or free. The fixed-format is required for values of mandatory
keywords and is recommended for values of all other keywords.
4.2.1
Character String
A character string value shall be composed only of the set of restricted ASCII text
characters, decimal 32 through 126 (hexadecimal 20 through 7E) enclosed by single
quote characters ("'", decimal 39, hexadecimal 27). A single quote is represented
within a string as two successive single quotes, e.g., O'HARA = 'O' 'HARA'. Leading
spaces are significant; trailing spaces are not. This standard imposes no requirements
on the case sensitivity of character string values unless explicitly stated in the definition
of specific keywords.
If the value is a fixed-format character string, the starting single quote character must
be in byte 11 of the keyword record and the closing single quote must occur in or before
byte 80. Earlier versions of this standard also required that fixed-format characters
strings must be padded with space characters to at least a length of 8 characters so that
the closing quote character does not occur before byte 20. This minimum character
string length is no longer required, except for the value of the XTENSION keyword (e.g.,
' and 'TABLEuuu
'; see §7) which must be padded to a length of 8 characters
'IMAGEuuu
for backward compatibility with previous usage.
Free-format character strings follow the same rules as fixed-format character strings
except that the starting single quote character may occur after byte 11. Any bytes pre-
ceding the starting quote character and after byte 10 must contain the space character.
Note that there is a subtle distinction between the following 3 keywords:
KEYWORD1= ' '
/ null string keyword
KEYWORD2= '
'
/ empty string keyword
KEYWORD3=
/ undefined keyword
The value of KEYWORD1 is a null, or zero length string whereas the value of the KEYWORD2
is an empty string (nominally a single space character because the first space in the
string is significant, but trailing spaces are not). The value of KEYWORD3 is undefined
and has an indeterminate data type as well, except in cases where the data type of the
specified keyword is explicitly defined in this standard.
The maximum possible length of a keyword string is 68 characters (with the opening
and closing quote characters in bytes 11 and 80, respectively). In general, no length
limit less than 68 is implied for character-valued keywords.
4.2.2
Logical
If the value is a fixed-format logical constant, it shall appear as an uppercase T or F in
byte 30. A logical value is represented in free-format by a single character consisting of
FITS Standard