Jump to content

ToolTip on TreeView items


Go to solution Solved by Melba23,

Recommended Posts

Hello everyone,

I did found a solution on this forum, for haveing tooltip on long line items in ListBox, but i want to know, does it posible to make the same for TreeView items? Kinda anoying to sscroll left - right if the item is longer then the TreeView itself. Other option for this why i am asking, i want to make a short description for the items. When the user hover the mouse cursor on it, the ToolTip is appear and can read the short description or the full length item text. Depends wich situation i wana use.

Up till now, i have this 2 situation, where i would like to use this ToolTip. (not in same application / TreeView)

Tricky

Sry for my bad English, and double sry, but I am learning AutoIT language by myself. :)

[u]Tricky[/u]

You can't teach a man anything, you can only help him, find it within himself. (Galileo Galilei)

Link to comment
Share on other sites

  • Moderators
  • Solution

TrickyDeath,

Treeviews automatically expand the "hot" item if it is too long for the normal visible area, so you do not need a tooltip for that. But you can add tooltips if you wish - as I show in >this post. :)

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

Hy there Melba,

Well, yes i know, if it is too long it will appear, but then i can not make a description for them (could not change what it is writen, and writen for all), and do not realy wanted to put that many control on the GUI, if it is not nessesery. Main option for me was to use that tooltip as a description.

I will take a look on your link now.

Edit.:

Thank You, that is what i was looking for. I saw normal Tooltip on long name items, and your coded ToolTips together. If i use $TSV_NOTOOLTIPS style, only the coded one will stay, so it is perfect. :)

Edited by TrickyDeath

Sry for my bad English, and double sry, but I am learning AutoIT language by myself. :)

[u]Tricky[/u]

You can't teach a man anything, you can only help him, find it within himself. (Galileo Galilei)

Link to comment
Share on other sites

  • Moderators

TrickyDeath,

Glad I could help. :)

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

  • Moderators

Tricky,

 

you can call me Tricky

Flattered, to be sure. ;)

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Link to comment
Share on other sites

  • 1 month later...

Finaly i manage to merge your code into my program source. The part how you made the tooltips on the TreeView was bit tricky. I was messing around with it, then i got pissed on it and insert an _ArrayDisplay on the table, and find out what was the problem.

Now it is work perfectly with my dynamic TreeView list. Made a little change, cause i call the tooltip from and INI, and the description in tooltip was away longer then my screen. xD

I did check all the posible way what i could think how to make it shorter. I know some or all program language can identify a special char in example INI file as a REM character. So i was going on this way to find out how i am able to make the 1 line into separated line in tooltip. To make it in source code it is easy, but as i read it from INI, i had to change your Tooltip like this:

ToolTip(StringReplace($sText, "|", @CRLF))

I do not know is there any better way or not, but it is work fine.

Sry for my bad English, and double sry, but I am learning AutoIT language by myself. :)

[u]Tricky[/u]

You can't teach a man anything, you can only help him, find it within himself. (Galileo Galilei)

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...