Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jichu4n/basic_wm
An example basic X11 window manager.
https://github.com/jichu4n/basic_wm
window-manager x11 x11-wm
Last synced: 15 days ago
JSON representation
An example basic X11 window manager.
- Host: GitHub
- URL: https://github.com/jichu4n/basic_wm
- Owner: jichu4n
- Created: 2014-03-25T23:18:43.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2024-07-03T23:05:54.000Z (4 months ago)
- Last Synced: 2024-08-01T16:23:22.046Z (3 months ago)
- Topics: window-manager, x11, x11-wm
- Language: C++
- Size: 53.7 KB
- Stars: 479
- Watchers: 16
- Forks: 72
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Basic Window Manager
[![Build Status][build-status-image]][github-url]
basic_wm is a simple reparenting, non-compositing X window manager that demonstrates
how to implement the fundamental functionality of a window manager:- Managing the life cycle of windows
- Reparenting windows
- Basic window operations (moving, resizing, closing)It serves as a pedagogical example for my series of articles,
[_How X Window Managers Work, And How To Write One_](https://jichu4n.com/posts/how-x-window-managers-work-and-how-to-write-one-part-i/).## Building and Running
To build this example window manager, you will need:
- A C++-11 enabled C++ compiler
- [GNU Make](https://www.gnu.org/software/make/)
- Xlib headers and libraries
- [google-glog](https://code.google.com/p/google-glog/) libraryTo run and test it, you will need:
- [Xephyr](https://en.wikipedia.org/wiki/Xephyr)
- `xinit`
- Some X utilities such as `xclock`, `xeyes`, and `xterm` to play withOn Debian / Ubuntu:
sudo apt-get install \
build-essential pkg-config libx11-dev libgoogle-glog-dev \
xserver-xephyr xinit x11-apps xtermOn Fedora:
sudo yum install \
make gcc gcc-c++ libX11-devel glog-devel \
xorg-x11-server-Xephyr xorg-x11-apps xtermOn Arch Linux:
sudo pacman -S base-devel libx11 google-glog \
xorg-server-xephyr xorg-xinit xorg-xclock xorg-xeyes xtermOnce you have all the dependencies, building and running it is as simple as:
./build_and_run.sh
This will launch a simple Xephyr session like in the following screenshot:
![Screenshot](basic_wm_screenshot.png)## Usage
Supported keyboard shortcuts:
- **Alt + Left Click**: Move window
- **Alt + Right Click**: Resize window
- **Alt + F4**: Close window
- **Alt + Tab**: Switch window[github-url]: https://github.com/jichu4n/basic_wm
[build-status-image]: https://github.com/jichu4n/basic_wm/actions/workflows/build.yaml/badge.svg