mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-18 19:06:10 +00:00
* Color function at offset 0. Closing #929
This commit is contained in:
parent
7ce1790fcf
commit
ed621e55a8
@ -156,6 +156,8 @@ void Configuration::loadDefaultTheme()
|
||||
setColor("gui.navbar.sym", QColor(229, 150, 69));
|
||||
setColor("gui.navbar.empty", QColor(100, 100, 100));
|
||||
setColor("gui.breakpoint_background", QColor(233, 143, 143));
|
||||
setColor("gui.item_invalid", QColor(155, 155, 155));
|
||||
setColor("gui.item_unsafe", QColor(255, 129, 123));
|
||||
}
|
||||
|
||||
void Configuration::loadBaseDark()
|
||||
@ -189,6 +191,8 @@ void Configuration::loadBaseDark()
|
||||
setColor("gui.dataoffset", QColor(255, 255, 255));
|
||||
// Custom
|
||||
setColor("gui.imports", QColor(50, 140, 255));
|
||||
setColor("gui.item_invalid", QColor(155, 155, 155));
|
||||
setColor("gui.item_unsafe", QColor(255, 129, 123));
|
||||
setColor("gui.main", QColor(0, 128, 0));
|
||||
|
||||
// GUI: navbar
|
||||
|
@ -31,8 +31,12 @@ QVariant ImportsModel::data(const QModelIndex &index, int role) const
|
||||
switch (role) {
|
||||
case Qt::ForegroundRole:
|
||||
if (index.column() < ImportsModel::ColumnCount) {
|
||||
// Red color for unsafe functions
|
||||
if (banned.match(import.name).hasMatch())
|
||||
return QColor(255, 129, 123);
|
||||
return Config()->getColor("gui.item_unsafe");
|
||||
// Grey color for symbols at offset 0 which can only be filled at runtime
|
||||
if (import.plt == 0)
|
||||
return Config()->getColor("gui.item_invalid");
|
||||
}
|
||||
break;
|
||||
case Qt::DisplayRole:
|
||||
|
Loading…
Reference in New Issue
Block a user