0

My question concerns visibility of hints in an application using DevExpress (C#) controls. The application has a panel on which there are several controls, and only one appears at a given moment. A user can choose which control should appear by switching among them. The controls have their bar with several buttons (different buttons for each type of control).

The problem is that the hints on the buttons sometimes do not appear when the mouse cursor is over them. They appear after opening the application, but when the user switches to a control of the same type, the hints are not visible. When the user switches to a control of another type, the hints can appear, but not always (I could not find the rule). But always, when the user goes to a window of another application and returns, the hints appear. The property ShowScreenTipsInToolbars for the bar manager has the value true during execution of the program.

Do you know the cause of this strange behavior? And what to do to make the hints always visible when a mouse cursor is over the buttons? I am not the author of the application (I was asked if it is possible to solve the problem) and I cannot give too many technical details.

4

1 回答 1

0

如果控件没有焦点,则该控件的所有子控件都不知道鼠标悬停在它们上方。因此,您不会获得工具提示。直到焦点传递到控件(通常在控件边界内单击左键)才会出现这种情况。

在没有看到任何代码的情况下,我最好的猜测是负责切换控件可见性的任何代码都不能保证可见控件具有焦点。Control.Focus()的文档在这里可能会有所帮助(请注意,该Control.Focus()方法设置焦点的能力存在例外情况。)

于 2013-09-29T09:04:30.973 回答