![]() |
|
||||
Decimal Shifting |
|||||
FeatureGoldenseal 3.3 adds the option to shift decimal displays. It allows you to increase the size of currency values that Goldenseal can handle. Suggested ByA user in Indonesia. When to UseUse decimal shifting if you need to use currency amounts over 2 billion. That may be necessary if you work on extremely large projects, or if you are in a country with a currency unit that is small relative to the US dollar. When you use decimal shifting, you lose some accuracy in the fractional part of money values, but then gain it on the other end. How to UseTo shift decimal digits, follow these steps:
Technical DetailsGoldenseal stores money values using a 32-bit signed number for the larger "dollar" portion, and a 16-bit signed number for the smaller "penny portion. There is an "overflow" bit in the larger part of the money value, which allows Goldenseal to store "dollar" values up to 2,000,000,000 (two billion), and "penny" values to .0001 (four decimals, or 1/100 of a penny).When you shift currency values by one digit, you can show dollar values up to 20,000,000,000 (twenty billion) and penny v alues down to .001 (three decimals, or 1/10 of a penny).When you shift currency values by two digits, you can show dollar values up to 200,000,000,000 (two hundred billion) and penny values down to .01 (two decimals, or one penny).When you shift currency values by three digits, you can show dollar values up to 2,000,000,000,000 (two trillion) and penny values down to .1 (one decimal, or 10 pennies).When you shift currency values by four digits,
you can show dollar values up to 20,000,000,000,000 (twenty
trillion) and no decimal values at all.
|