Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

coddra/screenrotator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

39 Commits

Repository files navigation

Simple Qt screen rotation manager

This repository is a fork of GuLinux's ScreenRotator.

Extra functionalities:

  • lock, unlock or reset screen rotation with inter process communication
  • run shell commands on changing or locking orientation

See more in the Messaging and Commands section.

Similar to the current solution implemented in Gnome, but works on all other X11 desktop environments as well (KDE, XFCE, I3, etc).

Compilation requirements

  • cmake
  • gcc
  • Qt5 (with modules x11extras, sensors)
  • xrandr
  • XInput (Xi)

On ubuntu, run the following command to install dependencies:

sudo apt install -y git cmake build-essential qtbase5-dev libxrandr-dev libxi-dev libqt5x11extras5-dev libqt5sensors5-dev 

Installation

To build and install ScreanRot, run the following commands:

git clone https://github.com/coddra/screanRot
cd screanRot
./install.sh

You can run the program by calling sreenrotator.

Links

Main icon: https://www.iconfinder.com/icons/326583/orientation_rotation_screen_icon#size=256

Messaging

To send messages to an active screenrotator, use sreenrotator-msg. It accepts the following commands:

  • lock
  • unlock
  • toggle-lock
  • reset

You can send multiple commands like this:

screenrotator-msg reset lock

Commands

You can pass the commands to execute on entering landscape or portrait mode or locking or unlocking orientation as command line arguments. Prefix the commands with three dashes, like this:

screenrotator --- ~/.config/polybar/mode landscape --- ~/.config/polybar/mode portrait --- polybar-msg action lock hook 0 --- polybar-msg action lock hook 1

About

Automatic screen rotation daemon for X11

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 89.9%
  • Shell 5.9%
  • CMake 3.7%
  • C 0.5%

AltStyle によって変換されたページ (->オリジナル) /