diff options
| author | Alexander Taylor <alex@vector35.com> | 2025-04-02 20:03:51 -0400 |
|---|---|---|
| committer | Alexander Taylor <alex@vector35.com> | 2025-04-02 20:03:51 -0400 |
| commit | 1b32a95b3a88567b349e1d3a57dea2fea9f42961 (patch) | |
| tree | cce799bc75a63fe5dc6a4606e9a02b2ecb252dc7 /view/sharedcache/ui/dsctriage.h | |
| parent | 58568cd94ea54723b95eaae83ccc387415ff8547 (diff) | |
Styling for data in shared cache view.
Diffstat (limited to 'view/sharedcache/ui/dsctriage.h')
| -rw-r--r-- | view/sharedcache/ui/dsctriage.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/view/sharedcache/ui/dsctriage.h b/view/sharedcache/ui/dsctriage.h index 243f7bc8..edab8358 100644 --- a/view/sharedcache/ui/dsctriage.h +++ b/view/sharedcache/ui/dsctriage.h @@ -14,9 +14,28 @@ #include "filter.h" #include "symboltable.h" +#include "ui/fontsettings.h" + #ifndef BINARYNINJA_DSCTRIAGE_H #define BINARYNINJA_DSCTRIAGE_H +class AddressColorDelegate : public QStyledItemDelegate +{ + +public: + AddressColorDelegate(QObject* parent = nullptr) : QStyledItemDelegate(parent) {} + + void paint(QPainter* painter, const QStyleOptionViewItem& option, const QModelIndex& index) const override + { + QStyleOptionViewItem opt = option; + initStyleOption(&opt, index); + + opt.palette.setColor(QPalette::Text, getThemeColor(BNThemeColor::AddressColor)); + + QStyledItemDelegate::paint(painter, opt, index); + } +}; + class FilterableTableView : public QTableView, public FilterTarget { Q_OBJECT @@ -26,6 +45,7 @@ public: explicit FilterableTableView(QWidget* parent = nullptr, bool filterByHiding = true) : QTableView(parent), m_filterByHiding(filterByHiding) { viewport()->installEventFilter(this); + setFont(getMonospaceFont(parent)); } ~FilterableTableView() override = default; |
