QHTM_SetHTMLListbox
BOOL WINAPI QHTM_SetHTMLListbox( HWND hwnd );
Change a listbox so that it's items can use HTML instead of plain text.
This is useful if you wish to add formatting, images or colour to listboxes but wish none of the development work normally associated with owner drawn content.
All QHTM HTML formatting is supported. Forms and links are not yet supported
Parameters
- hwnd
- The window handle to the listbox you wish to change.
Return value
non-zero if it succeeds.Example
if( QHTM_SetHTMLListbox( hwnd ) )
{
// Success
}
Once the listbox has been set to use HTML you can add the items as you would normally. e.g. (from the demo)
HWND hwndListbox = GetDlgItem( hwnd, IDC_LIST );
QHTM_SetHTMLListbox( hwndListbox );
ListBox_AddString( hwndListbox,
_T("<body MARGINHEIGHT=0><table><tr><td width=1>")
_T("<img src='res:145'></td><td><b>DigiGuide TV Guide</b>")
_T("<br>Fabulous PC based TV guide</td></tr></table>") );
See also None