Regarding the custom dialog, I have just noticed that some time ago I added another custom dialog "option" type, in addition to (dbu, pixels, notheme, disable), called "map". This performs the same function as "dbu" but is specific to the dialog being displayed. "dbu" is generic but has to be kept as it is for backwards compatibility.
If you try using "map" as an option type in the dialog definition, does that resolve the issue?
@khaled - I have just tried it at scaling=100% (i.e. no scaling) and I get a different output with "map" than I do with "dbu":
The dialog is defined with "size -1 -1 168 227" and ($dbuw==$dbuh==2):
- with "dbu" the dialog is 342x483 and looks perfect
- with "map" the dialog is 258x397 and is squashed.
Given that map is undocumented, I would imagine that very few people will be using it. And so it might be buggy.
OTOH, perhaps the coordinates / sizes work differently with "map", in which case switching to "map" and making a one-time change to all the coordinates and sizes might fix it.
But it really would help to understand what "map" is supposed to do and how it is different from "dbu". Also, I will need to know what version of mIRC "map" was introduced in so that I can know whether I need to increase the minimum version for the script.
P.S. I can see how the actual dialog sizes are calculated for "dbu" - we need to account for the borders and the title bar of the dialog (so 342 = 168*2 + 6 and 483 = 227*2 + 29 - with notheme we get a 1px border and 2px margin all around which makes 6px for width and the title bar is 22px high + 1px gap below).
With "map" the borders and title bar sizes look the same, which means that the dbu-type scaling is different for width and height with = 1.5, height = 1.621145 which makes no sense. OTOH the absolute differences in size are almost the same 84 for width and 86 for height. Not sure if that helps you diagnose this issue...