Main Page   Modules   Data Structures   Globals   Appendix  

m17n-misc.h

Go to the documentation of this file.
00001 /* m17n-misc.h -- header file for the MISC API.
00002    Copyright (C) 2003, 2004
00003      National Institute of Advanced Industrial Science and Technology (AIST)
00004      Registration Number H15PRO112
00005 
00006    This file is part of the m17n library.
00007 
00008    The m17n library is free software; you can redistribute it and/or
00009    modify it under the terms of the GNU Lesser General Public License
00010    as published by the Free Software Foundation; either version 2.1 of
00011    the License, or (at your option) any later version.
00012 
00013    The m17n library is distributed in the hope that it will be useful,
00014    but WITHOUT ANY WARRANTY; without even the implied warranty of
00015    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00016    Lesser General Public License for more details.
00017 
00018    You should have received a copy of the GNU Lesser General Public
00019    License along with the m17n library; if not, write to the Free
00020    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
00021    02111-1307, USA.  */
00022 
00023 #ifndef _M17N_ERR_H_
00024 #define _M17N_ERR_H_
00025 
00026 /*** @defgroup m17nMisc MISC API */
00027 /*=*/
00028 /*** @ingroup m17nMisc  */
00029 /***en @defgroup m17nError Error Handling */
00030 /***ja @defgroup m17nError エラー処理  */
00031 /*=*/
00032 
00033 /*** @ingroup m17nError */
00034 /***en 
00035     @brief Enumeration for error code of the m17n library.
00036 
00037     Enumeration for error code of the m17n library.
00038 
00039     When a library function is called with an invalid argument, it
00040     sets the external variable @e merror_code to one of these values.
00041     All the error codes are positive integers.
00042 
00043     When a memory allocation error happens, the function pointed to by
00044     the external variable #m17n_memory_full_handler is called with one
00045     of these values as an argument.  */
00046 
00047 /***ja 
00048     @brief m17n ライブラリエラーコードの列挙
00049 
00050     m17n ライブラリエラーコードの列挙
00051 
00052     ライブラリの関数が妥当でない引数とともに呼ばれた場合には、変数 @c
00053     merror_code をこれらの値のどれかにセットする。すべてのエラーコード
00054     は正の整数である。
00055 
00056     メモリ割当てエラーの際には、外部変数 #m17n_memory_full_handler の指
00057     す関数が、これらの値のうちのどれかを引数として呼ばれる。
00058     */
00059 
00060 enum MErrorCode
00061   {
00062     MERROR_NONE,
00063     MERROR_OBJECT,
00064     MERROR_SYMBOL,
00065     MERROR_MTEXT,
00066     MERROR_TEXTPROP,
00067     MERROR_CHAR,
00068     MERROR_CHARTABLE,
00069     MERROR_CHARSET,
00070     MERROR_CODING,
00071     MERROR_RANGE,
00072     MERROR_LANGUAGE,
00073     MERROR_LOCALE,
00074     MERROR_PLIST,
00075     MERROR_MISC,
00076     MERROR_WIN,
00077     MERROR_X,
00078     MERROR_FRAME,
00079     MERROR_FACE,
00080     MERROR_DRAW,
00081     MERROR_FONT,
00082     MERROR_FONTSET,
00083     MERROR_FONT_OTF,
00084     MERROR_FONT_FT,
00085     MERROR_IM,
00086     MERROR_DB,
00087     MERROR_IO,
00088     MERROR_DEBUG,
00089     MERROR_MEMORY,
00090     MERROR_MAX
00091   };
00092 
00093 /*=*/
00094 
00095 extern enum MErrorCode merror_code;
00096 
00097 extern void (*m17n_memory_full_handler) (enum MErrorCode err);
00098 
00099 /*=*/
00100 /*** @ingroup m17nMisc  */
00101 /***en @defgroup m17nDebug Debugging */
00102 /***ja @defgroup m17nDebug デバッグサポート */
00103 /*=*/
00104 
00105 extern int mdebug_hook (void);
00106 
00107 extern MSymbol mdebug_dump_symbol (MSymbol sym, int indent);
00108 extern MSymbol mdebug_dump_all_symbols (int indent);
00109 extern MPlist *mdebug_dump_plist (MPlist *plist, int indent);
00110 extern MText *mdebug_dump_mtext (MText *mt, int fullp, int indent);
00111 extern MCharTable *mdebug_dump_chartab (MCharTable *table, int indent);
00112 
00113 #ifdef DOXYGEN_INTERNAL_MODULE
00114 /***en @defgroup m17nInternal Internal */
00115 /***ja @defgroup m17nInternal Internal */
00116 #endif
00117 #endif /* _M17N_ERR_H_ */
00118 
00119 /*
00120   Local Variables:
00121   coding: euc-japan
00122   End:
00123 */

Top of this page

Main Page   Modules   Data Structures   Globals   Appendix  

mulemark mule-aist@m17n.org