Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ montbl(1M) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

localeconv(3C)

setlocale(3C)

montbl(1M)                                                       montbl(1M)

NAME
     montbl - create monetary database

SYNOPSIS
     montbl [-o outfile] infile

DESCRIPTION
     The montbl command takes as input a specification file, infile, that
     describes the formatting conventions for monetary quantities for a
     specific locale.

OPTIONS
     -o outfile     Write the output on outfile; otherwise, write the out-
                    put on a file named LCMONETARY.

     The output of montbl is suitable for use by the localeconv() function
     [see localeconv(3C)]. Before outfile can be used by localeconv(), it
     must be installed in the /usr/lib/locale/locale directory with the
     name LCMONETARY by someone who is superuser or a member of group bin.
     locale is the locale whose monetary formatting conventions are
     described in infile. This file must be readable by user, group, and
     other; no other permissions should be set. To use formatting conven-
     tions for monetary quantities described in this file, use
     setlocale(3C) to change the locale for category LCMONETARY to locale
     [see setlocale(3C)].

     Once installed, this file will be used by the localeconv() function to
     initialize the monetary specific fields of a structure of type struct
     lconv. For a description of each field in this structure, see
     localeconv(3C).

          struct lconv
          {
              char *decimalpoint;      /* "." */
              char *thousandssep;      /* "" (zero length string) */
              char *grouping;           /* "" */
              char *intcurrsymbol;    /* "" */
              char *currencysymbol;    /* "" */
              char *mondecimalpoint;  /* "" */
              char *monthousandssep;  /* "" */
              char *mongrouping;       /* "" */
              char *positivesign;      /* "" */
              char *negativesign;      /* "" */
              char intfracdigits;     /* CHARMAX */
              char fracdigits;         /* CHARMAX */
              char pcsprecedes;       /* CHARMAX */
              char psepbyspace;      /* CHARMAX */
              char ncsprecedes;       /* CHARMAX */
              char nsepbyspace;      /* CHARMAX */
              char psignposn;         /* CHARMAX */
              char nsignposn;         /* CHARMAX */
          };



Page 1                       Reliant UNIX 5.44                Printed 11/98

montbl(1M)                                                       montbl(1M)

     The specification file specifies the value of each struct lconv
     member, except for the first three members, decimalpoint,
     thousandssep, and grouping which are set by the LCNUMERIC category
     of setlocale(3C). Each member's value is given on a line with the fol-
     lowing format:

          keyword <white space> value

     where keyword is identical to the struct lconv field name and value is
     a quoted string for those fields that are a char * and an integer for
     those fields that are an int. For example,

          intcurrsymbol    "ITL."
          intfracdigits    0

     will set the international currency symbol and the number of frac-
     tional digits to be displayed in an internationally formatted monetary
     quantity to ITL. and 0, respectively.

     Blank lines and lines starting with a # are taken to be comments and
     are ignored. A character in a string may be in octal or hex represen-
     tation. For example, \141 or \x61 could be used to represent the
     letter "a". If there is no specification line for a given structure
     member, then the default "C" locale value for that member is used (see
     the values in comments in the struct lconv definition above).

     Given below is an example of what the specification file for Italy
     would look like:

          # Italy

          intcurrsymbol    "ITL."
          currencysymbol    "L."
          mondecimalpoint  ""
          monthousandssep  "."
          mongrouping       "\3"
          positivesign      ""
          negativesign      "-"
          intfracdigits    0
          fracdigits        0
          pcsprecedes      1
          psepbyspace     0
          ncsprecedes      1
          nsepbyspace     0
          psignposn        1
          nsignposn        1








Page 2                       Reliant UNIX 5.44                Printed 11/98

montbl(1M)                                                       montbl(1M)

LOCALE
     The LCMESSAGES environment variable governs the language in which
     message texts are displayed.

     If LCMESSAGES is undefined or is defined as the null string, it
     defaults to the value of LANG. If LANG is likewise undefined or null,
     the system acts as if it were not internationalized.

     If any of the locale variables has an invalid value, the system acts
     as if none of the variables was set.

     The LCALL environment variable governs the entire locale. LCALL
     takes precedence over all the other environment variables which affect
     internationalization.

FILES
     /usr/lib/locale/locale/LCMONETARY
          LCMONETARY database for locale

     /usr/lib/locale/C/montblC
          input file used to construct LCMONETARY in the default locale

SEE ALSO
     localeconv(3C), setlocale(3C).






























Page 3                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026