Skip to content

feat(outputs): physical monitor alignment, desktop overlay, coordinate simplification, and display identification - #51

Open
ech678 wants to merge 5 commits into
srinivasr:mainfrom
ech678:feature/physical-monitor-alignment
Open

ech678 wants to merge 5 commits into
srinivasr:mainfrom
ech678:feature/physical-monitor-alignment

Conversation

@ech678

@ech678 ech678 commented Sep 19, 2026

Copy link
Copy Markdown

Overview

This PR adds physical monitor alignment, real-time desktop alignment overlay, coordinate normalization, and display identification to the Outputs page in nirimod.

Features & Enhancements

  1. Physical Monitor Dimensions & Aspect-Ratio Scaling:

    • Supports millimeter dimensions from EDID with standard presets (24" 16:9, 27" 16:9, 32" 16:9, and Custom).
    • Canvas toggle (Physical vs Logical) to render monitors proportionally according to physical dimensions rather than raw pixel resolution, preventing visual distortion across mixed-DPI multi-monitor setups.
  2. Real-Time Desktop Alignment Overlay (GtkLayerShell):

    • Lightweight overlay helper (alignment_overlay.py) using GtkLayerShell.
    • Click-through transparent overlay drawing a real-time horizontal laser alignment guide line with Vernier ruler ticks on screen edges.
    • Turns emerald green when displays achieve perfect center, top, or bottom alignment.
    • Fine-tune red line buttons (▲/▼ 1px and 10px) to directly compensate for physical desk mount height differences.
    • Canvas guide line toggle button in header.
  3. Coordinate Simplification (Normalization):

    • Added Simplify button under Quick Alignment row to normalize multi-monitor bounding box origin to (0, 0).
    • Eliminates negative coordinate offsets while preserving exact relative distances between all displays.
  4. Display Identification (Identify Displays):

    • Number badges (1, 2, ...) displayed on canvas monitor cards.
    • Identify button in header (find-location-symbolic) and suffix button on the Monitor selection row.
    • HUD card popup on each physical screen displaying large index numbers, connector names, model, resolution, refresh rate, and physical size with automatic 2.5s timeout.
  5. Bugfixes & Robustness:

    • Prevent false dirty state on canvas clicks when outputs have not actually moved.
    • Stable overlay reference height anchoring across monitor selections.
    • 26 new comprehensive unit tests in tests/test_physical_outputs.py (118 repository tests passing).

@ech678

ech678 commented Sep 19, 2026

Copy link
Copy Markdown
Author

Hi! Just a friendly heads-up: due to school and academic commitments, I might not be able to follow up or make modifications in a timely manner. Please feel free to review, adjust, or build upon any part of this PR as needed. Thank you for creating and maintaining nirimod!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant