"Colour value invalid" when extended colours are selected in mIRC
danj2k opened this issue · comments
Steps to reproduce:
- Open mIRC with dlFilter loaded and running
- Choose the "View" menu, then choose "Colors"
- Change any item (ideally something that occurs frequently, so the error will show up quickly) to a colour that is not part of the block of 16 at the top of the colour picker, then click OK to close the "Colors" dialog
- Observe errors such as
[dlFilter] Error: $c: Colour value invalid: 88
(where the number will change depending which colour you picked)
Please could dlFilter be updated to support the full range of colours available in mIRC? This looks to be related to the following lines of code (6239-6240):
elseif ($1 !isnum 0-15) DLF.Error $ $+ c: Colour value invalid: $1
elseif (($0 >= 3) && ($2 isnum 0-15)) {
@danj2k Thank you for reporting this issue. I agree that the code is incorrect - and I will take a look at it ASAP. I can understand the issue, but I was unable to recreate the error by changing e/g the Topic colour - so as you say it presumably only triggers if the item changed is something like normal text.
@danj2k I have made these changes, but I have found that there is another issue that needs to be fixed before we can bump the version and you will get a download. Please feel free to change the two lines in your version from 0-15
to 0-99
in order to fix this temporarily.
I can understand the issue, but I was unable to recreate the error by changing e/g the Topic colour
I apologise for my somewhat imprecise description, I discovered this issue entirely by accident when I was setting up a new "white on black" colour scheme so that mIRC wouldn't blind me all the time (the only white-on-black scheme it has built in is a monochrome one, which didn't suit me), so as I changed a lot of things I'm not sure exactly which one it was that caused the issue.
It's not a problem. The cause was obvious enough and easy enough to fix.