Skip to content
/ glaze Public

A simple real-time screen annontation tool for GNU/Linux with both X11 and Wayland support.

Notifications You must be signed in to change notification settings

kde-yyds/glaze

Repository files navigation

Glaze

A lightweight, cross-platform screen annotation tool for Linux that provides real-time on-screen drawing capabilities.

License

✨ Features

🖥️ Universal Platform Support

  • X11 Support: Full support for traditional X11 desktop environments
  • Wayland Native: Native Wayland support using layer-shell protocol

📐 Modern Display Technology

  • HiDPI Scale Support: Perfect rendering on high-resolution displays with any scaling factor

🎯 Real-time Annotation

Unlike traditional screenshot-based annotation tools, Glaze provides:

  • Live Overlay: Draw directly on your screen without pausing your screen content
  • Persistent: Keep your annotations visible while continuing to use your computer

🛠️ Drawing Tools

  • Brush Tool: Freehand drawing with adjustable size (1-10px)
  • Eraser Tool: Remove annotations with adjustable size (10-100px)
  • Color Picker: Choose any color for your annotations
  • Clear Canvas: Remove all annotations instantly
  • Click Mode: Pass-through mode for normal computer interaction

🎨 User Interface

  • Draggable Toolbar: Move the control panel anywhere on screen
  • Background Blur: Modern blurred toolbar background (requires KWindowSystem)
  • Minimal Design: Unobtrusive interface that stays out of your way
  • Embedded Color Picker: Integrated Qt's color picker

📋 Requirements

Build Dependencies

  • Qt6 (Core, Widgets, GUI)
  • CMake >= 3.16
  • C++ compiler with C++17 support
  • layer-shell-qt (for Wayland support)
  • KWindowSystem (for blur effects)

Runtime Dependencies

  • For Wayland: Compositor with layer-shell-v1 protocol support
  • For X11: Any X11 server

🔨 Building

Arch Linux

# Install dependencies
sudo pacman -S qt6-base cmake layer-shell-qt kwindowsystem

# Clone and build
git clone https://github.com/kde-yyds/glaze
cd glaze
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
make

# Install (optional)
sudo make install

Ubuntu/Debian

# Install dependencies
sudo apt install qt6-base-dev cmake liblayershellqtinterface-dev libkf6windowsystem-dev

# Clone and build
git clone https://github.com/kde-yyds/glaze
cd glaze
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
make

# Install (optional)
sudo make install

🚀 Usage

Starting Glaze

glaze

Mouse/Touch Controls

  • Click Mode (🖱️): Click-through mode - interact with applications below
  • Brush Mode (✏️): Draw annotations on screen
  • Eraser Mode (🧹): Erase annotations
  • Drag Titlebar: Move the toolbar around the screen
  • Color Button: Open color picker to change brush color
  • Clear Button: Remove all annotations
  • Quit Button: Exit Glaze

Tips

  1. Start in Click Mode to position the toolbar
  2. Switch to Brush Mode to annotate
  3. Use Eraser to fix mistakes
  4. Return to Click Mode to interact with applications while keeping annotations visible

🏗️ Architecture

Window System Integration

Wayland Integration

  • Layer Shell Protocol: Uses layer-shell protocol to setup overlay window
  • Input Masking: Dynamic input regions allow click-through in specific areas

X11 Integration

  • Override Redirect: Unmanaged window that bypasses window manager
  • Input Shapes: X11 input shape extension for click-through regions

Both implementations provide:

  • Fullscreen coverage
  • Input passthrough

📝 License

This project is licensed under the GNU General Public License v2.0.

🙏 Acknowledgments

  • Qt Framework: Cross-platform UI framework
  • layer-shell-qt: Wayland layer-shell protocol implementation
  • KDE Frameworks: Window system integration and effects

🤝 Contributing

Contributions are welcome! Please feel free to submit pull requests or open issues.

Development Notes

  • Platform-specific code is isolated in WindowHelper and platform helpers
  • Wayland and X11 implementations are maintained separately in X11Helper and WaylandHelper

About

A simple real-time screen annontation tool for GNU/Linux with both X11 and Wayland support.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published