mIRC Home    About    Download    Register    News    Help

Print Thread
#271257 28/01/23 10:47 PM
Joined: Jul 2006
Posts: 4,146
W
Wims Offline OP
Hoopy frood
OP Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,146
Two bugs with the icon dialog control.

1) the parser for the icon control dialog definition is different, based on the extention of the icon filename

I had an icon definition where the path to the icon was icon id,x y w h, " $scriptdirfile.ico ", 0, options with quotes, when i copied this line and pasted it to create another icon control, but this time with a .png extention, i got an error about that line. Specifically, the trailing space seems to be the problem. It will work fine with .ico, .exe and .dll at least, but fail at least on .png.

I know the quotes are not necessary here, but if they are fine with some extentions, it should be fine with all of them.

2) If the icon dialog control is disabled in the dialog definition, the icon will incorrectly be hidden when you launch the dialog


#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Joined: Dec 2002
Posts: 5,412
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,412
Thanks for your bug report. The custom dialog code does not handle spaces at all in this case. The only reason that format is working for you is that some of the Windows image APIs parse spaces. I have extended the icon code to remove extra spaces before calling the APIs. As far as I can tell, this shouldn't break backward compatibility but will need testing.

As for the disabled/hidden icon on startup, this also applies to hotlinks. These have always worked this way and there are no plans to change this behaviour.


Link Copied to Clipboard