[openi18n-im:01467] Re: key release issue with iiimxcf

AShiZaWa KaZuNoRi <[email protected]> Mon, 11 Jul 2005 14:27:00 +0900
Newsgroups gmane.comp.internationalization.input-methods
Message-ID <[email protected]>
Hi,

Date: Mon, 11 Jul 2005 11:16:38 +0800
From: Federic Zhang <[email protected]>:
> 
> It's really one good idea to use iiimp_inputmethod_descriptor2_new to
> fix the libiiimp.so
> compatibility issue. Thanks a lot for this fix!

I'm glad to know that you think the fix is reasonable.

> 
> Do you think additional change should be made to client framework to fix
> the libiiimcf.so
> compatibility issue?

Client frameworks will be modified to honor the capability of
the server.  This is not implemented yet.

Thanks,
-- 
kasha

> 
> -federic
> 
> 
> > Date: Fri, 08 Jul 2005 14:06:44 +0800
> > From: Federic Zhang <[email protected]>:
> > > 
> > > Thanks for your commit. Can you post it in patch format? It would be
> > > easier for me to take a look at it.
> > 
> > Sure.  This mail include diffs for r2747.
> > 
> > Thanks,
> > -- 
> > kasha
> > 
> > ------------------------------------------------------------------------
> > r2747 | kasha | 2005-07-07 14:36:39 +0900 (Thu, 07 Jul 2005) | 2 lines
> > 
> > fix libiiimp.so compatibility issue - imeinfo
> > 
> > ------------------------------------------------------------------------
> > Index: iiimsf/src/ChangeLog
> > ===================================================================
> > --- iiimsf/src/ChangeLog	(revision 2746)
> > +++ iiimsf/src/ChangeLog	(revision 2747)
> > @@ -1,3 +1,9 @@
> > +2005-07-07  AShiZaWa KaZuNoRi  <[email protected]>
> > +
> > +	* IIIMP_IMState.cpp (create_input_method_descriptors): call
> > +	iiimp_inputmethod_descriptor2_new() instead of
> > +	iiimp_inputmethod_descriptor_new().
> > +
> >  2005-06-30  Federic Zhang <[email protected]>
> >  
> >  	Enable Input Method Engine (IME) switching and display IME list in the language submenu of GIMLET.
> > Index: iiimsf/src/IIIMP_IMState.cpp
> > ===================================================================
> > --- iiimsf/src/IIIMP_IMState.cpp	(revision 2746)
> > +++ iiimsf/src/IIIMP_IMState.cpp	(revision 2747)
> > @@ -568,14 +568,14 @@
> >  	}
> >  
> >  	pil = create_language_list(it->get_languages());
> > -        imeinfo = create_imeinfo_list (it->get_imeinfos());
> > -	pimd2 = iiimp_inputmethod_descriptor_new(pdata_s,
> > -						 it->get_attribid(),
> > -						 pidname,
> > -						 pihrn,
> > -						 pil,
> > -						 pidomain,
> > -						 imeinfo);
> > +	imeinfo = create_imeinfo_list (it->get_imeinfos());
> > +	pimd2 = iiimp_inputmethod_descriptor2_new(pdata_s,
> > +						  it->get_attribid(),
> > +						  pidname,
> > +						  pihrn,
> > +						  pil,
> > +						  pidomain,
> > +						  imeinfo);
> >  
> >  	if (!pimd2) goto memory_error;
> >  
> > Index: include/ChangeLog
> > ===================================================================
> > --- include/ChangeLog	(revision 2746)
> > +++ include/ChangeLog	(revision 2747)
> > @@ -1,3 +1,13 @@
> > +2005-07-07  AShiZaWa KaZuNoRi  <[email protected]>
> > +
> > +	* iiimp/iiimp-data.h: IIIMP_imeinfo - editorial change
> > +	IIIMP_inputmethod_descriptor - editorial change
> > +	iiimp_imeinfo_new() - editorial change
> > +	iiimp_inputmethod_descriptor_new() - revert
> > +	iiimp_inputmethod_descriptor2_new() - new
> > +	iiimp_inputmethod_descriptor_create() - revert
> > +	iiimp_inputmethod_descriptor2_create() - new
> > +	
> >  2005-06-30  Federic Zhang <[email protected]>
> >  
> >  	Enable Input Method Engine (IME) switching and display IME list in the language 
> > Index: include/iiimp/iiimp-data.h
> > ===================================================================
> > --- include/iiimp/iiimp-data.h	(revision 2746)
> > +++ include/iiimp/iiimp-data.h	(revision 2747)
> > @@ -167,17 +167,19 @@
> >  
> >  /* struct to hold the information of Input Method Engine */
> >  typedef struct iiimp_imeinfo {
> > -    size_t			nbyte;
> > -    IIIMP_card32		enable;      /* identify the status of the ime: enable/disable */
> > -    IIIMP_string *		ime_id;      /* unique identification for the ime (in ASCII) */
> > -    IIIMP_string *		imename;     /* the name of ime */
> > -    IIIMP_string *		version;
> > -    IIIMP_string *		description; /* can hold the hinting information */
> > -    IIIMP_string *		author;
> > -    IIIMP_string *		copyright;
> > -    IIIMP_string *		reserved1;   /* Padding for future expansion */
> > -    IIIMP_string *		reserved2;
> > -    struct iiimp_imeinfo *     next;
> > +    size_t		nbyte;
> > +    IIIMP_card32	enable;		/* identify the status of the ime:
> > +					   enable/disable */
> > +    IIIMP_string *	ime_id;		/* unique identification for the ime
> > +					   (in ASCII) */
> > +    IIIMP_string *	imename;	/* the name of ime */
> > +    IIIMP_string *	version;
> > +    IIIMP_string *	description;	/* can hold the hinting information */
> > +    IIIMP_string *	author;
> > +    IIIMP_string *	copyright;
> > +    IIIMP_string *	reserved1;	/* Padding for future expansion */
> > +    IIIMP_string *	reserved2;
> > +    struct iiimp_imeinfo *	next;
> >  } IIIMP_imeinfo;
> >  
> >  typedef struct {
> > @@ -194,9 +196,10 @@
> >      IIIMP_string *	hrn;		/* human readable name */
> >      size_t		language_nbyte;
> >      IIIMP_language *	language;	/* supported language list */
> > -    IIIMP_string *	rdun;	        /* reverse domain unique name */
> > -    size_t              imeinfo_nbyte; 
> > -    IIIMP_imeinfo *     imeinfo;       /* (Optional) the information of input method engine */
> > +    IIIMP_string *	rdun;		/* reverse domain unique name */
> > +    size_t		imeinfo_nbyte; 
> > +    IIIMP_imeinfo *	imeinfo;	/* (Optional) the information of
> > +					   input method engine */
> >      struct iiimp_inputmethod_descriptor *	next;
> >  } IIIMP_inputmethod_descriptor;
> >  
> > @@ -1639,16 +1642,16 @@
> >  
> >  extern IIIMP_imeinfo *
> >  iiimp_imeinfo_new(
> > -    IIIMP_data_s *      data_s,
> > -    IIIMP_card32        enable,
> > -    IIIMP_string *      ime_id,
> > -    IIIMP_string *      imename,
> > -    IIIMP_string *      version,
> > -    IIIMP_string *      description,
> > -    IIIMP_string *      author,
> > -    IIIMP_string *      copyright,
> > -    IIIMP_string *      reserved1,
> > -    IIIMP_string *      reserved2);
> > +    IIIMP_data_s *	data_s,
> > +    IIIMP_card32	enable,
> > +    IIIMP_string *	ime_id,
> > +    IIIMP_string *	imename,
> > +    IIIMP_string *	version,
> > +    IIIMP_string *	description,
> > +    IIIMP_string *	author,
> > +    IIIMP_string *	copyright,
> > +    IIIMP_string *	reserved1,
> > +    IIIMP_string *	reserved2);
> >  
> >  extern IIIMP_jarfile_object *
> >  iiimp_jarfile_object_new(
> > @@ -1664,8 +1667,17 @@
> >      IIIMP_string *	idname,
> >      IIIMP_string *	hrn,
> >      IIIMP_language *	language,
> > +    IIIMP_string *	rdun);
> > +
> > +extern IIIMP_inputmethod_descriptor *
> > +iiimp_inputmethod_descriptor2_new(
> > +    IIIMP_data_s *	data_s,
> > +    IIIMP_card16	id,
> > +    IIIMP_string *	idname,
> > +    IIIMP_string *	hrn,
> > +    IIIMP_language *	language,
> >      IIIMP_string *	rdun,
> > -    IIIMP_imeinfo *     imeinfo);
> > +    IIIMP_imeinfo *	imeinfo);
> >  
> >  extern IIIMP_binaryfile_object *
> >  iiimp_binaryfile_object_new(
> > @@ -2581,6 +2593,16 @@
> >      IIIMP_string *			idname,
> >      IIIMP_string *			hrn,
> >      IIIMP_language *			language,
> > +    IIIMP_string *			rdun);
> > +
> > +extern IIIMP_status
> > +iiimp_inputmethod_descriptor2_create(
> > +    IIIMP_data_s *			data_s,
> > +    IIIMP_inputmethod_descriptor **	ptr_ret,
> > +    IIIMP_card16			id,
> > +    IIIMP_string *			idname,
> > +    IIIMP_string *			hrn,
> > +    IIIMP_language *			language,
> >      IIIMP_string *			rdun,
> >      IIIMP_imeinfo *			imeinfo);
> >  
> > Index: lib/iiimp/ChangeLog
> > ===================================================================
> > --- lib/iiimp/ChangeLog	(revision 2746)
> > +++ lib/iiimp/ChangeLog	(revision 2747)
> > @@ -1,3 +1,13 @@
> > +2005-07-07  AShiZaWa KaZuNoRi  <[email protected]>
> > +
> > +	* data/comp-inputmethod-descriptor.c
> > +	(iiimp_inputmethod_descriptor_new): revert to original argument
> > +	(iiimp_inputmethod_descriptor2_new): new to support imeinfo
> > +	* data/comp-misc.c (iiimp_inputmethod_descriptor2_create):
> > +	iiimp_inputmethod_descriptor_create() - revert
> > +	iiimp_inputmethod_descriptor2_create() - new
> > +	* data/iiimp-dataP.h: editorial changes
> > +
> >  2005-06-21  Federic Zhang <[email protected]>
> >  
> >  	Export the information of input method engine to client.
> > Index: lib/iiimp/data/iiimp-dataP.h
> > ===================================================================
> > --- lib/iiimp/data/iiimp-dataP.h	(revision 2746)
> > +++ lib/iiimp/data/iiimp-dataP.h	(revision 2747)
> > @@ -418,8 +418,8 @@
> >  IIIMP_ccdef *			iiimp_ccdef_unpack(IIIMP_dal);
> >  IIIMP_language *		iiimp_language_unpack(IIIMP_dal);
> >  IIIMP_language *		iiimp_language_list_unpack(IIIMP_dal);
> > -IIIMP_imeinfo *        	iiimp_imeinfo_unpack(IIIMP_dal); 
> > -IIIMP_imeinfo *        	iiimp_imeinfo_list_unpack(IIIMP_dal);
> > +IIIMP_imeinfo *			iiimp_imeinfo_unpack(IIIMP_dal); 
> > +IIIMP_imeinfo *			iiimp_imeinfo_list_unpack(IIIMP_dal);
> >  IIIMP_jarfile_object *		iiimp_jarfile_object_unpack(IIIMP_dal);
> >  IIIMP_inputmethod_descriptor *	iiimp_inputmethod_descriptor_unpack(IIIMP_dal);
> >  IIIMP_inputmethod_descriptor *	iiimp_inputmethod_descriptor_list_unpack(IIIMP_dal);
> > @@ -616,15 +616,15 @@
> >  
> >  extern void     iiimp_imeinfo_pack(
> >      IIIMP_data_s *              data_s,
> > -    IIIMP_imeinfo *    m,
> > -    size_t *            nbyte,
> > -    uchar_t **          ptr);
> > +    IIIMP_imeinfo *	m,
> > +    size_t *		nbyte,
> > +    uchar_t **		ptr);
> >  
> >  extern void     iiimp_imeinfo_list_pack(
> >      IIIMP_data_s *              data_s,
> > -    IIIMP_imeinfo *    m,
> > -    size_t *            nbyte,
> > -    uchar_t **          ptr);
> > +    IIIMP_imeinfo *	m,
> > +    size_t *		nbyte,
> > +    uchar_t **		ptr);
> >  
> >  extern void	iiimp_jarfile_object_pack(
> >      IIIMP_data_s *		data_s,
> > Index: lib/iiimp/data/comp-misc.c
> > ===================================================================
> > --- lib/iiimp/data/comp-misc.c	(revision 2746)
> > +++ lib/iiimp/data/comp-misc.c	(revision 2747)
> > @@ -590,11 +590,27 @@
> >      IIIMP_string *			idname,
> >      IIIMP_string *			hrn,
> >      IIIMP_language *			language,
> > +    IIIMP_string *			rdun)
> > +{
> > +    *ptr_ret = iiimp_inputmethod_descriptor_new(data_s, id, idname, hrn,
> > +						language, rdun);
> > +    return ((NULL == *ptr_ret) ? data_s->status : IIIMP_DATA_NO_ERROR);
> > +}
> > +
> > +
> > +IIIMP_status
> > +iiimp_inputmethod_descriptor2_create(
> > +    IIIMP_data_s *			data_s,
> > +    IIIMP_inputmethod_descriptor **	ptr_ret,
> > +    IIIMP_card16			id,
> > +    IIIMP_string *			idname,
> > +    IIIMP_string *			hrn,
> > +    IIIMP_language *			language,
> >      IIIMP_string *			rdun,
> >      IIIMP_imeinfo *			imeinfo)
> >  {
> > -    *ptr_ret = iiimp_inputmethod_descriptor_new(data_s, id, idname, hrn,
> > -						language, rdun, imeinfo);
> > +    *ptr_ret = iiimp_inputmethod_descriptor2_new(data_s, id, idname, hrn,
> > +						 language, rdun, imeinfo);
> >      return ((NULL == *ptr_ret) ? data_s->status : IIIMP_DATA_NO_ERROR);
> >  }
> >  
> > Index: lib/iiimp/data/comp-inputmethod-descriptor.c
> > ===================================================================
> > --- lib/iiimp/data/comp-inputmethod-descriptor.c	(revision 2746)
> > +++ lib/iiimp/data/comp-inputmethod-descriptor.c	(revision 2747)
> > @@ -15,6 +15,20 @@
> >      IIIMP_string *	idname,
> >      IIIMP_string *	hrn,
> >      IIIMP_language *	language,
> > +    IIIMP_string *	rdun)
> > +{
> > +    return iiimp_inputmethod_descriptor2_new(data_s, id, idname, hrn,
> > +					     language, rdun, NULL);
> > +}
> > +
> > +
> > +IIIMP_inputmethod_descriptor *
> > +iiimp_inputmethod_descriptor2_new(
> > +    IIIMP_data_s *	data_s,
> > +    IIIMP_card16	id,
> > +    IIIMP_string *	idname,
> > +    IIIMP_string *	hrn,
> > +    IIIMP_language *	language,
> >      IIIMP_string *	rdun,
> >      IIIMP_imeinfo *	imeinfo)
> >  {