FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Antonio,need help!How to ShowToolTip without move the mouse
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted:

James,

I think it is related to the standard behavior that Windows provides to the tooltip class. They relate the tooltip to the mouse movements. Maybe there is a message to be sent to the tooltip that forces its inmediate display.

But after reviewing Samir's screenshot, I think that a different implementation may be taken. I would display an overlapping bitmaps with all the "simulated" tooltips on it. Similar to samples\newhelp,prg implementation.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Antonio,need help!How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 01:05 PM

I have a tooltip in a get and in a MsgBar, and I need to show both when I show my dialog, my app is for markets, and the use of mouse is rare in my app

I already tryed the ShowToolTip() method but it didn't work

I searched in the forum but didn't found a solution, some topics like these simple go on unanswered....

Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 01:56 PM

If I remember correctly, you need a tooltip class. There was one posted here some time ago.

The normal FW tooltip is not a class but rather some functions in TWindow (I think). This is why you need a Tooltip class.

Try searching again for "tooltip class."

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Re: How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 05:54 PM

I don't have the TTip class and don't like to use third code, Fivewin already have the code but it didn't work or I couldn't discover how to use because of the lack of comments...

But thanks for answer

Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 08:23 PM

>Fivewin already have the code but it didn't work or I couldn't discover how to use because of the lack of comments...

I am trying to tell you that you can't do what you want using only FW native code. The functions are STATIC functions inside one of the FW PRGs, and you cannot call a STATIC function outside the PRG.

I know this because I spent many hours on this issue years ago.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Re: How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 09:03 PM

So don't you think that Antonio should do something?
I really don't want to move the mouse via code and return to the original position just to show the tooltip...
I didn't find the TTip class

Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: How to ShowToolTip without move the mouse
Posted: Fri Jun 04, 2010 09:31 PM
>So don't you think that Antonio should do something?

Antonio says that the tooltips are STATIC for speed reasons.

>I didn't find the TTip class

According to this thread:

http://forums.fivetechsupport.com/viewtopic.php?f=3&t=12412&hilit=+in+place+tooltips+

FW has a new TTooltip class as of version 8.09. I have not tried using it.

James
FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Re: How to ShowToolTip without move the mouse
Posted: Mon Jun 07, 2010 11:47 AM

I can't find this class in my 9.06 version

Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Mon Jun 07, 2010 03:02 PM

I don't see that class either. Antonio?

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 12:13 PM
James Bott wrote:I don't see that class either. Antonio?

James


Antonio! Where are you?
Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 02:31 PM

I am out of the office until tomorrow, so I will check it as soon as I am back there where we have all our tools :-)

Please send me a reminder, if I don't answer by tomorrow, thanks

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 03:30 PM
Samir,

This code shows how to create a standard WIndows tooltip, though it behaves standard, and I don't think thats the behavior that you want:
Code (fw): Select all Collapse
#include "FiveWin.ch"

function Main()

   local oWnd, hWndTooltip

   DEFINE WINDOW oWnd
   
   ACTIVATE WINDOW oWnd ;
      ON CLICK hWndTooltip := CreateTooltip( oWnd:hWnd, "Hello world" )

return nil

So I don't think we may be able to use a standard tooltip to create it and leave it fixed at a certain place. Please notice that as soon as the mouse leaves the window owner of the tooltip, it vanishes away.

Maybe we should create a small window that simulates a real tooltip
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 03:40 PM
This info seems to provide the missing part:
http://msdn.microsoft.com/en-us/library/bb760252(VS.85).aspx#tooltip_sample_inplace

anyhow it seems as we can only change its location in response to a notification code (TTN_SHOW) and that means that the mouse is over the window. Not sure if this may be what you want.
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 389
Joined: Mon Oct 13, 2008 11:26 AM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 04:46 PM

I NEED to show the tooltip through a method or procedure...

Email: SamirSSabreu@gmail.com
xHarbour 1.2.3 + Fwhh 20.2
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Antonio,need help!How to ShowToolTip without move the mouse
Posted: Tue Jun 08, 2010 04:54 PM

Samir,

The question is: where the mouse will be ? If it goes out of the window then the tooltip will not be visible.

Is that fine for you ?

regards, saludos

Antonio Linares
www.fivetechsoft.com