On 1/31/07, Danny Backx <[EMAIL PROTECTED]> wrote: > On Tue, 2007-01-30 at 22:31 +0000, Nuno Lucas wrote: > > The GetCharWidth32 hasn't two variations on WinCE as it has on Windows > > (even if they are the same). > > Yes, this is true for many functions. I'm a bit confused by your > proposed patch, and what I see in our libcoredll.a though. > > In other places, e.g. src/w32api/include/winuser.h, these definitions > are triggered not by _WIN32_WCE but by #ifdef UNICODE . > > My gut says your approach looks better than the #ifdef UNICODE, but I'd > like to be certain. > > Also I'm not sure which direction the macro's should point. An example : > #ifdef UNICODE > [..] > #define MessageBox MessageBoxW > > dannypc: {85} arm-wince-cegcc-nm libcoredll.a | grep MessageBox > 00000000 T MessageBoxW > 00000000 I __imp_MessageBoxW > dannypc: {86} arm-wince-cegcc-nm libcoredll.a | grep GetCharWidth32 > 00000000 T GetCharWidth32 > 00000000 I __imp_GetCharWidth32 > > This confuses me. Should we define MessageBoxW in the lib with the W, > but GetCharWidth32 without the W ? What do other Windows architectures > implement ?
I believe this was actually an error by Microsoft on the Windows API, which they maintained for the sake of compatibility. But with Windows CE they didn't need to maintain that error and just had one GetCharWidth32() export. The thing is that GetCharWidth32() doesn't need a UNICODE and non-UNICODE version, because the parameters are UINT, so either ANSI or Unicode characters would work. The only difference is that maybe the ANSI version can be implemented by a simple array lookup, while the Unicode version needs some form of table scan or (most probably) a binary tree. I hope I made it more clearer. Regards, ~Nuno Lucas ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel