Skip to content

azorkai/TopMost-WebView2-Floating-Workspace

Repository files navigation

🖥️ TopMost | WebView2 Floating Workspace

Platform Engine License

A hybrid desktop utility leveraging the Chromium engine (WebView2) to create borderless, always-on-top web instances with global system hook integration.


🚀 Project Overview

TopMost is a productivity tool designed for developers and power users who need persistent access to web-based dashboards, documentation, or media content without context switching.

Unlike standard browser windows, this application interacts directly with the Windows API (User32.dll) to register global hotkeys and manage window layering (Z-Order), ensuring the content remains accessible above other full-screen applications. It demonstrates the seamless integration of modern web technologies within a legacy .NET Framework container.

🛠️ Technical Highlights

  • WebView2 Integration: Embeds the full Microsoft Edge (Chromium) rendering engine, enabling support for modern JavaScript frameworks (React, Vue, etc.) within a native WinForms container.
  • Win32 API Interop: Utilizes P/Invoke to register system-wide hotkeys (Alt + M), allowing users to toggle visibility even when the application is not in focus.
  • Borderless UI Architecture: Implements a custom drag-and-drop handler for frameless windows, overriding standard OS window chrome for a minimalist aesthetic.
  • Persistent Configuration: Features a JSON-based settings manager (Newtonsoft.Json) that serializes user preferences (Opacity, Start URL, Hotkeys) and restores state upon initialization.

⚙️ Core Features

  • Global System Hooks: Minimize/Restore functionality works globally across the operating system context.
  • Dynamic Opacity Control: Adjustable transparency layers for creating "ghost" browser windows that don't obstruct background work.
  • Crash Resilience: Graceful error handling for WebView2 Runtime initialization failures, ensuring the host application remains stable even if the browser process encounters an exception.

🔧 Installation & Setup

Prerequisites

Configuration (settings.json)

The application generates a config file on the first run. You can manually tweak the HotkeyModifier (1 = Alt, 2 = Ctrl, 4 = Shift) to avoid conflicts with other IDE shortcuts.

{
  "Opacity": 85,
  "StartUrl": "[https://chatgpt.com](https://chatgpt.com)",
  "HotkeyModifier": 1,
  "HotkeyKey": "M"
}

About

Persistent overlay workspace utilizing WebView2 for seamless multi-instance web orchestration.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages