[PATCH] [gdb/tui] Fix centering and highlighting of current line

Tom Tromey tom@tromey.com
Mon Apr 1 16:13:31 GMT 2024


>>>>> "Tom" == Tom de Vries <tdevries@suse.de> writes:

Tom> Fix these problems respectively by:
Tom> - in tui_enable, instead of "tui_show_frame_info (0)" using
Tom>   'tui_show_frame_info (deprecated_safe_get_selected_frame ())", and
Tom> - in tui_source_window_base::rerender, adding centering functionality.

Thanks.
Approved-By: Tom Tromey <tom@tromey.com>

Tom> +      /* This centering code is copied from tui_source_window::maybe_update.
Tom> +	 It would be nice to do centering more often, and do it in just one
Tom> +	 location.  But since this is a regression fix, handle this
Tom> +	 conservatively for now.  */

Yeah, unfortunately some of this code remains spaghetti from the old
days.

Tom


More information about the Gdb-patches mailing list