mIRC Homepage
Posted By: drum Method to detect scrolling position of window - 25/05/10 07:03 AM
I find myself sometimes accidentally using the mouse wheel to scroll up slightly in a channel window which causes me to miss new messages until I realize the channel wasn't scrolled down to the bottom. I know mIRC can make a sound to alert when a line that isn't visible is added to the window, but I personally prefer to not have any sounds active in mIRC. (Also, with a sound, it might not be obvious which window is causing it.)

Would it be possible to add some method of detecting the scrolling position of a window? For example, an identifier that can indicate the first and/or last visible line of a window. Or perhaps more simply an identifier that gives a $true/$false result if the window is scrolled to the bottom or not.

Another possibility is an event that triggers when a line that isn't visible is added to a window.

I'm not at all sure what the best implementation would be so I'm open to suggestions. I'd also be open to a non-scripting method as well. Any ideas?
$window() .scrollstart and .scrollend would be a similar idea but with a little more functionality. You could test if $window(#chan).scrollend == $line(#chan,0), but you could also do some other neat scroll related things with it (eg. a script to copy only the active lines in a window to the clipboard). Perhaps an associated command to set the scrollbar would be useful too (bind extra keys to scrolling, would also allow for custom window search scripts!).
© mIRC Discussion Forums