diff --git a/top/top.c b/top/top.c index 045748e9..a66eef0f 100644 --- a/top/top.c +++ b/top/top.c @@ -2173,7 +2173,8 @@ static inline void widths_resize (void) { Autox_found = 1; } } - if (Autox_found) calibrate_fields(); + // trigger a call to calibrate_fields (via zap_fieldstab) + if (Autox_found) Frames_signal = BREAK_autox; } // end: widths_resize @@ -5935,6 +5936,10 @@ static void frame_make (void) { WIN_t *w = Curwin; // avoid gcc bloat with a local copy int i, scrlins; + // check auto-sized width increases from the last iteration... + if (AUTOX_MODE && Autox_found) + widths_resize(); + // deal with potential signal(s) since the last time around... if (Frames_signal) zap_fieldstab(); @@ -5986,10 +5991,6 @@ static void frame_make (void) { /* we'll deem any terminal not supporting tgoto as dumb and disable the normal non-interactive output optimization... */ if (!Cap_can_goto) PSU_CLREOS(0); - - /* lastly, check auto-sized width needs for the next iteration */ - if (AUTOX_MODE && Autox_found) - widths_resize(); } // end: frame_make diff --git a/top/top.h b/top/top.h index 9ee42848..12fdef21 100644 --- a/top/top.h +++ b/top/top.h @@ -202,7 +202,7 @@ enum scale_enum { /* Used to manipulate (and document) the Frames_signal states */ enum resize_states { - BREAK_off = 0, BREAK_kbd, BREAK_sig + BREAK_off = 0, BREAK_kbd, BREAK_sig, BREAK_autox }; /* This typedef just ensures consistent 'process flags' handling */