From 5bd8a40cf861829a4d13d16cfcc0a62e5b1ffc9a Mon Sep 17 00:00:00 2001 From: Kevin Easton Date: Fri, 15 Sep 2017 17:39:52 +1000 Subject: [PATCH] Change $geom() to return current screen's geometry, not the original terminal's This only affects additional screens created with /window create, which is an unusual configuration. --- Changelog | 3 +++ source/functions.c | 3 +-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Changelog b/Changelog index ae0867d..3da211b 100644 --- a/Changelog +++ b/Changelog @@ -1,5 +1,8 @@ [Changes 1.2.2] +* Change $geom() to return current screen's geometry, not the original + terminal's. (caf) + * Fix $statsparse() scripting function to handle right-justified status formats correctly and improve efficiency of all status formatting. (caf) diff --git a/source/functions.c b/source/functions.c index 67ff0d6..2f09fde 100644 --- a/source/functions.c +++ b/source/functions.c @@ -4208,8 +4208,7 @@ BUILT_IN_FUNCTION(function_channelmode, word) BUILT_IN_FUNCTION(function_geom, words) { - /* Erf. CO and LI are ints. (crowman) */ - return m_sprintf("%d %d", current_term->co, current_term->li); + return m_sprintf("%d %d", current_window->screen->co, current_window->screen->li); } BUILT_IN_FUNCTION(function_pass, words)