Tooltips stopped working
-
At some point during development, tool tips stopped working for the buttons on my tool bars. If the mouse is moved over a button, nothing happens. If the button is clicked then tooltip text does appear at the bottom of the window, as long as the button is held down. May I ask if anyone has had a similar experience, and whether they have figured out the cause? Any input appreciated. Thanks.
-
At some point during development, tool tips stopped working for the buttons on my tool bars. If the mouse is moved over a button, nothing happens. If the button is clicked then tooltip text does appear at the bottom of the window, as long as the button is held down. May I ask if anyone has had a similar experience, and whether they have figured out the cause? Any input appreciated. Thanks.
Possibly your string identifiers do not correlate with the numeric values of the command identifiers for your tooltips any more. I noticed this when I created the tooltip and string at same time, and later changed the actual value of the command ID, then the strings in the resource string table still had the OLD identifiers, I had to go in and change them manually to match the new command identifiers the tools were using.
-
Possibly your string identifiers do not correlate with the numeric values of the command identifiers for your tooltips any more. I noticed this when I created the tooltip and string at same time, and later changed the actual value of the command ID, then the strings in the resource string table still had the OLD identifiers, I had to go in and change them manually to match the new command identifiers the tools were using.
I appreciate your feedback, but I have not changed the values of the identifiers. Also, since the correct button description is displayed when the button is held down, it would appear that the association is correct. The problem is related to the failure of mouse movement to invoke an appropriate function. When the mouse enters and leaves the "window" of the button, there are surely events that need to be processed, but are not. Thanks
-
I appreciate your feedback, but I have not changed the values of the identifiers. Also, since the correct button description is displayed when the button is held down, it would appear that the association is correct. The problem is related to the failure of mouse movement to invoke an appropriate function. When the mouse enters and leaves the "window" of the button, there are surely events that need to be processed, but are not. Thanks
Did you inadvertently intercept messages anywhere in the message loop chain? There are some special functions for making this all work, if you are using MFC, such as CWnd::FilterToolTipMessage Called by the framework to display the tool tip message associated with a button on the toolbar. void FilterToolTipMessage(MSG* pMsg); Parameters pMsg - A pointer to the tool tip message. Remarks - It is normally called from PreTranslateMessage. Call it when the framework does not call it for you. See Also CWnd::OnToolHitTest Maybe this got bypassed with your recent development efforts? Just trying to help.
-
Did you inadvertently intercept messages anywhere in the message loop chain? There are some special functions for making this all work, if you are using MFC, such as CWnd::FilterToolTipMessage Called by the framework to display the tool tip message associated with a button on the toolbar. void FilterToolTipMessage(MSG* pMsg); Parameters pMsg - A pointer to the tool tip message. Remarks - It is normally called from PreTranslateMessage. Call it when the framework does not call it for you. See Also CWnd::OnToolHitTest Maybe this got bypassed with your recent development efforts? Just trying to help.
That is some good thinking. I should have posted that I "solved" this problem. First of all, it turned out that tooltips did appear every once in a while, maybe once out of 50 times that the cursor was moved over the button. In an effort to solve the problem, I started getting earlier versions of my source code out of Source Safe, and each time, the tool tips worked. Finally, I got to where there was a trivial difference between the "current" source and the source that did not work, a difference that could not matter, it seemed to me. Let me mention here that I did "rebuild all"s on the "current" version, which did not help. Finally, I checked out the current version of the code to a fresh directory. In other words, I checked out code identical to the source code which exhibited the problem. When I built the project, tool tips worked! I will say that I do not check in .dsw, .clw, or any of the "project" files, other than .dsp (well, .rc and resource.h are checked in, of course). I simply do not know. It seems so odd to me. I never did try deleting all the files from the "debug" or "release" folders, rather than just doing a rebuild all. Perhaps it was evil electrons.