Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 5)

2013-09-27 Thread Jactry Zeng
Hi all, I see this patch is in 'pending' now, are there anything needs to be improved? Please give me some advice. Thank you. -- Regards, Jactry Zeng

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 5)

2013-09-14 Thread Jactry Zeng
Hi Nikolay, 2013/9/13 Nikolay Sivov > > Does it actually accept any other value besides CP_ACP or 1200? Documentation is unclear here, and makes impression that only two these values are valid. Did you mean EM_SETTEXTEX? I had some tests today. And I found native EM_SETTEXTEX can accept almost al

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 5)

2013-09-13 Thread Nikolay Sivov
On 9/13/2013 13:27, Jactry Zeng wrote: Re-based to latest git. Does it actually accept any other value besides CP_ACP or 1200? Documentation is unclear here, and makes impression that only two these values are valid.

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 2)

2013-09-05 Thread Nikolay Sivov
On 9/4/2013 21:16, Jactry Zeng wrote: Hi Nikolay, 2013/9/5 Nikolay Sivov > > > On 9/4/2013 07:17, Jactry Zeng wrote: >> >> -ME_EndToUnicode(unicode, wszText); >> +ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText); > > It's still ugly to use magic num

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 2)

2013-09-04 Thread Jactry Zeng
Hi Nikolay, 2013/9/5 Nikolay Sivov > > On 9/4/2013 07:17, Jactry Zeng wrote: >> >> -ME_EndToUnicode(unicode, wszText); >> +ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText); > > It's still ugly to use magic numbers like that, in a similar situation I had some time > ago I use ~0 t

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 2)

2013-09-04 Thread Nikolay Sivov
On 9/4/2013 07:17, Jactry Zeng wrote: -ME_EndToUnicode(unicode, wszText); +ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText); It's still ugly to use magic numbers like that, in a similar situation I had some time ago I use ~0 to mark WCHAR data encoding that does need special ha

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode.

2013-09-03 Thread Jactry Zeng
Hi Phil, 2013/9/4 Phil Krylov > > Hello, > > >-ME_EndToUnicode(unicode, wszText); > >+unicode ? ME_EndToUnicode(1200, wszText) : ME_EndToUnicode(CP_ACP, wszText); > > Personally I dislike this stuff in C code. Especially when you could > make it shorter: > > ME_EndToUnicode(unicod

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode.

2013-09-03 Thread Phil Krylov
Hello, >-ME_EndToUnicode(unicode, wszText); >+unicode ? ME_EndToUnicode(1200, wszText) : ME_EndToUnicode(CP_ACP, >wszText); Personally I dislike this stuff in C code. Especially when you could make it shorter: ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText) -- Ph.