X-Git-Url: https://git.donarmstrong.com/?p=deb_pkgs%2Fautorandr.git;a=blobdiff_plain;f=autorandr.py;h=1e980f6f7c0f7bc8f96999e36f5162a3971f5403;hp=433cdc6dfdb683ef773abff9ddae2f628cab2799;hb=HEAD;hpb=e987251c2158ee3237f82d1bbb12b14e6da470c6 diff --git a/autorandr.py b/autorandr.py index 433cdc6..93b4e79 100755 --- a/autorandr.py +++ b/autorandr.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # encoding: utf-8 # # autorandr.py @@ -26,13 +26,14 @@ from __future__ import print_function import binascii import copy -import fnmatch import getopt import hashlib +import math import os import posix import pwd import re +import shlex import subprocess import sys import shutil @@ -40,16 +41,16 @@ import time import glob from collections import OrderedDict -from distutils.version import LooseVersion as Version from functools import reduce from itertools import chain + if sys.version_info.major == 2: import ConfigParser as configparser else: import configparser -__version__ = "1.9" +__version__ = "1.14" try: input = raw_input @@ -63,6 +64,22 @@ virtual_profiles = [ ("clone-largest", "Clone all connected outputs with the largest resolution (scaled down if necessary)", None), ("horizontal", "Stack all connected outputs horizontally at their largest resolution", None), ("vertical", "Stack all connected outputs vertically at their largest resolution", None), + ("horizontal-reverse", "Stack all connected outputs horizontally at their largest resolution in reverse order", None), + ("vertical-reverse", "Stack all connected outputs vertically at their largest resolution in reverse order", None), +] + +properties = [ + "Colorspace", + "max bpc", + "aspect ratio", + "Broadcast RGB", + "audio", + "non-desktop", + "TearFree", + "underscan vborder", + "underscan hborder", + "underscan", + "scaling mode", ] help_text = """ @@ -77,11 +94,15 @@ Usage: autorandr [options] --batch run autorandr for all users with active X11 sessions --current only list current (active) configuration(s) --config dump your current xrandr setup +--cycle automatically load the next detected profile --debug enable verbose output --detected only list detected (available) configuration(s) --dry-run don't change anything, only print the xrandr commands --fingerprint fingerprint your current hardware setup +--ignore-lid treat outputs as connected even if their lids are closed +--match-edid match displays based on edid instead of name --force force (re)loading of a profile / overwrite exiting files +--list list configurations --skip-options