Support Hexadecimal Page Numbers (e.g. 1FF, 12E)

- Refactored  to parse page numbers as nibbles ((T<<4)|U) instead of decimal, preventing collisions between hex and decimal pages.
- Updated  to format page IDs as Hex.
- Updated  to display page IDs as Hex in the list.
- Ensures filler/housekeeping pages are correctly isolated.
This commit is contained in:
2026-01-11 11:52:29 +01:00
parent 8c393c8f9e
commit 4b7b73e9a3
3 changed files with 11 additions and 3 deletions

View File

@@ -496,7 +496,8 @@ class MainWindow(QMainWindow):
sorted_keys = sorted(self.page_groups.keys())
for mag, pnum in sorted_keys:
label = f"{mag}{pnum:02d}"
# Display as Hex
label = f"{mag}{pnum:02X}"
item = QListWidgetItem(label)
item.setData(Qt.ItemDataRole.UserRole, (mag, pnum))
self.page_list.addItem(item)