2004-04-05 20:22:28 +00:00
|
|
|
######################################################################
|
2004-03-25 02:22:11 +00:00
|
|
|
# Copyright (c) 2004, International Business Machines
|
|
|
|
# Corporation and others. All Rights Reserved.
|
|
|
|
######################################################################
|
|
|
|
# Author: Alan Liu
|
|
|
|
# Created: March 15 2004
|
|
|
|
# Since: ICU 3.0
|
|
|
|
######################################################################
|
|
|
|
|
|
|
|
ref= "#.#"
|
|
|
|
|
|
|
|
rt: "0.###" 1.0 "1"
|
|
|
|
|
|
|
|
# Basics
|
|
|
|
fp: "0.####" 0.10005 "0.1" 0.1
|
|
|
|
fp: - 0.10006 "0.1001" 0.1001
|
|
|
|
pat: - "#0.####"
|
|
|
|
fp: "#.####" 0.10005 "0.1" 0.1
|
|
|
|
pat: - "#0.####"
|
|
|
|
|
|
|
|
rt: "0" 1234 "1234"
|
|
|
|
pat: - "#0"
|
|
|
|
|
|
|
|
# Significant digits
|
|
|
|
fp: "@@@" 1.234567 "1.23" 1.23
|
|
|
|
fp: - 1234567 "1230000" 1230000
|
|
|
|
fp: - 0.012345 "0.0123" 0.0123
|
|
|
|
pat: - -
|
|
|
|
fp: "#,@@@" 1234567 "1,230,000" 1230000
|
|
|
|
pat: - "#,@@@"
|
|
|
|
rt: "@@@@" 0.0012 "0.001200"
|
|
|
|
fp: - 0.99999 "1.000" 1
|
|
|
|
pat: - -
|
|
|
|
rt: "@###" 0.00123 "0.00123"
|
|
|
|
rt: - 123000 "123000"
|
|
|
|
fp: - 123456 "123500" 123500
|
|
|
|
fp: - 12.3456 "12.35" 12.35
|
|
|
|
fp: - 0.0123456 "0.01235" 0.01235
|
|
|
|
pat: - -
|
|
|
|
fp: "@,###" 27182 "27,180" 27180
|
|
|
|
rt: - 123000 "123,000"
|
|
|
|
fp: - 0.99999 "1" 1
|
|
|
|
rt: - 0.9999 "0.9999"
|
|
|
|
pat: - -
|
|
|
|
rt: "@##E0" 20000 "2E4"
|
|
|
|
rt: - 27000 "2.7E4"
|
|
|
|
rt: - 27100 "2.71E4"
|
|
|
|
fp: - 27182 "2.72E4" 27200
|
|
|
|
pat: - -
|
|
|
|
rt: "@@@E0" 20000 "2.00E4"
|
|
|
|
rt: - 27000 "2.70E4"
|
|
|
|
rt: - 27100 "2.71E4"
|
|
|
|
fp: - 27182 "2.72E4" 27200
|
|
|
|
pat: - -
|
|
|
|
fp: "#,@@##" 314156 "31,4200" 314200
|
|
|
|
rt: - 3 "3.0"
|
|
|
|
rt: - 5000 "5000"
|
|
|
|
rt: - 0.005 "0.0050"
|
|
|
|
pat: - -
|
2004-04-12 23:38:12 +00:00
|
|
|
fp: "@@@@@@" 123456.7 "123457" 123457
|
|
|
|
pat: - -
|
2004-03-25 02:22:11 +00:00
|
|
|
|
|
|
|
pat: "##,@@##" "#,@@##"
|
|
|
|
pat: "##@@##" "@@##"
|
|
|
|
|
|
|
|
pat: "@@.@@" err # decimal sep. disallowed in sig. digits
|
|
|
|
pat: "@#@" err # only one cluster of sig. digits
|
|
|
|
pat: "@@0" err # either @ or 0, not both
|
|
|
|
|
|
|
|
# NumberRegression/Test4140009
|
|
|
|
rt: "" 123.456 "123.456"
|
|
|
|
rt: "" -123.456 "-123.456"
|
2004-04-15 06:20:42 +00:00
|
|
|
|
|
|
|
# Currency
|
|
|
|
fpc: "\u00A4 0.00" 1234.56/USD "$ 1234.56" 1234.56/USD
|
|
|
|
fpc: - 1234.56/JPY "\u00A5 1235" 1235/JPY
|
|
|
|
# ISO codes that overlap display names (QQQ vs. Q)
|
|
|
|
fpc: - 123/QQQ "QQQ 123.00" 123/QQQ # QQQ is fake
|
|
|
|
fpc: - 123/GTQ "Q 123.00" 123/GTQ
|
|
|
|
# ChoiceFormat-based display names
|
|
|
|
fpc: - 1/INR "Re. 1.00" 1/INR
|
|
|
|
fpc: - 2/INR "Rs. 2.00" 2/INR
|
|
|
|
# Display names with shared prefix (YDD vs. Y)
|
|
|
|
fpc: - 100/YDD "YDD 100.00" 100/YDD
|
|
|
|
fpc: - 100/CNY "Y 100.00" 100/CNY
|