The description of the bug is as follows:
In a gui comprising a listview control an item is truncated when its length is greater than the width of the listview column comprising the item.
By adding the option +LV0x400 to the listview, a tooltip comprising the complete item text is shown when hovering with the mouse over the truncated item.
Usually the tooltip for the item under the mouse is always correctly updated when I hover the mouse from one item to another item.
However, when I add an ActiveX control to the same gui, the tooltip is not always correctly updated when moving the mouse. Whith an added ActiveX control this only works correctly when hovering between the items of column 1. In the other columns the tooltip is only updated when I move the mouse from a first item to an item located above the first item. But when I move the mouse from a first item to a second item located below the first item the tooltip for the first item is maintained rather than showing the tooltip for the second item.
You should be able to reproduce this behavior with the following code:
Code: Select all
myGui := Gui()
myGui.OnEvent("Close", GuiClose)
mylistview := myGui.Add("ListView", "w450 h400 +LV0x400 +LV0x10000", ["A", "B", "C", "D"])
mylistview.ModifyCol(1, 100)
mylistview.ModifyCol(2, 100)
mylistview.ModifyCol(3, 100)
mylistview.ModifyCol(4, 100)
myActiveX := myGui.Add("ActiveX", "x+10 w850 h400", "Shell.Explorer").Value
mylistview.Add("", "Col A Row 111111111111111111111111111", "Col B Row 111111111111111111111111111", "Col C Row 111111111111111111111111111", "Col D Row 111111111111111111111111111")
mylistview.Add("", "Col A Row 222222222222222222222222222", "Col B Row 222222222222222222222222222", "Col C Row 222222222222222222222222222", "Col D Row 222222222222222222222222222")
mylistview.Add("", "Col A Row 333333333333333333333333333", "Col B Row 333333333333333333333333333", "Col C Row 333333333333333333333333333", "Col D Row 333333333333333333333333333")
mylistview.Add("", "Col A Row 444444444444444444444444444", "Col B Row 444444444444444444444444444", "Col C Row 444444444444444444444444444", "Col D Row 444444444444444444444444444")
myGui.Show("autosize Center")
Return
GuiClose(*)
{
ExitApp()
}
If I position my mouse over the first row of column D, a tooltip with "Col D Row 111111111111111111111111111" appears.
When I then move the mouse for example to the last row of column D the original tooltip "Col D Row 111111111111111111111111111" remains shown for some time before it disappears. However, it should immediately show a new tooltip with "Col D Row 444444444444444444444444444" when the mouse reaches the last row of column D.
If I make the same mouse movements in column A (from the first row to the last row) or if I make the movement from the last row of column D to the first row of column D the tooldip is correctly updated.
If I remove the "ActiveX" line from the code the tooltip is also correctly updated when the mouse is moved from the first row of column D to the last row of column D.
The script run flawlessly running Windows 10 22H2, AHK 2.0.11
The bug was confirmed on several computers running Windows 11 23H2 and AHK 2.0.11. It also was confirmed that the same problem exists using a v1 version of the script.