Skip to content

AppShell: undecorated mode lost window controls + chrome dragging #162

@israel-dryer

Description

@israel-dryer

Summary

A user demonstrated that AppShell(undecorated=True) no longer provides window controls (minimize / maximize / close) or chrome-row dragging. In undecorated mode the OS title bar is removed and a custom border is drawn, but there is now no way to move, minimize, maximize, or close the window from the chrome — leaving the window effectively stuck.

Root cause

The clean-slate Shell rewrite (shipped in 0.1.0a10, PRs #133#136) builds its chrome band from a plain Frame:

# src/bootstack/widgets/_impl/composites/shell/layout.py
self._chrome = Frame(root, surface=self._chrome_surface)

The previous region-based AppShell got this behavior for free from the internal Toolbar, which supports show_window_controls= and draggable= (and auto-enables drag with controls):

# src/bootstack/widgets/_impl/composites/toolbar.py
self._draggable = draggable or show_window_controls  # Auto-enable drag with window controls
... self.bind('<B1-Motion>', self._on_drag_motion, add='+')

The new chrome Frame carries none of that. The docstring at layout.py:77 still claims undecorated "Enables window controls + dragging on the chrome row" — which is now inaccurate.

Proposed direction (enrich AppShell)

  • In undecorated mode, render window-control buttons (minimize / maximize / close) at the right edge of the chrome row.
  • Make the chrome row draggable to move the window (and ideally double-click-to-maximize), reusing the existing _on_drag_motion-style logic.
  • Expose options on AppShell/App to configure this — e.g. which controls show, whether the chrome is draggable — rather than hardwiring. Decide whether this lives on the public App/AppShell chrome surface or a dedicated window-controls config.
  • macOS: overrideredirect is already force-disabled there; keep custom controls Windows/Linux-only (ties into the separate native-macOS-chrome follow-up).
  • Fix the layout.py:77 docstring once behavior is restored.

Acceptance

  • AppShell(undecorated=True) shows working min/max/close and can be dragged by its chrome row on Windows/Linux.
  • The behavior is configurable via documented public options.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions