Re: Trap MouseHover in Win32Lib

new topic     » goto parent     » topic index » view thread      » older message » newer message
DerekParnell said...
euphoric said...

I would like to trap a MouseHover event...

When you set a tooltip hint, you can supply a routine_id instead of some text. Then when Windows goes to display the tooltip, it calls your routine and displays whatever text your routine returns.

This means that you can write a routine that gets the mouse location, calculates which cell that's hovering over and return the text appropriate for that cell. Your routine will receive two parameters; the ID that invoked the tooltip and the maximum length for the tip text.

I tried this route. Two problems:

  1. It doesn't call the tooltip routine again until the mouse is moved off the control, then back to it. I need to hit it for each stopping point, not just the first. If I hover over column 2, then hover over column 5, the tooltip generated over column 2 remains.
  2. The routine called by the tooltip feature lets me get the mouse coordinate, but I don't know how to translate that coordinate into a column of the EuGrid.


Any ideas?

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu