Back to index

im-sdk  12.3.91
XlcPubI.h
Go to the documentation of this file.
00001 /* $XConsortium: XlcPubI.h,v 1.4 95/02/22 22:02:55 kaleb Exp $ */
00002 /*
00003  * Copyright 1992, 1993 by TOSHIBA Corp.
00004  *
00005  * Permission to use, copy, modify, and distribute this software and its
00006  * documentation for any purpose and without fee is hereby granted, provided
00007  * that the above copyright notice appear in all copies and that both that
00008  * copyright notice and this permission notice appear in supporting
00009  * documentation, and that the name of TOSHIBA not be used in advertising
00010  * or publicity pertaining to distribution of the software without specific,
00011  * written prior permission. TOSHIBA make no representations about the
00012  * suitability of this software for any purpose.  It is provided "as is"
00013  * without express or implied warranty.
00014  *
00015  * TOSHIBA DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
00016  * ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
00017  * TOSHIBA BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
00018  * ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
00019  * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
00020  * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
00021  * SOFTWARE.
00022  *
00023  * Author: Katsuhisa Yano   TOSHIBA Corp.
00024  *                          mopi@osa.ilab.toshiba.co.jp
00025  */
00026 
00027 #ifndef _XLCPUBLICI_H_
00028 #define _XLCPUBLICI_H_
00029 
00030 #include "XlcPublic.h"
00031 
00032 #define XLC_PUBLIC(lcd, x)  (((XLCdPublic) lcd->core)->pub.x)
00033 #define XLC_PUBLIC_PART(lcd)       (&(((XLCdPublic) lcd->core)->pub))
00034 #define XLC_PUBLIC_METHODS(lcd)    (&(((XLCdPublicMethods) lcd->methods)->pub))
00035 
00036 /*
00037  * XLCd public methods
00038  */
00039 
00040 typedef struct _XLCdPublicMethodsRec *XLCdPublicMethods;
00041 
00042 typedef XLCd (*XlcPubCreateProc)(
00043 #if NeedFunctionPrototypes
00044     char*            /* name */,
00045     XLCdMethods             /* methods */
00046 #endif
00047 );
00048 
00049 typedef Bool (*XlcPubInitializeProc)(
00050 #if NeedFunctionPrototypes
00051     XLCd             /* lcd */
00052 #endif
00053 );
00054 
00055 typedef void (*XlcPubDestroyProc)(
00056 #if NeedFunctionPrototypes
00057     XLCd             /* lcd */
00058 #endif
00059 );
00060 
00061 typedef char* (*XlcPubGetValuesProc)(
00062 #if NeedFunctionPrototypes
00063     XLCd             /* lcd */,
00064     XlcArgList              /* args */,
00065     int                     /* num_args */
00066 #endif
00067 );
00068 
00069 typedef void (*XlcPubGetResourceProc)(
00070 #if NeedFunctionPrototypes
00071     XLCd             /* lcd */,
00072     char*            /* category */,
00073     char*            /* class */,
00074     char***          /* value */,
00075     int*             /* count */
00076 #endif
00077 );
00078 
00079 typedef struct _XLCdPublicMethodsPart {
00080     XLCdPublicMethods superclass;
00081     XlcPubCreateProc create;
00082     XlcPubInitializeProc initialize;
00083     XlcPubDestroyProc destroy;
00084     XlcPubGetValuesProc get_values;
00085     XlcPubGetResourceProc get_resource;
00086 } XLCdPublicMethodsPart;
00087 
00088 typedef struct _XLCdPublicMethodsRec {
00089     XLCdMethodsRec core;
00090     XLCdPublicMethodsPart pub;
00091 } XLCdPublicMethodsRec;
00092 
00093 /*
00094  * XLCd public data
00095  */
00096 
00097 typedef struct _XLCdPublicPart {
00098     char *siname;                  /* for _XlcMapOSLocaleName() */
00099     char *language;                /* language part of locale name */
00100     char *territory;               /* territory part of locale name */
00101     char *codeset;                 /* codeset part of locale name */
00102     char *encoding_name;           /* encoding name */
00103     int mb_cur_max;                /* ANSI C MB_CUR_MAX */
00104     Bool is_state_depend;          /* state-depend encoding */
00105     char *default_string;          /* for XDefaultString() */
00106     XPointer xlocale_db;
00107 } XLCdPublicPart;
00108 
00109 typedef struct _XLCdPublicRec {
00110     XLCdCoreRec core;       
00111     XLCdPublicPart pub;
00112 } XLCdPublicRec, *XLCdPublic;
00113 
00114 extern XLCdMethods _XlcPublicMethods;
00115 
00116 _XFUNCPROTOBEGIN
00117 
00118 extern XLCd _XlcCreateLC(
00119 #if NeedFunctionPrototypes
00120     char*            /* name */,
00121     XLCdMethods             /* methods */
00122 #endif
00123 );
00124 
00125 extern void _XlcDestroyLC(
00126 #if NeedFunctionPrototypes
00127     XLCd             /* lcd */
00128 #endif
00129 );
00130 
00131 extern Bool _XlcParseCharSet(
00132 #if NeedFunctionPrototypes
00133     XlcCharSet              /* charset */
00134 #endif
00135 );
00136 
00137 extern XlcCharSet _XlcCreateDefaultCharSet(
00138 #if NeedFunctionPrototypes
00139     char*            /* name */,
00140     char*            /* control_sequence */
00141 #endif
00142 );
00143 
00144 extern XlcCharSet _XlcAddCT(
00145 #if NeedFunctionPrototypes
00146     char*            /* name */,
00147     char*            /* control_sequence */
00148 #endif
00149 );
00150 
00151 extern XrmMethods _XrmDefaultInitParseInfo(
00152 #if NeedFunctionPrototypes
00153     XLCd             /* lcd */,
00154     XPointer*        /* state */
00155 #endif
00156 );
00157 
00158 extern int _XmbTextPropertyToTextList(
00159 #if NeedFunctionPrototypes
00160     XLCd             /* lcd */,
00161     Display*         /* dpy */,
00162     XTextProperty*   /* text_prop */,
00163     char***          /* list_ret */,
00164     int*             /* count_ret */
00165 #endif
00166 );
00167 
00168 extern int _XwcTextPropertyToTextList(
00169 #if NeedFunctionPrototypes
00170     XLCd             /* lcd */,
00171     Display*         /* dpy */,
00172     XTextProperty*   /* text_prop */,
00173     wchar_t***              /* list_ret */,
00174     int*             /* count_ret */
00175 #endif
00176 );
00177 
00178 extern int _XmbTextListToTextProperty(
00179 #if NeedFunctionPrototypes
00180     XLCd             /* lcd */,
00181     Display*         /* dpy */,
00182     char**           /* list */,
00183     int                     /* count */,
00184     XICCEncodingStyle       /* style */,
00185     XTextProperty*   /* text_prop */
00186 #endif
00187 );
00188 
00189 extern int _XwcTextListToTextProperty(
00190 #if NeedFunctionPrototypes
00191     XLCd             /* lcd */,
00192     Display*         /* dpy */,
00193     wchar_t**        /* list */,
00194     int                     /* count */,
00195     XICCEncodingStyle       /* style */,
00196     XTextProperty*   /* text_prop */
00197 #endif
00198 );
00199 
00200 extern void _XwcFreeStringList(
00201 #if NeedFunctionPrototypes
00202     XLCd             /* lcd */,
00203     wchar_t**        /* list */
00204 #endif
00205 );
00206 
00207 extern int _XlcResolveLocaleName(
00208 #if NeedFunctionPrototypes
00209     const char*             /* lc_name */,
00210     char*            /* full_name */,
00211     char*            /* language */,
00212     char*            /* territory */,
00213     char*            /* codeset */
00214 #endif
00215 );
00216 
00217 extern int _XlcResolveDBName(
00218 #if NeedFunctionPrototypes
00219     const char*             /* lc_name */,
00220     char*            /* file_name */
00221 #endif
00222 );
00223 
00224 extern int _XlcResolveI18NPath(
00225 #if NeedFunctionPrototypes
00226     char*            /* path_name */
00227 #endif
00228 );
00229 
00230 extern XPointer _XlcCreateLocaleDataBase(
00231 #if NeedFunctionPrototypes
00232     XLCd             /* lcd */
00233 #endif
00234 );
00235 
00236 extern void _XlcDestroyLocaleDataBase(
00237 #if NeedFunctionPrototypes
00238     XLCd             /* lcd */
00239 #endif
00240 );
00241 
00242 extern void _XlcGetLocaleDataBase(
00243 #if NeedFunctionPrototypes
00244     XLCd             /* lcd */,
00245     char*            /* category */,
00246     char*            /* name */,
00247     char***          /* value */,
00248     int*             /* count */
00249 #endif
00250 );
00251 
00252 _XFUNCPROTOEND
00253 
00254 #endif  /* _XLCPUBLICI_H_ */