X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=autorandr.py;h=b18ce7b4d0ad61c456f9e062430a070ea29c0d1b;hb=176ce3bc1935693e4611bc151da38682f74e9c7a;hp=89f1ab816518b3e20a5f04e159b5b60302bd73c9;hpb=d8cb50aff33fcb964558086b33b7d059729511ec;p=deb_pkgs%2Fautorandr.git diff --git a/autorandr.py b/autorandr.py index 89f1ab8..b18ce7b 100755 --- a/autorandr.py +++ b/autorandr.py @@ -48,7 +48,7 @@ if sys.version_info.major == 2: else: import configparser -__version__ = "1.8" +__version__ = "1.8.1" try: input = raw_input @@ -161,6 +161,7 @@ class XrandrOutput(object): (?:[\ \t]*border\ (?P(?:[0-9]+/){3}[0-9]+))? # Border information (?:\s*(?: # Properties of the output Gamma: (?P(?:inf|[0-9\.: e])+) | # Gamma value + CRTC:\s*(?P[0-9]) | # CRTC value Transform: (?P(?:[\-0-9\. ]+\s+){3}) | # Transformation matrix EDID: (?P\s*?(?:\\n\\t\\t[0-9a-f]+)+) | # EDID of the output (?![0-9])[^:\s][^:\n]+:.*(?:\s\\t[\\t ].+)* # Other properties @@ -363,6 +364,8 @@ class XrandrOutput(object): # so we approximate by 1e-10. gamma = ":".join([str(max(1e-10, round(1. / float(x), 3))) for x in gamma.split(":")]) options["gamma"] = gamma + if match["crtc"]: + options["crtc"] = match["crtc"] if match["rate"]: options["rate"] = match["rate"]