0.0
No commit activity in last 3 years
No release in over 3 years
Ruby bindings for X11
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 3.4
~> 1.1
rspec-mocks-matchers-send_message
~> 0.1

Runtime

~> 1.2
 Project Readme

X11 bindings for ruby

Lightweight object wrappers around a subset of Xlib to handle displays, screens and windows. Uses Xrandr to deal with multi-monitor setups.

Installation

gem install xlib-objects

Basic usage

require 'xlib-objects'

display = XlibObj::Display.new(':0')

main_screen = display.screens.first

root_win = main_screen.root_window
root_win.width  # => e.g. 3600
root_win.height # => e.g. 1080

outputs = main_screen.crtcs.map(&:outputs).flatten
outputs.first.name # => e.g. 'DVI-I-1'
outputs.last.name  # => e.g. 'DVI-I-2'