lbrtdy Posted October 3, 2010 Share Posted October 3, 2010 (edited) I have a question that I can not find online or in the help file. Say I have a Guictrlcreatelist that is a certain height and width, the items in the list are longer than the width of the list itself so only part of it shows up. If I highlight the item, how do I make it so that it the highlighted thing expands showing the entire contents, perhaps in a tool tip? I found a post by Siao and he posted something similar about using MouseOver: GUISetOnEvent($GUI_EVENT_MOUSEMOVE, "On_MOUSEMOVE") Func On_MOUSEMOVE() Local $aCI = GUIGetCursorInfo(), $aCtrlPos, $x, $sText = "" If @error Or $aCI[4] <> $List1 Then Return GUICtrlSetData($Input2, $sText) $aCtrlPos = ControlGetPos(@GUI_WinHandle, "", $aCI[4]) $x = _GUICtrlListBox_ItemFromPoint($aCI[4], $aCI[0]-$aCtrlPos[0], $aCI[1]-$aCtrlPos[1]) If $x > -1 Then $sText = _GUICtrlListBox_GetText($aCI[4], $x) GUICtrlSetData($Input2, $sText) EndFunc I can change it so that it shows a tooltip instead of changing $Input2's data, but I can't use any of the other buttons on my form1. But if I turn off Opt("GUIOnEventMode", 1) all my GUI buttons work again. So I guess there's really two questions here: 1)How do I make something that's in a list expand in perhaps tooltip form when I select it/mouse over it. Or if there is no such option: 2)How come when I turn on Opt("GUIOnEventMode", 1) my gui Buttons no longer work? I mean the post by Siao works perfectly for my purposes, but it just disables every button I created so.. that defeats the purpose. Thanks for your help! Edited October 3, 2010 by lbrtdy Link to comment Share on other sites More sharing options...
taietel Posted October 3, 2010 Share Posted October 3, 2010 (edited) Ibrtdy, I have faced the same problem, but I've solved with a gui: when an item in the list is double-clicked, it opens a gui with info from the other columns. Maybe this is useful to you. And also Melba's GuiExtender.M.I. Edited October 3, 2010 by taietel Things you should know first...In the beginning there was only ONE! And zero... Progs: Create PDF(TXT2PDF,IMG2PDF) 3D Bar Graph DeskGadget Menu INI Photo Mosaic 3D Text Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now