Thread overview
How does RCC suport asian characters
Aug 02, 2004
danny
Aug 03, 2004
Walter
Aug 03, 2004
danny
Aug 04, 2004
Walter
Aug 04, 2004
Jan Knepper
Aug 06, 2004
danny
Aug 07, 2004
Walter
August 02, 2004
I'm a Chinese, and I use rcc to compiler my .rc file to .res, like this:
rcc test.rc -j1 -32.
then link it to my exe.
There are some chinese words in the test.rc, but I can't get correct result.
when I use Borland's brcc , it works correct. why?

And why the background of the dialog is white but not gray as normal?




August 03, 2004
Can you email me the rc file?

"danny" <danny@hftc.com.cn> wrote in message news:cekcd9$2kjg$1@digitaldaemon.com...
> I'm a Chinese, and I use rcc to compiler my .rc file to .res, like this:
> rcc test.rc -j1 -32.
> then link it to my exe.
> There are some chinese words in the test.rc, but I can't get correct
result.
> when I use Borland's brcc , it works correct. why?
>
> And why the background of the dialog is white but not gray as normal?
>
>
>


August 03, 2004
"Walter" <newshound@digitalmars.com> дÈëÓʼþ news:cenlqe$vd6$1@digitaldaemon.com...
> Can you email me the rc file?
>
Thanks! and can you tell me why the background of dialogbox is white but not gray?



August 04, 2004
"danny" <danny@hftc.com.cn> wrote in message news:cenmip$vl3$1@digitaldaemon.com...
>
> "Walter" <newshound@digitalmars.com> дÈëÓʼþ news:cenlqe$vd6$1@digitaldaemon.com...
> > Can you email me the rc file?
> >
> Thanks! and can you tell me why the background of dialogbox is white but not gray?

I have no idea.


August 04, 2004
Walter wrote:
> "danny" <danny@hftc.com.cn> wrote in message
> news:cenmip$vl3$1@digitaldaemon.com...
> 
>>"Walter" <newshound@digitalmars.com> дÈëÓʼþ
>>news:cenlqe$vd6$1@digitaldaemon.com...
>>
>>>Can you email me the rc file?
>>>
>>
>>Thanks! and can you tell me why the background of dialogbox
>>is white but not gray?

Make sure you target Windows 95, not Windows NT in case you're using the  IDDE. Also add the DS_3DLOOK to your dialog style.

Use a .def file or command line options as:
NAME		"AppName"

DESCRIPTION	'AppName'

EXETYPE		NT

SUBSYSTEM	WINDOWS,4.0

STUB		'WINSTUB.EXE'

CODE		 EXECUTE READ

DATA		 READ WRITE

STACKSIZE	1048576,4096

HEAPSIZE	1048576,4096



-- 
ManiaC++
Jan Knepper

But as for me and my household, we shall use Mozilla...
www.mozilla.org
August 06, 2004
> Make sure you target Windows 95, not Windows NT in case you're using the
>   IDDE. Also add the DS_3DLOOK to your dialog style.
>
I just lack the DS_3DLOOK style, and now it looks fine.
Thank you very much.
But rcc still can't deal with the chinese characters. Any idea?
I use windowsXP.


August 07, 2004
"danny" <danny@hftc.com.cn> wrote in message news:ceul8k$2fbn$1@digitaldaemon.com...
> > Make sure you target Windows 95, not Windows NT in case you're using the
> >   IDDE. Also add the DS_3DLOOK to your dialog style.
> >
> I just lack the DS_3DLOOK style, and now it looks fine.
> Thank you very much.
> But rcc still can't deal with the chinese characters. Any idea?
> I use windowsXP.

Please email me the source file. thanks.


October 03, 2004
In article <cekcd9$2kjg$1@digitaldaemon.com>, danny says...
>
>I'm a Chinese, and I use rcc to compiler my .rc file to .res, like this:
>rcc test.rc -j1 -32.
>then link it to my exe.
>There are some chinese words in the test.rc, but I can't get correct result.
>

Try to patch your RCC.EXE if you have RCC.EXE version 7.50B5 (292 864 bytes):

write 0x1 instead of 0x0 at file offset 0x43aa8.

But before, backup your RCC.EXE
;-----------------------------------------------------------
RCC incorrectly converts strings to Unicode.
Here is my explanation why RCC works so.

;
;it looks like mbstowcs function
;
_TEXT:00437808                 xor     edi, edi
_TEXT:0043780A                 test    esi, esi
_TEXT:0043780C                 jz      loc_0_4378DB
_TEXT:00437812                 cmp     [esp+arg_8], 1
_TEXT:00437817                 sbb     ecx, ecx
_TEXT:00437819                 inc     ecx
_TEXT:0043781A                 jz      loc_0_43790E

;dword_0_444EA8==0 ?
;but it is always stays zero
;that is why all troubles with russian, hebrew and maybe chinese and others

_TEXT:00437820                 cmp     ds:dword_0_444EA8, edi

;if not zero -- make Unicode-string with MultiByteToWideChar as it should be.
;seems like program never runs this way
_TEXT:00437826                 jnz     short loc_0_437857


_TEXT:00437828                 test    ecx, ecx _TEXT:0043782A                 jz      loc_0_43790E _TEXT:00437830                 mov     ebx, ebp _TEXT:00437832                 mov     eax, [esp+arg_8] _TEXT:00437836                 add     eax, ebp _TEXT:00437838

;Make Unicode-string by expanding byte to word
;it is good only for english characters

_TEXT:00437838 loc_0_437838:
_TEXT:00437838                 mov     dl, [ebx]
_TEXT:0043783A                 mov     ecx, edx
_TEXT:0043783C                 movzx   ecx, cl
_TEXT:0043783F                 mov     [esi], cx
_TEXT:00437842                 test    dl, dl
_TEXT:00437844                 jz      short loc_0_43784E
_TEXT:00437846                 inc     ebx
_TEXT:00437847                 add     esi, 2
_TEXT:0043784A                 cmp     ebx, eax
_TEXT:0043784C                 jb      short loc_0_437838
_TEXT:0043784E
_TEXT:0043784E loc_0_43784E:
_TEXT:0043784E                 mov     edi, ebx
_TEXT:00437850                 sub     edi, ebp
_TEXT:00437852                 jmp     loc_0_43790E