X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=autorandr.py;h=5082ebd08d6489e3d092766ec463dbb189af9ef7;hb=f171c8a5ad91dd586320d89c504c316d18f3d056;hp=e9d1c2570b4cda5a922b562f3030549a8653cac1;hpb=9b0570824fb93cf07701eff57038543d8ab744cf;p=deb_pkgs%2Fautorandr.git diff --git a/autorandr.py b/autorandr.py index e9d1c25..5082ebd 100755 --- a/autorandr.py +++ b/autorandr.py @@ -4,7 +4,7 @@ # autorandr.py # Copyright (c) 2015, Phillip Berndt # -# Experimental autorandr rewrite in Python +# Autorandr rewrite in Python # # This script aims to be fully compatible with the original autorandr. # @@ -21,22 +21,31 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . # -# TODO Add virtual profiles common, horizontal, vertical -# This also requires to load all resolutions into the XrandrOutputs from __future__ import print_function -import copy -import getopt import binascii +import copy +import getopt import hashlib import os +import posix +import pwd import re import subprocess import sys +import shutil +import time -from itertools import chain from collections import OrderedDict +from distutils.version import LooseVersion as Version +from functools import reduce +from itertools import chain + +try: + input = raw_input +except NameError: + pass virtual_profiles = [ # (name, description, callback) @@ -48,17 +57,22 @@ virtual_profiles = [ help_text = """ Usage: autorandr [options] --h, --help get this small help --c, --change reload current setup --s, --save save your current setup to profile --l, --load load profile +-h, --help get this small help +-c, --change reload current setup +-s, --save save your current setup to profile +-r, --remove remove profile +-l, --load load profile -d, --default make profile the default profile ---force force (re)loading of a profile ---fingerprint fingerprint your current hardware setup ---config dump your current xrandr setup +--skip-options