Final fix from '[ 1473731 ] wxColourBase and wxString <-> wxColour implementation'.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@39764 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
3c15a15128
commit
6bdcf0b143
@ -475,13 +475,16 @@ wxString MyHtmlListBox::OnGetItem(size_t n) const
|
||||
return s;
|
||||
#else
|
||||
int level = n % 6 + 1;
|
||||
wxString label = wxString::Format(_T("<h%d><font color=#%2x%2x%2x>")
|
||||
|
||||
wxColour clr(abs((int)n - 192) % 256,
|
||||
abs((int)n - 256) % 256,
|
||||
abs((int)n - 128) % 256);
|
||||
|
||||
wxString label = wxString::Format(_T("<h%d><font color=%s>")
|
||||
_T("Item</font> <b>%lu</b>")
|
||||
_T("</h%d>"),
|
||||
level,
|
||||
abs((int)n - 192) % 256,
|
||||
abs((int)n - 256) % 256,
|
||||
abs((int)n - 128) % 256,
|
||||
clr.GetAsString(wxC2S_HTML_SYNTAX).c_str(),
|
||||
(unsigned long)n, level);
|
||||
if ( n == 1 )
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user