Initial import of the CDE 2.1.30 sources from the Open Group.
[oweals/cde.git] / cde / programs / dtcm / dtcm / cm_i18n.h
1 /*******************************************************************************
2 **
3 **  cm_i18n.h
4 **
5 **  static char sccsid[] = "@(#)cm_i18n.h 1.7 94/12/22 Copyr 1991 Sun Microsystems, Inc.";
6 **
7 **  $XConsortium: cm_i18n.h /main/4 1996/11/07 17:00:36 drk $
8 **
9 **  RESTRICTED CONFIDENTIAL INFORMATION:
10 **
11 **  The information in this document is subject to special
12 **  restrictions in a confidential disclosure agreement between
13 **  HP, IBM, Sun, USL, SCO and Univel.  Do not distribute this
14 **  document outside HP, IBM, Sun, USL, SCO, or Univel without
15 **  Sun's specific written approval.  This document and all copies
16 **  and derivative works thereof must be returned or destroyed at
17 **  Sun's request.
18 **
19 **  Copyright 1993 Sun Microsystems, Inc.  All rights reserved.
20 **
21 *******************************************************************************/
22
23 /*                                                                      *
24  * (c) Copyright 1993, 1994 Hewlett-Packard Company                     *
25  * (c) Copyright 1993, 1994 International Business Machines Corp.       *
26  * (c) Copyright 1993, 1994 Sun Microsystems, Inc.                      *
27  * (c) Copyright 1993, 1994 Novell, Inc.                                *
28  */
29
30 #ifndef _FILENAME
31 #define _FILENAME
32 #endif
33
34 /* CM font file description:
35  *
36  * Each line cannot exceed MAX_LINE_LEN. 
37  * File format is as follows: 
38  * <Locale name> <fontset1_fontname1> <fontset2_fontname1>
39  *               <fontset1_fontname2> <fontset2_fontname2>
40  * Line starts at left most margin.
41  * Categories separated by space(s).
42  * Comment lines start with an '%'
43  */
44
45
46 #define MAX_LINE_LEN    128
47 #define MAX_FONT_LEN    40
48 #define COMMENT_SYMBOL  "%"
49 #define CHAR_SIZE       sizeof(char)
50 #define isEUC(c)    ((c) & 0x80 ? TRUE : FALSE)
51
52 /* cm_get_fonts()'s return values */
53 #define OPEN_FAIL         -1
54 #define NO_LOCALE_ENTRY   -2 
55 #define EXTRACT_FAIL      -3
56 #define OKAY               1
57 #define NO_I18N_HEADER     2
58
59 extern char *fontset1[];
60 extern char *fontset2[];
61 extern int use_default_fonts;
62 extern int use_octal;
63
64 extern int cm_get_fonts(/* char * */); 
65 extern void ps_i18n_header(/* FILE *, Frame */);
66 extern char *euc_to_octal(/* char * */);
67 extern char *cm_get_i18n_date(/* Frame, char * */);
68 extern char *cm_printf();
69
70 int is_comment();
71 int match_locale();
72
73 extern int      cm_get_fonts            P((char *));
74 extern int      is_comment              P((char[MAX_LINE_LEN]));
75 extern int      match_locale            P((char *, char[MAX_LINE_LEN]));
76 extern void     ps_i18n_header          P((FILE *, Widget));
77 extern char*    euc_to_octal            P((char *));
78 extern char*    cm_get_i18n_date        P((Widget, char *));
79 extern char*    cm_printf               P((double, int));