From cde6a0e940d736a84ff1390d3306794e1ee49627 Mon Sep 17 00:00:00 2001 From: Phillip Berndt Date: Sat, 11 Apr 2020 14:14:53 +0200 Subject: [PATCH] Handle negative gamma values Fixes #188. --- README.md | 1 + autorandr.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index ab3d23d..9e32355 100644 --- a/README.md +++ b/README.md @@ -215,6 +215,7 @@ profiles matching multiple (or any) monitors. ## Changelog **autorandr 1.10 (dev)** +* *2020-04-11* Handle negative gamma values (fixes #188) * *2020-04-11* Sort approximate matches in detected profiles by quality of match * *2019-12-31* Fix output positioning if the top-left output is not the first * *2019-12-31* Accept negative gamma values (and interpret them as 0) diff --git a/autorandr.py b/autorandr.py index 295d01a..c876560 100755 --- a/autorandr.py +++ b/autorandr.py @@ -172,7 +172,7 @@ class XrandrOutput(object): (?:[\ \t]*tracking\ (?P[0-9]+x[0-9]+\+[0-9]+\+[0-9]+))? # Tracking information (?:[\ \t]*border\ (?P(?:[0-9]+/){3}[0-9]+))? # Border information (?:\s*(?: # Properties of the output - Gamma: (?P(?:inf|[0-9\.\-: e])+) | # Gamma value + 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 -- 2.39.2