/* same for foreground */
if (local_style && local_style->m_foreground_color_set)
- painter.setBackgroundColor(local_style->m_foreground_color);
+ painter.setForegroundColor(local_style->m_foreground_color);
/* if we have no transparent background */
if (!local_style || !local_style->m_transparent_background)
painter.clear();
} else
{
- if (local_style && local_style->m_background)
+ if (local_style->m_background)
painter.blit(local_style->m_background, offset, eRect(), gPainter::BT_ALPHATEST);
+ else if (selected && !local_style->m_selection)
+ painter.clear();
}
if (m_list && cursorValid())
/* same for foreground */
if (local_style && local_style->m_foreground_color_set)
- painter.setBackgroundColor(local_style->m_foreground_color);
+ painter.setForegroundColor(local_style->m_foreground_color);
if (!local_style || !local_style->m_transparent_background)
/* if we have no transparent background */
painter.clear();
} else
{
- if (local_style && local_style->m_background)
+ if (local_style->m_background)
painter.blit(local_style->m_background, offset, eRect(), gPainter::BT_ALPHATEST);
+ else if (selected && !local_style->m_selection)
+ painter.clear();
}
if (m_list && cursorValid())
{
int color = PyInt_AsLong(pbackColor);
painter.setBackgroundColor(gRGB(color));
- }
- else if (local_style)
- {
- // transparent background?
- if (local_style->m_transparent_background)
- clear=false;
- // if we have a local background color set, use that.
- else if (local_style->m_background_color_set)
- painter.setBackgroundColor(local_style->m_background_color);
- }
+ } // transparent background?
+ else if (local_style && local_style->m_transparent_background)
+ clear=false;
+ // if we have a local background color set, use that.
+ else if (local_style && local_style->m_background_color_set)
+ painter.setBackgroundColor(local_style->m_background_color);
else
style.setStyle(painter, eWindowStyle::styleListboxNormal);
if (clear)
painter.setForegroundColor(gRGB(color));
}/* if we have a local foreground color set, use that. */
else if (local_style && local_style->m_foreground_color_set)
- painter.setBackgroundColor(local_style->m_foreground_color);
+ painter.setForegroundColor(local_style->m_foreground_color);
}
void eListboxPythonMultiContent::paint(gPainter &painter, eWindowStyle &style, const ePoint &offset, int selected)