Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Text /
Appendix B - International Resources


Numeric-Format Resource (Type 'itl0')

The numeric-format resource (resource type 'itl0') contains general conventions for formatting numeric strings. It provides separators for decimals, thousands, and lists; it determines currency symbols and units of measurement; it specifies formats for currency, times, and short dates (the specification of dates in purely numeric representation--for example, in the U.S. Roman script system the short date for Tuesday, December 3, 1946, is 12/3/46). It also contains the region code for this particular instance of the 'itl0' resource.

Each enabled script system has one or more numeric-format resources. The resource ID for each one is within the range of resource ID numbers for that script system. The default numeric-format resource for a script is specified in the itlbNumber field of the script's international bundle ('itlb') resource.

The Text Utilities routines TimeString, LongTimeString, and StringToTime use information in the numeric-format resource to create time strings and to convert time strings to internal numeric representations. See the chapter "Text Utilities" in this book. The Operating System Utilities function IsMetric examines the numeric-format resource to determine the result it returns. See Inside Macintosh: OSUtilities.

Each numeric-format resource specifies the following:

Table B-4 lists constants that you can use in the numeric-format and long-date-format resources to specify separators for standard international formats. For example, in the U.S., slashSymbol is the separator for the short date 12/3/46, but in Germany periodSymbol is the separator for the short date 3.12.1946.
Table B-4 Constants for specifying numeric separators
ConstantSymbol
periodSymbol.
commaSymbol,
semicolonSymbol;
dollarsignSymbol$
slashSymbol/
colonSymbol:

IMPORTANT
When it specifies the order of elements, the numeric-format resource describes them in terms of storage order, not display order. Using the information in a numeric-format resource frees you from assuming a particular memory order for the components of numbers and short dates. However, the resource does not necessarily specify the left-to-right order for displaying the components.

Subtopics
The Intl0Rec Data Type

Previous Book Contents Book Index Next

© Apple Computer, Inc.
6 JUL 1996