New tooltip system?

This forum is for eXpress++ general support.
Post Reply
Message
Author
User avatar
Tom
Posts: 1321
Joined: Thu Jan 28, 2010 12:59 am
Location: Berlin, Germany

New tooltip system?

#1 Post by Tom »

Some of us know Diego Kerejeta. He retired some time ago, but he never stopped working on a really good tooltip system for Xbase++ applications. A few days ago, he released the attached code and sample "for free", and he explicitly linked this to permission to use and distribute the code. It looks great to me.

I would try by myself to adapt this for eXpress++, but maybe it would be a little easier if Roger takes a look. 8-)
Attachments
test.zip
(6.99 KiB) Downloaded 39 times
Best regards,
Tom

"Did I offend you?"
"No."
"Okay, give me a second chance."

User avatar
Tom
Posts: 1321
Joined: Thu Jan 28, 2010 12:59 am
Location: Berlin, Germany

Re: New tooltip system?

#2 Post by Tom »

This is how it looks:
Attachments
sample2.png
sample2.png (58.35 KiB) Viewed 1919 times
sample1.png
sample1.png (55.33 KiB) Viewed 1919 times
Best regards,
Tom

"Did I offend you?"
"No."
"Okay, give me a second chance."

User avatar
Tom
Posts: 1321
Joined: Thu Jan 28, 2010 12:59 am
Location: Berlin, Germany

Re: New tooltip system?

#3 Post by Tom »

Diego released a new version, and he added this comment:
I have just modified the XbpToolTip class, simplifying it a lot. For me, this is the recommended version to use.

There are at least two ways to work with tooltips:

- Direct storage inside the tooltip control (the new version).
- Delegated loading/display through LPSTR_TEXTCALLBACK + WM_NOTIFY + TTN_GETDISPINFOA (the previous version).

The first approach has the advantage of being much simpler, more straightforward, and self-contained (there is no need to modify anything in the XbpDialog it is attached to).

The second approach may be intended for dynamic text usage, where the text can change each time the tooltip is displayed. In Xbase++, it is slower, more complex, and requires changes in the parent XbpDialog (handling notifications via WM_NOTIFY).

Both approaches are equally functional and properly integrated into Xbase++ (or at least I believe so), although I personally prefer the new one. At least, it is the one I will use for maintaining our applications.
Attachments
test(1).zip
(6.92 KiB) Downloaded 43 times
Best regards,
Tom

"Did I offend you?"
"No."
"Okay, give me a second chance."

Post Reply