1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 06:47:35 +00:00

Mail: Draw unread messages as bold

This commit is contained in:
Karol Kosek 2023-07-11 19:18:26 +02:00 committed by Sam Atkins
parent 411ffb7954
commit 619b53eaca
3 changed files with 12 additions and 1 deletions

View file

@ -6,6 +6,7 @@
*/
#include "InboxModel.h"
#include <LibGfx/Font/FontDatabase.h>
InboxModel::InboxModel(Vector<InboxEntry> entries)
: m_entries(move(entries))
@ -46,5 +47,9 @@ GUI::Variant InboxModel::data(GUI::ModelIndex const& index, GUI::ModelRole role)
if (index.column() == Column::Date)
return Gfx::TextAlignment::CenterRight;
}
if (role == GUI::ModelRole::Font) {
if (!value.seen)
return Gfx::FontDatabase::default_font().bold_variant();
}
return {};
}