Re: Intercepting and modifying calltips on the fly
Tim Rude <[email protected]> Fri, 21 Apr 2023 20:40:29 -0700 (PDT)
| Newsgroups | gmane.editors.scite.general |
|---|---|
| Message-ID | <[email protected]> |
Neil: I don't think that will be sufficient to override the current functionality cleanly. SciTE is also responsible for moving the highlight within the calltip by calling CallTipSetHlt as the user enters each parameter. What if an OnCallTipShow event function fires right after the automatic calltip routine reads the calltip info from the api file, and it passes as a parameter the calltip text that was read. This would be just before the rest of the calltip processing takes place that sets up the state variables for handling for the parameter highlighting. Then the code in the OnCallTipShow event function could modify that calltip text as desired, and pass the modified text back as the function's return value (rather than a True / False return). If the returned text is blank (as it presumably would be if there's no OnCallTipShow function coded), SciTE just shows the calltip as it was read from the api file as usual. Otherwise, SciTE would use the modified text instead of the original text and proceed with the rest of the calltip functionality. In this case, maybe a better name for the event function would be OnCallTipRead instead of OnCallTipShow. Tim Rude -- You received this message because you are subscribed to the Google Groups "scite-interest" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/scite-interest/d2be5470-38a0-4a77-9417-b2ec3439a0efn%40googlegroups.com.