![]() |
HOWTO: Set tooltip style for item tooltip |
Post Reply
|
| Author | |
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Topic: HOWTO: Set tooltip style for item tooltipPosted: 02 December 2008 at 5:23pm |
|
Hi;
I call GetToolTipContext()->SetStyle(xtpToolTipOffice2007) but the tooltip that pops up for hidden item text is still drawn like an old style tooltip. Does anyone know how to change this tooltip also to Office2007 style? |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 03 December 2008 at 4:41am |
|
Hi, Tooltips for Hidden text don't use ToolTipContext. :(
You can call SetTooltip for all items to show Office 2007 tips.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Posted: 03 December 2008 at 5:52am |
But this will also double the size required to show records in the control (each item string is contained twice). I have to show several thousand records grouped by some columns, so I can't use the control in virtual mode... No other solutions possible? How can I replace the internal tooltip by my own control? |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
Oleg
Senior Member
Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
Quote Reply
Posted: 03 December 2008 at 12:07pm |
|
Hi,
Anoter option - create special Item class for your items, override "virtual CString GetTooltip() const"; method and return Caption.
|
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
![]() |
|
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Posted: 15 December 2008 at 7:34am |
|
Hi Oleg;
will this be changed in coming releases, so that the item tooltip also uses the tooltip context? |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 July 2009 at 5:19am |
|
Hi Oleg;
will this be implemented (soon)? |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 July 2009 at 6:27am |
|
I've already done this with all my record items. It's simple. Like Oleg said: class CReportRecordItemText : public CXTPReportRecordItemText
{
public:
virtual CString GetTooltip() const { return GetCaption(); }
};
|
|
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 July 2009 at 6:33am |
|
Hi;
but this leads to another problem: callin a non const member within a const member function. And what happens to the tooltip if markup is used? ![]() It's also not usable if the text for the item is provided by CmyRecord::GetItemMetrics() (pItemMetrics->strText) because in this case the caption is not set! |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
mgampi
Senior Member
Joined: 14 July 2003 Status: Offline Points: 1210 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 July 2009 at 6:54am |
|
Another issue:
With this solution, the tooltip is no longer inplace!!!! ![]() |
|
|
Martin Product: Xtreme Toolkit v 22.1.0, new Projects v 24.0.0 Platform: Windows 10 v 22H2 (64bit) Language: VC++ 2022 |
|
![]() |
|
znakeeye
Senior Member
Joined: 26 July 2006 Status: Offline Points: 1672 |
Post Options
Thanks(0)
Quote Reply
Posted: 10 July 2009 at 9:32am |
|
No longer inplace? Don't follow here.
Markup --> use markup tooltips or strip markup code from caption. Not a big deal.
Virtual mode? I guess you need som special logic for that.
|
|
|
PokerMemento - http://www.pokermemento.com/
|
|
![]() |
|
Post Reply
|
|
|
Tweet
|
| Forum Jump | Forum Permissions ![]() You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |