From ff959720292b2b3e2ae825fd7b8adaae597a67c9 Mon Sep 17 00:00:00 2001 From: Satya Prakash Khuntia <87168509+atomikkus@users.noreply.github.com> Date: Fri, 12 Sep 2025 14:48:55 +0530 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20Enhance=20Visualization=20with=20Pa?= =?UTF-8?q?tient=20ID=20and=20Drawing=20Tools?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Added a patient ID display in the visualization templates for better context. - Introduced new drawing tools including measure distance and freehand annotation features. - Updated styles for patient ID and buttons to improve UI/UX. This update enhances the interactivity and usability of the visualization interface. --- .../data/visualization/templates/index.html | 137 +++++++++++++++++- .../bokeh_app/templates/index.html | 20 ++- tiatoolbox/visualization/tileserver.py | 3 + 3 files changed, 155 insertions(+), 5 deletions(-) diff --git a/tiatoolbox/data/visualization/templates/index.html b/tiatoolbox/data/visualization/templates/index.html index bff5a71df..041330870 100644 --- a/tiatoolbox/data/visualization/templates/index.html +++ b/tiatoolbox/data/visualization/templates/index.html @@ -101,12 +101,59 @@ left: 6pt; top: 116pt; } + .patient-id { + position: absolute; + top: 10px; + left: 50%; + transform: translateX(-50%); + z-index: 2000; + background: #fff; + padding: 10px 24px; + border-radius: 8px; + box-shadow: 0 2px 8px rgba(0,0,0,0.10); + font-weight: bold; + font-size: 1.2em; + color: #333; + border: 1px solid #eee; + } + .icon-btn { + background: #fff; + border: 1px solid #eee; + border-radius: 50%; + width: 44px; + height: 44px; + display: flex; + align-items: center; + justify-content: center; + font-size: 1.5em; + color: #333; + box-shadow: 0 2px 8px rgba(0,0,0,0.10); + cursor: pointer; + transition: background 0.2s, color 0.2s; + outline: none; + position: relative; + } + .icon-btn:hover { + background: #f0f0f0; + color: #007bff; + } + .icon-btn:active { + background: #e0e0e0; + }