mIRC Homepage
Posted By: FroggieDaFrog ON TABCOMP improvements - 11/01/16 01:30 AM
I find that ON TABCOMP is lacking in many areas, so I suggest the following to fill gaps.

Firstly, on TABCOMP should trigger even if native mIRC is unable to come up with a match. Currently, unless mIRC finds a match, on tabcomp does not trigger thus not allowing scripts to include there own handling.

Secondly, on TABCOMP does not make the text to be completed or its position available to a script. Which results in scripters having to use a work around involving $editbox().selstart & $editbox().selend then working backwards until a space is encountered. This is tedious to do, and can be quite slow. Along with that, the successive tab count is not made available anywhere resulting in the scripter to have to track such manually

I suggest adding the following identifers for use within an ON TABCOMP event:
Code:
$TabText : The text to be completed

$TabTextPos : The starting position of $TabText within the line

$Tab(n) : returns the text mIRC would use for the nth tab press

$TabCount : Returns the tab-press count


Last, once a script has deduced the tabcomp text and its position its, again, tedious to insert the scripted tabcomp text into the editbox at the correct position overwriting the previous text. And thus I'd like to see the following command added for use within ON TABCOMP events:
Code:
/tabcomp <text> : Uses the specified text as the 'completed' text
Posted By: TRT Re: ON TABCOMP improvements - 12/01/16 10:37 AM
Originally Posted By: FroggieDaFrog

Firstly, on TABCOMP should trigger even if native mIRC is unable to come up with a match. Currently, unless mIRC finds a match, on tabcomp does not trigger thus not allowing scripts to include there own handling.


I remember using scripts that used tabcompletition with arbitrary editbox text.

Originally Posted By: versions.txt

Added on TABCOMP event, triggers when a user presses the TAB key in an editbox and mIRC is about to perform tab completion. Halting the event prevents mIRC's default tab completion.


Was this really changed?
Posted By: Wims Re: ON TABCOMP improvements - 13/01/16 01:31 AM
I'm not sure what you're trying to say but the second quote talks about "and mIRC is about to perform tab completion", I think nothing changed and the event only ever triggered for nick/channel/$identifier/etc completion
Posted By: TRT Re: ON TABCOMP improvements - 13/01/16 12:40 PM
It triggers just fine when I press Tab in an empty status window here...
Posted By: Wims Re: ON TABCOMP improvements - 13/01/16 03:29 PM
Yeah, that's a bug smile
© mIRC Discussion Forums