X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=autorandr.py;h=e11628c4959e16e2096aa325e70b3eca55617a0b;hb=b18d3347613a004bae879a669b9fee165153baa2;hp=7edf72fb243d66404a094da3b02813942b704a78;hpb=a64db8d1269af1c76bfa3604de489fe2f6c4a12e;p=deb_pkgs%2Fautorandr.git diff --git a/autorandr.py b/autorandr.py index 7edf72f..e11628c 100755 --- a/autorandr.py +++ b/autorandr.py @@ -656,9 +656,9 @@ def get_fb_dimensions(configuration): if "panning" in output.options: match = re.match("(?P[0-9]+)x(?P[0-9]+)(?:\+(?P[0-9]+))?(?:\+(?P[0-9]+))?.*", output.options["panning"]) if match: - detail = match.groupdict() - o_width = int(detail.get("w")) + int(detail.get("x", "0")) - o_height = int(detail.get("h")) + int(detail.get("y", "0")) + detail = match.groupdict(default="0") + o_width = int(detail.get("w")) + int(detail.get("x")) + o_height = int(detail.get("h")) + int(detail.get("y")) width = max(width, o_width) height = max(height, o_height) return int(width), int(height)