Skip to content

Fix pane layout instability across monitor-size changes #21

Description

@Cheol-H-Jeong

Problem

When a user disconnects and later reconnects from a different monitor environment, tmux/nmux resizes the panes. This currently causes two severe problems:

  1. Sub panes accumulate unexpectedly

    • After reconnecting from a different display size, sub panes can be duplicated/accumulated instead of preserving a stable layout.
  2. Main pane text reflows to the new pane width and stalls the session

    • When the pane width changes, the main pane content is reflowed/rewrapped to match the new width.
    • On long-running coding-agent sessions with large scrollback/output, this causes huge delay and can appear to freeze/hang.
    • The main pane text fill/reflow must not happen as a consequence of monitor-size changes.

Required behavior

The core pane sizes must be fixed to a canonical 16:9 layout and must not be user-resizable:

  • project-list side pane
  • main pane
  • status pane
  • bash pane

The layout should be stable regardless of the client monitor size used to attach to the tmux session.

Wide monitor behavior

On wide monitors, nmux should not widen/reflow the existing main pane. Instead, it should use the extra horizontal space by adjusting the number of sub panes or additional pane slots.

In other words:

  • Do not resize the main pane width based on monitor width.
  • Do not trigger text reflow in the main pane.
  • Use extra width for additional sub panes / workspace columns.

Acceptance criteria

  • Reattaching from a different monitor size does not duplicate or accumulate stale sub panes.
  • The project-list side pane, main pane, status pane, and bash pane keep fixed 16:9-derived dimensions.
  • Users cannot manually resize those core panes into unstable dimensions.
  • Wide displays increase capacity via sub-pane count/layout, not by changing the main pane width.
  • Existing main pane text does not reflow/re-wrap when attaching from a different monitor environment.
  • Long coding-agent sessions do not stall/freeze due to pane-width recalculation after reconnect.

Rationale

The current behavior makes long-running agent sessions fragile. A simple disconnect/reconnect from another screen can force expensive terminal reflow and leave the layout polluted with accumulated sub panes. nmux should treat the core interactive panes as fixed-size surfaces and adapt only the surrounding sub-pane layout.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions