Number::Format - Convert numbers to strings with pretty formatting Version: 1.44 WHAT IS IT Number::Format is a library for formatting numbers. Functions are provided for converting numbers to strings in a variety of ways, and to convert strings that contain numbers back into numeric form. The output formats may include thousands separators - characters inserted between each group of three characters counting right to left from the decimal point. The characters used for the decimal point and the thousands separator come from the locale information or can be specified by the user. Also of note is the format_picture command which converts a number into a string using a "picture" string that you provide. This is similar to the PRINT USING statement that some versions of BASIC have. In addition, functions exist to generate strings for numbers containing currency (e.g. "USD 9.99", "DEM 20.00", etc.) or for rounding large values of bytes to the nearest giga/mega/kilo (e.g. "1.5M", "640K", etc.). HOW TO GET Download it from your favorite CPAN mirror, or from our website: http://www.bayview.com/software/perl.shtml BUILDING/INSTALLING Perl version 5.004 or higher is recommended, though it should work on 5.003. This package is set up to configure and build like a typical Perl extension. To build: perl Makefile.PL make && make test && make install make install NOTE: You may need super-user access to install. PROBLEMS/BUG REPORTS Please send any reports of problems or bugs to wrw@bayview.com. If you can include a patch, it'll increase the chances that the bug will be fixed quickly :-) MAILING LIST We have an electronic mailing list for announcements of new releases of this module. If you wish to join this list, visit this URL: http://lists.bayview.com/listinfo/number-format-announce There is not currently a discussion list, but I'll be happy to create one if there is demand for it. (Yes, I know that Mailman is written in Python, but it's the best mailing list software I know of.) CREDITS AND LICENSES This package is copyright 1997-2001 by William R. Ward and may be distributed under terms of the Artistic License used to cover Perl itself. See the file Artistic in the distribution of Perl 5.002 or later for details of copy and distribution terms. CHANGE HISTORY Changes for version 1.44 (Dec 11, 2001) ------------------------ - Fix bug in format_number caused by the fact that under Perl 5.6, the string representation of a number respects the decimal point defined by the locale. Changes for version 1.43 (Dec 10, 2001) ------------------------ - Fix bug in format_price that caused an extra space to be inserted in some situations, and no space in others, between the currency string and the number. - Add support for gigabytes (formerly only kilo and mega) to format_bytes. [See the file "CHANGES" for previous changes.]