This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: windres: serious bug


"Danny Smith" <danny_r_smith_2001 at yahoo dot co dot nz> wrote:

> Using this id.rc (which parses with old windres as well as patched version)
> as testcase:
>
>
> 101 DIALOGEX 0, 0, 200, 200
>
> BEGIN
> CONTROL "stringid", 102, "Static", 0x5000120e, 5, 5, 10, 10
> END
>
> where "Static" is the class name.
>
> I get this from windres:
>
> dump of id.res from windres
>
> Contents of section .data:
>  0000 00000000 20000000 ffff0000 ffff0000  .... ...........
>  0010 00000000 00000000 00000000 00000000  ................
>  0020 5a000000 20000000 ffff0500 ffff6500  Z... .........e.
>  0030 00000000 30100904 00000000 00000000  ....0...........
>  0040 0100ffff 00000000 00000000 00008880  ................
>  0050 01000000 0000c800 c8000000 00000000  ................
>  0060 00000000 00000000 0e120050 05000500  ...........P....
>  0070 0a000a00 66000000 53007400 61007400  ....f...S.t.a.t.
>  0080 69006300 00007300 74007200 69006e00  i.c...s.t.r.i.n.
>  0090 67006900 64000000 00000000           g.i.d.......
>
>
> and this from rc.exe:
>
> dump of id.res from rc
>
> Contents of section .data:
>  0000 00000000 20000000 ffff0000 ffff0000  .... ...........
>  0010 00000000 00000000 00000000 00000000  ................
>  0020 50000000 20000000 ffff0500 ffff6500  P... .........e.
>  0030 00000000 30100904 00000000 00000000  ....0...........
>  0040 0100ffff 00000000 00000000 00008880  ................
>  0050 01000000 0000c800 c8000000 00000000  ................
>  0060 00000000 00000000 0e120050 05000500  ...........P....
>  0070 0a000a00 66000000 ffff8200 73007400  ....f.......s.t.
>  0080 72006900 6e006700 69006400 00000000  r.i.n.g.i.d.....
>
>
> Note the class name "Static" is missing in the rc.exe output
>
> I don't know what the class name is used for.  Maybe it just for the GUI
> resource editor.  It doesn't make any difference to how the finally
> executable works in my tests, but this windres-rc difference makes testcase
> construction difficult with the current framework.

Have a look at
http://msdn.microsoft.com/library/en-us/winui/winui/windowsuserinterface/windowing/dialogboxes/dialogboxreference/dialogboxstructure
s/dlgitemtemplate.asp

What rc.exe does is that it replaces class names of the standard controls
by ordinal values (presumably in order to save a bit of space).

0x0080 - Button
0x0081 - Edit
0x0082 - Static
0x0083 - List box
0x0084 - Scroll bar
0x0085 - Combo box

However current behaviour of windres is perfectly correct and acceptable IMHO.

--
Dmitry.




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]