Josef Kučera | 1 May 2007 13:01
Picon

Unicode support for Status Mode Messages

Hello all,
there is two major ideas how to implement unicode support for Status Mode Messages, I just wanted to sumarize that and perhaps get some new points for this.
 
All core protocols except AIM & ICQ knows status messages and stores them in DB... so the best for them is idea 1), ICQ and AIM otherwise does not know the real status message, and for each time it requests the message from server/client.
 
Here is the summary:
1) use Unicode support in DB as define some resident variable, which will be used to comunicate this to other plugins.
2) define some PS_GETCAPS flags and use this to detect the same Unicode formatted hack in current ACKTYPE_AWAYMSG.
 
The idea 2) is awful in realisation, but provides the easiest solution for ICQ - just because with idea 1) ICQ has a problem: either keep outdated status msg in DB, or delete it after broadcasting an ack... either way it is a wrong way to go...
 
So what I think about this:
- define two new PS_GETCAPS
- one e.g. PF1_AWAYMSG_DB, which notes idea 1) and no PSS_GETAWAYMSG or ACKTYPE_AWAYMSG is necessary
- second e.g. PF1_AWAYMSG_UNICODE for idea 2) where it will not be stored in DB, but broadcasted using ACKTYPE_AWAYMSG with Unicode hack same as the one for message blob
- with Miranda IM 0.8+ we can safely remove all that "hack" code PSS_GETAWAYMSG for MSN and others, which only reads the status message from DB and broadcasts it...
 
So, what do you think about this ?
 
Have a nice day,
Joe <at> Whale
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop
borkra | 1 May 2007 13:49
Picon

Re: Unicode support for Status Mode Messages

Joe,
 
I was under an impression that the plan was to change all strings in Miranda from ASCII to UTF8, and this would resolve problem with status messages as well as many others.
Have it changed?

From: miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org] On Behalf Of Josef Kucera
Sent: Tuesday, May 01, 2007 6:01 AM
To: miranda-develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: [Miranda-Develop] Unicode support for Status Mode Messages

Hello all,
there is two major ideas how to implement unicode support for Status Mode Messages, I just wanted to sumarize that and perhaps get some new points for this.
 
All core protocols except AIM & ICQ knows status messages and stores them in DB... so the best for them is idea 1), ICQ and AIM otherwise does not know the real status message, and for each time it requests the message from server/client.
 
Here is the summary:
1) use Unicode support in DB as define some resident variable, which will be used to comunicate this to other plugins.
2) define some PS_GETCAPS flags and use this to detect the same Unicode formatted hack in current ACKTYPE_AWAYMSG.
 
The idea 2) is awful in realisation, but provides the easiest solution for ICQ - just because with idea 1) ICQ has a problem: either keep outdated status msg in DB, or delete it after broadcasting an ack... either way it is a wrong way to go...
 
So what I think about this:
- define two new PS_GETCAPS
- one e.g. PF1_AWAYMSG_DB, which notes idea 1) and no PSS_GETAWAYMSG or ACKTYPE_AWAYMSG is necessary
- second e.g. PF1_AWAYMSG_UNICODE for idea 2) where it will not be stored in DB, but broadcasted using ACKTYPE_AWAYMSG with Unicode hack same as the one for message blob
- with Miranda IM 0.8+ we can safely remove all that "hack" code PSS_GETAWAYMSG for MSN and others, which only reads the status message from DB and broadcasts it...
 
So, what do you think about this ?
 
Have a nice day,
Joe <at> Whale
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop
hrathh | 4 May 2007 17:55
Picon

hyperlink class of m_utils.h does not redraw properly when enabled/disabled

Hello there,

In my plug-ins I am using the hyperlink control provided by Miranda.
I noticed a bug in it: When the control gets enabled/disabled it does not redraw itself properly.
The reason is that the control does not handle WM_ENABLE at all.

Here is a patch which fixes this problem.
Could this be merged with SVN please?
The attached patch is for the current revision 4466 of trunk modules\utils\hyperlink.c. 

While analysing the control's code I noticed some other issues, which I also fixed.
fixed problems:
* hyperlink control did not redraw properly when getting enabled/disabled
* Unicode problem with MEASURETEXT routine (possible crash)
* cursor (hand) was not updated when system cursor changed
* system colours were not refreshed on WM_SYSCOLORCHANGE
* added proper error checking for all function results

Regards,
hrathh
_______________________________________________________________
SMS schreiben mit WEB.DE FreeMail - einfach, schnell und
kostenguenstig. Jetzt gleich testen! http://f.web.de/?mc=021192

Attachment (hyperlink.c.diff): application/octet-stream, 10 KiB
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop
Ricardo Pescuma Domenecci | 8 May 2007 05:39
Picon

User avatar dialog in avs

Hi all,

I just commited in berliOS an initial version of a user avatar dialog
(in 'View/Change My Details...') built by avs. The idea is to replace
the dialogs that each protocol creates by one created by avs.

I'd like to explain here how are things working and check if this is
fine with all proto developers. (As the last version of the set my
avatar service didn't supported removing avatars, it required a small
change, so some crashes may happen and some protocol changes are
needed)

The user avatar (also know as own avatar or protocol avatar) dialog is
built this way:

1. All protocols that define the PS_SETMYAVATAR service are listed in the dialog
2. When the user sets an avatar for a protocol, the following happens:
2a. If exists, PS_GETMYAVATARMAXSIZE is called in the protocol to get
the max avatar size for the protocol. If it don't exists, 300 is used.
If the selected image is smaller than that, it will not be resized.
(Some protocol need an option to always resize?)
2b. If exists, PS_GETMYAVATARIMAGEPROPORTION is called in the protocol
to check if the avatar must be square. If it don't exists the image
proportions are not changed
2c. If exists, PS_ISAVATARFORMATSUPPORTED is called in the protocol to
check which image formats are suported. If it don't exists any image
format can be sent to the protocol
2d. The image is resized and sent to the protocol throught the
PS_SETMYAVATAR service. The image passed is a temporary one and will
be deleted after the return of the call
3. When the user deletes an avatar the service PS_SETMYAVATAR is
called, passing NULL as image file (this is a new behaviour of this
service)

The notification that the avatar has changed is get from one of the following:
- a MS_AV_REPORTMYAVATARCHANGED service call
- The setting AvatarFile or PictObject or AvatarHash of the protocol is changed

There are some things still missing:
- Support for XML files in ICQ (or any protocol that reports support
of xml/swf images)
- Use the original image selected by the user if no resize is needed
(actually the image is always saved to disk, what isn't really needed
and can cause problems with transparency)
- Option to use one avatar to all protocols

Well, that's all, folks.
Pescuma

PS: A more descriptive info of the above services:

/*
wParam=0
lParam=(const char *)Avatar file name or NULL to remove the avatar
return=0 for sucess
*/
#define PS_SETMYAVATAR "/SetMyAvatar"

/*
wParam=(char *)Buffer to file name
lParam=(int)Buffer size
return=0 for sucess
*/
#define PS_GETMYAVATAR "/GetMyAvatar"

/*
wParam=(int *)max width of avatar - will be set (-1 for no max)
lParam=(int *)max height of avatar - will be set (-1 for no max)
return=0 for sucess
*/
#define PS_GETMYAVATARMAXSIZE "/GetMyAvatarMaxSize"

/*
wParam=0
lParam=0
return=One of PIP_SQUARE, PIP_FREEPROPORTIONS
*/
#define PIP_FREEPROPORTIONS	0
#define PIP_SQUARE			1
#define PS_GETMYAVATARIMAGEPROPORTION "/GetMyAvatarImageProportion"

/*
wParam = 0
lParam = PA_FORMAT_*   // avatar format
return = 1 (supported) or 0 (not supported)
*/
#define PS_ISAVATARFORMATSUPPORTED "/IsAvatarFormatSupported"

PS 2: Could someone please add this funcion near the CallProtoService one?
// See if a protocol service exists
__inline static int ProtoServiceExists(const char *szModule,const char
*szService)
{
	char str[MAXMODULELABELLENGTH * 2];
	strcpy(str,szModule);
	strcat(str,szService);
	return ServiceExists(str);
}

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
borkra | 8 May 2007 06:40
Picon

Re: User avatar dialog in avs

Pescuma,

I have few questions and proposal. 

1. Why are we having service for every avatar parameter? Maximum, size,
proportion, formats supported, etc. 
It seems like endless number of services in future. Why not to create one
service like PS_GETAVATARCAPS and replace all these servives with it.
The service would return a structure with all this stuff and maybe more in
future.

2. Could you please move all these PS_*AVATAR* definitions into m_avatar.h
Currently every protocol defines it's own set of these defitions and it
would be nice to get rid of them and move to the common location.

-----Original Message-----
From: miranda-develop-bounces@...
[mailto:miranda-develop-bounces@...] On Behalf
Of Ricardo
Pescuma Domenecci
Sent: Monday, May 07, 2007 10:40 PM
To: miranda-develop@...
Subject: [Miranda-Develop] User avatar dialog in avs

Hi all,

I just commited in berliOS an initial version of a user avatar dialog (in
'View/Change My Details...') built by avs. The idea is to replace the
dialogs that each protocol creates by one created by avs.

I'd like to explain here how are things working and check if this is fine
with all proto developers. (As the last version of the set my avatar service
didn't supported removing avatars, it required a small change, so some
crashes may happen and some protocol changes are
needed)

The user avatar (also know as own avatar or protocol avatar) dialog is built
this way:

1. All protocols that define the PS_SETMYAVATAR service are listed in the
dialog 2. When the user sets an avatar for a protocol, the following
happens:
2a. If exists, PS_GETMYAVATARMAXSIZE is called in the protocol to get the
max avatar size for the protocol. If it don't exists, 300 is used.
If the selected image is smaller than that, it will not be resized.
(Some protocol need an option to always resize?) 2b. If exists,
PS_GETMYAVATARIMAGEPROPORTION is called in the protocol to check if the
avatar must be square. If it don't exists the image proportions are not
changed 2c. If exists, PS_ISAVATARFORMATSUPPORTED is called in the protocol
to check which image formats are suported. If it don't exists any image
format can be sent to the protocol 2d. The image is resized and sent to the
protocol throught the PS_SETMYAVATAR service. The image passed is a
temporary one and will be deleted after the return of the call 3. When the
user deletes an avatar the service PS_SETMYAVATAR is called, passing NULL as
image file (this is a new behaviour of this
service)

The notification that the avatar has changed is get from one of the
following:
- a MS_AV_REPORTMYAVATARCHANGED service call
- The setting AvatarFile or PictObject or AvatarHash of the protocol is
changed

There are some things still missing:
- Support for XML files in ICQ (or any protocol that reports support of
xml/swf images)
- Use the original image selected by the user if no resize is needed
(actually the image is always saved to disk, what isn't really needed and
can cause problems with transparency)
- Option to use one avatar to all protocols

Well, that's all, folks.
Pescuma

PS: A more descriptive info of the above services:

/*
wParam=0
lParam=(const char *)Avatar file name or NULL to remove the avatar return=0
for sucess */ #define PS_SETMYAVATAR "/SetMyAvatar"

/*
wParam=(char *)Buffer to file name
lParam=(int)Buffer size
return=0 for sucess
*/
#define PS_GETMYAVATAR "/GetMyAvatar"

/*
wParam=(int *)max width of avatar - will be set (-1 for no max) lParam=(int
*)max height of avatar - will be set (-1 for no max) return=0 for sucess */
#define PS_GETMYAVATARMAXSIZE "/GetMyAvatarMaxSize"

/*
wParam=0
lParam=0
return=One of PIP_SQUARE, PIP_FREEPROPORTIONS */
#define PIP_FREEPROPORTIONS	0
#define PIP_SQUARE			1
#define PS_GETMYAVATARIMAGEPROPORTION "/GetMyAvatarImageProportion"

/*
wParam = 0
lParam = PA_FORMAT_*   // avatar format
return = 1 (supported) or 0 (not supported) */ #define
PS_ISAVATARFORMATSUPPORTED "/IsAvatarFormatSupported"

PS 2: Could someone please add this funcion near the CallProtoService one?
// See if a protocol service exists
__inline static int ProtoServiceExists(const char *szModule,const char
*szService)
{
	char str[MAXMODULELABELLENGTH * 2];
	strcpy(str,szModule);
	strcat(str,szService);
	return ServiceExists(str);
}

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express Download DB2 Express C - the
FREE version of DB2 express and take control of your XML. No limits. Just
data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
George Hazan | 8 May 2007 10:06
X-Face
Picon

Re: User avatar dialog in avs

   Hello, Ricardo!
   Tue, 8 May 2007 00:39:49 -0300 you wrote:

RPD> I just commited in berliOS an initial version of a user avatar dialog
RPD> (in 'View/Change My Details...') built by avs. The idea is to replace
RPD> the dialogs that each protocol creates by one created by avs.

What about moving it to the main repository, if AVS becomes the essential 
dependency of all Miranda's plugins?

RPD> 2a. If exists, PS_GETMYAVATARMAXSIZE is called in the protocol to get
RPD> the max avatar size for the protocol. If it don't exists, 300 is used.
RPD> If the selected image is smaller than that, it will not be resized.

Maybe we'll finally have the PS_GETAVATARCAPS service, which will take the 
first integer argument as a switch? And the second arg as a RECT*, POINT* 
etc. It's a bit boring to have so many services for nothing.

--

-- 
WMBR, George Hazan (ghazan@...) 

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
Josef Kucera | 8 May 2007 12:19
Picon

Re: User avatar dialog in avs

Hello,
I have some comments:
1) ICQ protocol is ready - it already handles all the "new" stuff (used 
internaly)
2) The idea for one service PS_GETAVATARCAPS is nice and I like it
3) For better handling I think something like AF_ENABLED should be defined 
if it is really possible to set own avatar (the support can be disabled and 
I do not like the idea of destroying a service to remove protocol from AVS 
list).

So the definition can be something like:

#define AF_MAXSIZE 1
// lParam = (POINT*)maxSize
// return 0 for success
#define AF_PROPORTION 2
// lParam = 0
// return same as current PS_GETMYAVATARIMAGEPROPORTION
#define AF_FORMATSUPPORTED 3
// lParam = PA_FORMAT_*   // avatar format
// return = 1 (supported) or 0 (not supported)
#define AF_ENABLED 4
// lParam = 0
// return = 1 (avatars ready) or 0 (disabled)
/*
wParam=One of AF_*
lParam=See descr of each AF_*
#define PS_GETAVATARCAPS "/GetAvatarCaps"

Regards,
Joe  <at>  Whale

----- Original Message ----- 
From: "Ricardo Pescuma Domenecci" <pescuma+miranda@...>
To: <miranda-develop@...>
Sent: Tuesday, May 08, 2007 5:39 AM
Subject: [Miranda-Develop] User avatar dialog in avs

> Hi all,
>
> I just commited in berliOS an initial version of a user avatar dialog
> (in 'View/Change My Details...') built by avs. The idea is to replace
> the dialogs that each protocol creates by one created by avs.
>
> I'd like to explain here how are things working and check if this is
> fine with all proto developers. (As the last version of the set my
> avatar service didn't supported removing avatars, it required a small
> change, so some crashes may happen and some protocol changes are
> needed)
>
> The user avatar (also know as own avatar or protocol avatar) dialog is
> built this way:
>
> 1. All protocols that define the PS_SETMYAVATAR service are listed in the 
> dialog
> 2. When the user sets an avatar for a protocol, the following happens:
> 2a. If exists, PS_GETMYAVATARMAXSIZE is called in the protocol to get
> the max avatar size for the protocol. If it don't exists, 300 is used.
> If the selected image is smaller than that, it will not be resized.
> (Some protocol need an option to always resize?)
> 2b. If exists, PS_GETMYAVATARIMAGEPROPORTION is called in the protocol
> to check if the avatar must be square. If it don't exists the image
> proportions are not changed
> 2c. If exists, PS_ISAVATARFORMATSUPPORTED is called in the protocol to
> check which image formats are suported. If it don't exists any image
> format can be sent to the protocol
> 2d. The image is resized and sent to the protocol throught the
> PS_SETMYAVATAR service. The image passed is a temporary one and will
> be deleted after the return of the call
> 3. When the user deletes an avatar the service PS_SETMYAVATAR is
> called, passing NULL as image file (this is a new behaviour of this
> service)
>
>
> The notification that the avatar has changed is get from one of the 
> following:
> - a MS_AV_REPORTMYAVATARCHANGED service call
> - The setting AvatarFile or PictObject or AvatarHash of the protocol is 
> changed
>
>
> There are some things still missing:
> - Support for XML files in ICQ (or any protocol that reports support
> of xml/swf images)
> - Use the original image selected by the user if no resize is needed
> (actually the image is always saved to disk, what isn't really needed
> and can cause problems with transparency)
> - Option to use one avatar to all protocols
>
>
> Well, that's all, folks.
> Pescuma
>
>
>
>
> PS: A more descriptive info of the above services:
>
> /*
> wParam=0
> lParam=(const char *)Avatar file name or NULL to remove the avatar
> return=0 for sucess
> */
> #define PS_SETMYAVATAR "/SetMyAvatar"
>
> /*
> wParam=(char *)Buffer to file name
> lParam=(int)Buffer size
> return=0 for sucess
> */
> #define PS_GETMYAVATAR "/GetMyAvatar"
>
> /*
> wParam=(int *)max width of avatar - will be set (-1 for no max)
> lParam=(int *)max height of avatar - will be set (-1 for no max)
> return=0 for sucess
> */
> #define PS_GETMYAVATARMAXSIZE "/GetMyAvatarMaxSize"
>
> /*
> wParam=0
> lParam=0
> return=One of PIP_SQUARE, PIP_FREEPROPORTIONS
> */
> #define PIP_FREEPROPORTIONS 0
> #define PIP_SQUARE 1
> #define PS_GETMYAVATARIMAGEPROPORTION "/GetMyAvatarImageProportion"
>
> /*
> wParam = 0
> lParam = PA_FORMAT_*   // avatar format
> return = 1 (supported) or 0 (not supported)
> */
> #define PS_ISAVATARFORMATSUPPORTED "/IsAvatarFormatSupported"
>
>
>
> PS 2: Could someone please add this funcion near the CallProtoService one?
> // See if a protocol service exists
> __inline static int ProtoServiceExists(const char *szModule,const char
> *szService)
> {
> char str[MAXMODULELABELLENGTH * 2];
> strcpy(str,szModule);
> strcat(str,szService);
> return ServiceExists(str);
> }
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Miranda-Develop mailing list
> Miranda-Develop@...
> https://lists.sourceforge.net/lists/listinfo/miranda-develop 

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
Josef Kucera | 8 May 2007 12:26
Picon

Re: Unicode support for Status Mode Messages

Well,
I was not aware that something such is planned...
 
That idea was a product of discussion between me and George (he actually suggested idea 1) ). It was not meant as something crucial, but merely as a survey - which is others points of view.
 
Have a nice day,
Joe <at> Whale
----- Original Message -----
From: borkra
Sent: Tuesday, May 01, 2007 1:49 PM
Subject: Re: [Miranda-Develop] Unicode support for Status Mode Messages

Joe,
 
I was under an impression that the plan was to change all strings in Miranda from ASCII to UTF8, and this would resolve problem with status messages as well as many others.
Have it changed?

From: miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org] On Behalf Of Josef Kucera
Sent: Tuesday, May 01, 2007 6:01 AM
To: miranda-develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: [Miranda-Develop] Unicode support for Status Mode Messages

Hello all,
there is two major ideas how to implement unicode support for Status Mode Messages, I just wanted to sumarize that and perhaps get some new points for this.
 
All core protocols except AIM & ICQ knows status messages and stores them in DB... so the best for them is idea 1), ICQ and AIM otherwise does not know the real status message, and for each time it requests the message from server/client.
 
Here is the summary:
1) use Unicode support in DB as define some resident variable, which will be used to comunicate this to other plugins.
2) define some PS_GETCAPS flags and use this to detect the same Unicode formatted hack in current ACKTYPE_AWAYMSG.
 
The idea 2) is awful in realisation, but provides the easiest solution for ICQ - just because with idea 1) ICQ has a problem: either keep outdated status msg in DB, or delete it after broadcasting an ack... either way it is a wrong way to go...
 
So what I think about this:
- define two new PS_GETCAPS
- one e.g. PF1_AWAYMSG_DB, which notes idea 1) and no PSS_GETAWAYMSG or ACKTYPE_AWAYMSG is necessary
- second e.g. PF1_AWAYMSG_UNICODE for idea 2) where it will not be stored in DB, but broadcasted using ACKTYPE_AWAYMSG with Unicode hack same as the one for message blob
- with Miranda IM 0.8+ we can safely remove all that "hack" code PSS_GETAWAYMSG for MSN and others, which only reads the status message from DB and broadcasts it...
 
So, what do you think about this ?
 
Have a nice day,
Joe <at> Whale

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
Miranda-Develop mailing list
Miranda-Develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
https://lists.sourceforge.net/lists/listinfo/miranda-develop
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop
borkra | 8 May 2007 14:30
Picon

Re: Unicode support for Status Mode Messages

Joe,
 
in my opinion option #1 is prefarable (no impact to anything really).
 
BTW, storing status messages in the DB variable is not a "hack" for MSN.  It a normal mode operation (and the only possible).
In MSN, server sends Personal Message only once when it changes or on login and it's a job to of the client to keep it from that  point to the next change.
There is no capability in protocol to request Personal Message from anybody.
This code (to read DB variable and use it for broadcast) will most likely stay in MSN regardless of API changes. 
If I am not mistaken the same statement applicable to Yahoo.
 
Thank you 

From: miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org] On Behalf Of Josef Kucera
Sent: Tuesday, May 08, 2007 5:26 AM
To: miranda-develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [Miranda-Develop] Unicode support for Status Mode Messages

Well,
I was not aware that something such is planned...
 
That idea was a product of discussion between me and George (he actually suggested idea 1) ). It was not meant as something crucial, but merely as a survey - which is others points of view.
 
Have a nice day,
Joe <at> Whale
----- Original Message -----
From: borkra
Sent: Tuesday, May 01, 2007 1:49 PM
Subject: Re: [Miranda-Develop] Unicode support for Status Mode Messages

Joe,
 
I was under an impression that the plan was to change all strings in Miranda from ASCII to UTF8, and this would resolve problem with status messages as well as many others.
Have it changed?

From: miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:miranda-develop-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org] On Behalf Of Josef Kucera
Sent: Tuesday, May 01, 2007 6:01 AM
To: miranda-develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: [Miranda-Develop] Unicode support for Status Mode Messages

Hello all,
there is two major ideas how to implement unicode support for Status Mode Messages, I just wanted to sumarize that and perhaps get some new points for this.
 
All core protocols except AIM & ICQ knows status messages and stores them in DB... so the best for them is idea 1), ICQ and AIM otherwise does not know the real status message, and for each time it requests the message from server/client.
 
Here is the summary:
1) use Unicode support in DB as define some resident variable, which will be used to comunicate this to other plugins.
2) define some PS_GETCAPS flags and use this to detect the same Unicode formatted hack in current ACKTYPE_AWAYMSG.
 
The idea 2) is awful in realisation, but provides the easiest solution for ICQ - just because with idea 1) ICQ has a problem: either keep outdated status msg in DB, or delete it after broadcasting an ack... either way it is a wrong way to go...
 
So what I think about this:
- define two new PS_GETCAPS
- one e.g. PF1_AWAYMSG_DB, which notes idea 1) and no PSS_GETAWAYMSG or ACKTYPE_AWAYMSG is necessary
- second e.g. PF1_AWAYMSG_UNICODE for idea 2) where it will not be stored in DB, but broadcasted using ACKTYPE_AWAYMSG with Unicode hack same as the one for message blob
- with Miranda IM 0.8+ we can safely remove all that "hack" code PSS_GETAWAYMSG for MSN and others, which only reads the status message from DB and broadcasts it...
 
So, what do you think about this ?
 
Have a nice day,
Joe <at> Whale

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
Miranda-Develop mailing list
Miranda-Develop-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
https://lists.sourceforge.net/lists/listinfo/miranda-develop
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop
Josef Kucera | 8 May 2007 14:35
Picon

Re: Unicode support for Status Mode Messages

Yeaaaaah, I did not meant, that storing in DB is a hack - I had those PS_GETAWAYMSG wrappers in mind...
 
Btw. with ICQ 6 the old way of handling status messages for ICQ will die... so it will behave just like MSN...
 
Regards,
Joe <at> Whale
----- Original Message -----
From: borkra
Sent: Tuesday, May 08, 2007 2:30 PM
Subject: Re: [Miranda-Develop] Unicode support for Status Mode Messages

Joe,
 
in my opinion option #1 is prefarable (no impact to anything really).
 
BTW, storing status messages in the DB variable is not a "hack" for MSN.  It a normal mode operation (and the only possible).
In MSN, server sends Personal Message only once when it changes or on login and it's a job to of the client to keep it from that  point to the next change.
There is no capability in protocol to request Personal Message from anybody.
This code (to read DB variable and use it for broadcast) will most likely stay in MSN regardless of API changes. 
If I am not mistaken the same statement applicable to Yahoo.
 
Thank you 

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Miranda-Develop mailing list
Miranda-Develop@...
https://lists.sourceforge.net/lists/listinfo/miranda-develop

Gmane