gus
March 29th, 1999, 03:33 AM
In my application, I add a dialog bar with some fields with tooltip also. The tooltip are generated using the default
CToolTipCtrl inside the dialog bar, and I change the text intercepting the message TTN_NEEDTEXT, with something like
this:
BOOL CMyDlgBar::OnToolTipNeedText( UINT id, NMHDR *pNMHDR, LRESULT *pResult )
{
BOOL bHandleNotify = FALSE;
TOOLTIPTEXT *pTTT = (TOOLTIPTEXT*)pNMHDR;
UINT pos;
nID = ::GetDlgCtrlID( (HWND)pNMHDR->idFrom );
switch( nID )
{
case IDC_FLD1:
pTTT->lpszText = "my tooltip;
bHandleNotify = TRUE;
break;
}
return bHandleNotify;
}
The tooltip default position is centered and under the field: does anybody knows how I can move it to another position
(ie to the left of the field) ?
Thanks everybody
CToolTipCtrl inside the dialog bar, and I change the text intercepting the message TTN_NEEDTEXT, with something like
this:
BOOL CMyDlgBar::OnToolTipNeedText( UINT id, NMHDR *pNMHDR, LRESULT *pResult )
{
BOOL bHandleNotify = FALSE;
TOOLTIPTEXT *pTTT = (TOOLTIPTEXT*)pNMHDR;
UINT pos;
nID = ::GetDlgCtrlID( (HWND)pNMHDR->idFrom );
switch( nID )
{
case IDC_FLD1:
pTTT->lpszText = "my tooltip;
bHandleNotify = TRUE;
break;
}
return bHandleNotify;
}
The tooltip default position is centered and under the field: does anybody knows how I can move it to another position
(ie to the left of the field) ?
Thanks everybody