First, load your wdf file and set it to read 25 bytes; now I know this isnt the 'perfect' setting, but it is by far the easiest to navigate (unless you have a ginormous screen, then go ahead and set it to 101, 82 or 41, it depends which part of which wdf file you are editing). I will be using the k_sysmap.wdf file for this instructional, as it is small and contains both graphics and text. This wdf file controls all the text and graphics for the solar system view at the bottom of the main screen and system screen.
And now we begin.
The first 8 bytes should read 02 00 00 00 01 00 00 00 - this is the same for every wdf file i opened up so far. Unknown what function these serve, so we will leave them be.
(This next paragraph is speculatory)
The next 4 bytes I believe to be used for 'extra space' in wdf file, such as if the file is scrollable, like in *solcur.wdf, *summary.wdf, and *techosh.wdf (there are more Im sure, but dont know which ones atm). I am confident these must be changed if you are allowing a scroll bar to be usable in your screen (such as energy screen project). The 8 following bytes might have a similar function, however this has eluded me.
Ok, jump ahead to offset 0x14, here you will see the width that the wdf file covers (it may also be the width of the specified tga file, this has not yet been determined by me as it was not necessary for my experiment)
Now, 0x18 is the height the wdf file covers (or it is the height of the specified tga, again, not necessary for the experiment)
At 0x29 seems to me to be either the total number of instances of groups of items the file contains, or the number of times 02, 07, 08, 0D and 0E are found within the file. This might be important to change if adding another button set, such as a slider and buttons, to the file (energy screem project, could also have a trek.exe reference).
Not for the weak of heart...
GALM <--- GALM/Galaxies Mod