Skip to content

jojomondag/electron-multi-display-window-manager

Repository files navigation

Electron Multi Display Window Manager

A desktop application for advanced multi-display window management with state persistence and Windows Snap Layout integration.

Overview

The Electron Multi Display Window Manager provides a centralized interface for creating, managing, and organizing multiple windows across multiple displays while maintaining their exact state across application restarts. Features full compatibility with Windows native snap layouts and third-party window management tools.

Example

Application Screenshot

The main window manager interface showing active windows with detailed state information, alongside a managed window displaying its configuration.

Features

  • Multi-window management from single interface
  • Persistent window positions, sizes, and properties
  • Windows Snap Layout integration
  • Third-party snap tool support (StickySnap, PowerToys)
  • Multi-display positioning
  • Z-order and focus management
  • Real-time window monitoring

Installation

Prerequisites

  • Node.js v14+
  • Windows 10/11 (recommended)

Setup

git clone <your-repo-url>
cd electron-multi-display-window-manager
npm install
npm start

Usage

  1. Launch the application
  2. Create windows with custom titlesc
  3. Use Windows Snap Layouts or third-party tools normally
  4. Window positions and sizes are automatically saved
  5. Windows restore to exact positions on restart

Architecture

Core Files

  • main.js - Application controller and IPC communication
  • window-manager.js - Window management engine with snap detection
  • preload.js - Secure IPC bridge
  • index.html - Management interface
  • window.html - Managed window template

Key Features

  • Dual storage system (window-state + window-registry)
  • Advanced snap detection for Windows and third-party tools
  • Multi-display intelligence with display-relative positioning
  • Unified event handling and debounced saving

Configuration

The application uses electron-store for persistent storage:

  • Window states: positions, sizes, display information
  • Window registry: metadata and relationships
  • Automatic cleanup of orphaned states

Troubleshooting

Window positioning issues: Check display configuration and snap tool compatibility Multi-monitor problems: Verify display IDs in console output Snap state conflicts: Ensure Windows Snap Layouts are enabled

Debug information available through built-in console logging.

Development

Dependencies

  • Electron ^29.4.6
  • electron-store ^8.2.0

Commands

npm start          # Start application
npm install <pkg>  # Add dependencies

License

MIT License

Technical Notes

Optimized for Windows environments with professional window management requirements. Advanced snap detection and third-party tool integration are Windows-specific. Basic functionality works on all platforms.

Performance: <2s startup, <500ms window restoration, ~50MB base memory usage.

About

Multi-display window management for Electron windows with persistent state and snap layout integration

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published