{
QPalette palette = QPalette();
QColor text_color = (guiApp->isInDarkMode())
? palette.color(QPalette::Active, QPalette::WindowText)
: Qt::black;
QColor highlight_color = palette.color(QPalette::Active, QPalette::HighlightedText);
{
QPalette palette = QPalette();
QColor text_color = (guiApp->isInDarkMode())
? palette.color(QPalette::Active, QPalette::WindowText)
: Qt::black;
QColor highlight_color = palette.color(QPalette::Active, QPalette::HighlightedText);
// create a layer with black text turned to QPalette::HighlightedText
QPixmap hl_overlay(pixmap.size());
hl_overlay.fill(highlight_color);
hl_overlay.setMask(pixmap.createMaskFromColor(text_color, Qt::MaskOutColor));
// create a layer with black text turned to QPalette::HighlightedText
QPixmap hl_overlay(pixmap.size());
hl_overlay.fill(highlight_color);
hl_overlay.setMask(pixmap.createMaskFromColor(text_color, Qt::MaskOutColor));
// get pixmap with bullets
QPixmap pixmap = getPixmap("images/math/", toqstr(ms.icon), "svgz,png");
QIcon icon(pixmap);
// get pixmap with bullets
QPixmap pixmap = getPixmap("images/math/", toqstr(ms.icon), "svgz,png");
QIcon icon(pixmap);
QListWidgetItem * lwi = new QListWidgetItem(icon, QString());
setDelimiterName(lwi, delim);
left_list_items_[ms.unicode] = lwi;
QListWidgetItem * lwi = new QListWidgetItem(icon, QString());
setDelimiterName(lwi, delim);
left_list_items_[ms.unicode] = lwi;