aboutsummaryrefslogtreecommitdiff
path: root/mapman
diff options
context:
space:
mode:
Diffstat (limited to 'mapman')
-rw-r--r--mapman/src/painter.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/mapman/src/painter.cpp b/mapman/src/painter.cpp
index 5b3ad3b..3dafee6 100644
--- a/mapman/src/painter.cpp
+++ b/mapman/src/painter.cpp
@@ -105,6 +105,11 @@ void map_painter::set_map_id(int pos, bool populated, int id, bool user_input)
QPixmapCache::insert(QString("map_%1").arg(id), pm);
}
auto p = s->addPixmap(pm);
+ auto m = l->get_map(id);
+ p->setToolTip(QString("%1\nId #%2%3")
+ .arg(m.custom_name.empty() ? QString("Map") : QString::fromStdString(m.custom_name))
+ .arg(m.id)
+ .arg(m.locked ? "\nLocked" : ""));
int x = pos / hc;
int y = pos % hc;
p->setPos(y * 128, x * 128);