Chris E. Miller ToolTip (D1)

Heinz thor587 at yahoo.com
Thu Nov 14 08:17:51 PST 2013


You have to manually set the tooltip's max width to a fixed value 
using the tooltip handle and Win32 API, by doing this you're 
telling the tooltip object it is a multiline tooltip and from now 
on it will accept \r\n as end of line:

     ttip = new ToolTip;
     SendMessageA(ttip.handle, TTM_SETMAXTIPWIDTH, 0, 250);
     ttip.setToolTip(find, "a=n (not approved)\r\no=n (not 
outlooked)\r\nt>0 (total > 0));

That's it, it works (i tested it).

By the way, the DFL version on Chris' site is for D1 but there's 
this version for D2 (i use both): 
https://github.com/Rayerd/dfl/tree/master/win32/dfl


More information about the Digitalmars-d-learn mailing list