From 20fd4f94fa8ce40e3b2f79cc04358c32c8acc8fc Mon Sep 17 00:00:00 2001 From: "Rafael H. Schloming" Date: Tue, 2 Jun 2009 17:41:11 +0000 Subject: added a signal handler for terminal resize git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@781091 13f79535-47bb-0310-9956-ffa450edef68 --- python/qpid-python-test | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'python/qpid-python-test') diff --git a/python/qpid-python-test b/python/qpid-python-test index d02f2ac6cc..8d56311dbe 100755 --- a/python/qpid-python-test +++ b/python/qpid-python-test @@ -110,6 +110,13 @@ def width(): WIDTH = width() +def resize(sig, frm): + global WIDTH + WIDTH = width() + +import signal +signal.signal(signal.SIGWINCH, resize) + def vt100_attrs(*attrs): return "\x1B[%sm" % ";".join(map(str, attrs)) -- cgit v1.2.1